depositDetail.html 3.9 KB
<!DOCTYPE html>
<div id="tt" class="easyui-layout" fit="true" style="overflow-y: scroll; margin-left: 20px">
    <h2>寄存信息</h2>
    <div style="margin-top: 20px;margin-left: 30px">
        <table border="0" style="width:95%;margin-top:5px;line-height:30px;" id="tab">
            <tr>
                <td>持有者:<span id="showOwnerUid"></span></td>
                <td>寄存码:<span id="showDepositCode"></span></td>
                <td>库位号:<span id="showShelfCode"></span></td>
                <td>寄存状态:<span id="showStatusStr"></span></td>
            </tr>

            <tr>
                <td>剩余天数:<span id="showDepositRemainDay"></span></td>
                <td>滞纳天数:<span id="showDepositOverDay"></span></td>
                <td>滞纳金:<span id="showLateFee"></span>
                    <br/>运费  :<span id="showShipFee"></span>
                    <br/>提货费:<span id="showContractFee"></span>
                </td>
            </tr>
        </table>
    </div>
    <br/><br/><br/>
    <h2>操作信息</h2>
    <div style="margin-top: 20px;margin-left: 30px">
        <table border="0" style="width:95%;margin-top:5px;line-height:30px;" id="rent">
            <tr>
                <td>操作类型</td>
                <td>操作时间</td>
                <td>滞纳金</td>
                <td>详情</td>
            </tr>
        </table>
    </div>
    <br/><br/><br/>
    <h2>交易历史</h2>
    <div style="margin-top: 20px;margin-left: 30px">
        <table border="0" style="width:95%;margin-top:5px;line-height:30px;" id="trade">
            <tr>
                <td>订单编号</td>
                <td>持有人</td>
                <td>交易时间</td>
            </tr>
        </table>
    </div>
</div>
<script>

    $(function () {
        // 隐藏域赋值
        $.post(contextPath + "/storageDeposit/getDepositDetail", {
            depositCode: depositCode
        }, function (result) {
            if (result.code == 200) {
                var data = result.data;
                $("#showOwnerUid").text(data.ownerUid);
                $("#showDepositCode").text(data.depositCode);
                $("#showShelfCode").text(data.shelfCode);
                $("#showStatusStr").text(data.statusStr);
                $("#showDepositRemainDay").text(data.depositRemainDay);
                $("#showDepositOverDay").text(data.depositOverDay);
                $("#showLateFee").text(data.lateFee);
                $("#showShipFee").text(data.shipFee);
                $("#showContractFee").text(data.contractFee);

                // 续约
                for ( var i = 0; i <data.opInfo.length; i++){
                    var rowStr ="<tr>";
                    rowStr += "<td>"+data.opInfo[i].opName+"</td>";
                    rowStr += "<td>"+data.opInfo[i].depositTime+"</td>";
                    rowStr += "<td>"+data.opInfo[i].lateFee+"</td>";

                    if("续约" == data.opInfo[i].opName) {
                        rowStr += "<td> 续约费:"+data.opInfo[i].reNewFee+"<br/>续约天数:"+data.opInfo[i].renewDay+"</td>";
                    } else {
                        rowStr += "<td> 提货费:"+data.opInfo[i].contractFee+"<br/>运费  :"+data.opInfo[i].shipFee+"</td>";
                    }
                    rowStr += "</tr>";
                    $("#rent").append(rowStr);
                }

                // 交易
                for ( var i = 0; i <data.tradeInfo.length; i++){
                    var rowStr ="<tr>";
                    rowStr += "<td>"+data.tradeInfo[i].orderCode+"</td>";
                    rowStr += "<td>"+data.tradeInfo[i].ownerUid+"</td>";
                    rowStr += "<td>"+data.tradeInfo[i].depositTime+"</td>";
                    rowStr += "</tr>";
                    $("#trade").append(rowStr);
                }
                $.parser.parse($("#trade").parent());
            }
        });
    });
</script>