dateils.html 2.92 KB
<form id="edit-form" test="1" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="table-responsive">

        <table id="table"  class="table table-striped table-bordered table-hover table-nowrap">
            <thead>
            <td></td>
            <th>{:__('商品名称')}</th>

            <th>{:__('单位')}</th>
            <th>{:__('单价')}</th>
            {if condition="in_array(1, $role)"}
            <th>{:__('结算价')}</th>
            {/if}
            {if condition="in_array(2, $role)"}
            <th>{:__('成本价')}</th>
            {/if}
            <th>{:__('数量')}</th>
            <th>{:__('总价')}</th>
            </thead>
            <tbody>
            {volist name="row.goods_list" id="list" key="k"}

                <tr>
                    <td>{$key}</td>
                </tr>
                {volist name="$row.goods_list[$key]" id="vo" key="k"}
                <tr>
                    <td></td>
                    <td>{$vo.productName}</td>
                    <td>{$vo.unit}</td>
                    <td>{$vo.unitPrice}</td>
                    {if condition="in_array(1, $role)"}
                    <td>{$vo.wholesale_price}</td>
                    {/if}
                    {if condition="in_array(2, $role)"}
                    <td>{$vo.cb_price}</td>
                    {/if}
                    <td>{$vo.qty}</td>
                    <td>{$vo.amount}</td>
                </tr>
                {/volist}
            {/volist}


            <tr>
                <td>合计</td>
                <td></td>
                {if condition="in_array(1, $role)"}
                <th></th>
                {/if}
                {if condition="in_array(2, $role)"}
                <th></th>
                {/if}
                <td></td>
                <td></td>
                <td></td>
                <td>{$row.totalprice}</td>
            </tr>

            {if condition="in_array(1, $role)"}
            <tr>
                <td>销售利润率</td>
                <td></td>
                {if condition="in_array(1, $role)"}
                <th></th>
                {/if}
                {if condition="in_array(2, $role)"}
                <th></th>
                {/if}
                <td></td>
                <td></td>
                <td></td>
                <td>{$row.balance}</td>
            </tr>
            {/if}


            {if condition="in_array(2, $role)"}
            <tr>
                <td>成本利润率</td>
                <td></td>
                {if condition="in_array(1, $role)"}
                <th></th>
                {/if}
                {if condition="in_array(2, $role)"}
                <th></th>
                {/if}
                <td></td>
                <td></td>
                <td></td>
                <td>{$row.profit}</td>
            </tr>
            {/if}
            </tbody>
        </table>
    </div>



</form>