table.hbs 1.66 KB
<div class="address-table">

    <span class="blue table-title">已保存了{{data.length}}条地址,还能保存{{data.leftLength}}条地址</span>
    <table class="a-table">
        <tr class="table-head">
            <th class="width-70">收货人</th>
            <th class="width-195">所在区域</th>
            <th class="width-255">详细地址</th>
            <th class="width-120">手机/电话</th>
            <th class="width-260">操作</th>
        </tr>
        {{#each data}}
            <tr class="table-body">
                <input type="hidden" id="tr_{{address_id}}" value="{{address_id}}">
                <input type="hidden" id="tr_{{area_code}}" value="{{area_code}}">
                <td class="width-70">{{consignee}}</td>
                <td class="width-195">{{area}}</td>
                <td class="width-255">{{address}}</td>
                <td class="width-120"><p>{{mobile}}</p><p>{{phone}}</p></td>
                <td class="width-260">
                    <div>
                        <span class="blue opreation update-address" data-id="{{address_id}}">修改</span>
                        <em class="op-sep">|</em>
                        <span class="blue opreation del-address" data-id="{{address_id}}">删除</span>
                        {{#isY is_default}}
                            <span class="btn set-default opreation current-default ">默认地址</span>
                        {{^}}
                            <span class="btn set-default opreation " data-id="{{address_id}}">设为默认</span>
                        {{/isY}}
                    </div>
                </td>
            </tr>
        {{/each}}
    </table>

</div>