You've already forked qlg.tsgz.moe
Init Repo
This commit is contained in:
439
hyhproject/wechat2/view/default/users/sellerorders/orders_list.html
Executable file
439
hyhproject/wechat2/view/default/users/sellerorders/orders_list.html
Executable file
@ -0,0 +1,439 @@
|
||||
{extend name="default/base" /}
|
||||
{block name="title"}我的订单 - {__block__}{/block}
|
||||
{block name="css"}
|
||||
<link rel="stylesheet" href="__WECHAT__/css/orders.css?v={$v}">
|
||||
{/block}
|
||||
{block name="header"}
|
||||
<div id="info_list">
|
||||
<header style="background:#ffffff;" class="ui-header ui-header-positive wst-header wst-headero">
|
||||
<i class="ui-icon-return" onclick="location.href='{:url('wechat/users/index')}'"></i><h1>我的订单</h1>
|
||||
</header>
|
||||
{/block}
|
||||
{block name="main"}
|
||||
<input type="hidden" name="" value="" id="currPage" autocomplete="off">
|
||||
<input type="hidden" name="" value="" id="totalPage" autocomplete="off">
|
||||
<input type="hidden" name="" value="{$type}" id="type" autocomplete="off">
|
||||
|
||||
<script id="shopList" type="text/html">
|
||||
{{# for(var i = 0; i < d.length; i++){ }}
|
||||
<div class="order-item">
|
||||
<div class="ui-row-flex ui-whitespace item-head" onclick="getOrderDetail({{d[i].orderId}})">
|
||||
<div class="ui-col ui-col-2 ui-nowrap-flex">订单号:{{d[i].orderNo}}{{d[i].noticeDeliver}}
|
||||
{{# if(d[i].orderStatus==0 && d[i].noticeDeliver==1){ }}
|
||||
<span class='notice'><img style='width:0.2rem' src='{{WST.conf.ROOT}}\wstmart\wechat\view\default\img\nocite_deliver.png'>提醒发货</span>
|
||||
{{# } }}
|
||||
</div>
|
||||
<div class="ui-col order-tr o-status">
|
||||
{{ d[i].status }}
|
||||
{{# if($.inArray(d[i].orderStatus,[-1,-3])!=-1){ }}
|
||||
{{# if(d[i].payType==1 && d[i].isPay==1) { }}
|
||||
{{# if(d[i].isRefund==1) { }}
|
||||
(已退款)
|
||||
{{# }else{ }}
|
||||
(未退款)
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{# for(var g=0;g<d[i].list.length;g++){ }}
|
||||
<div class="ui-row-flex ui-whitespace border-b" onclick="getOrderDetail({{d[i].orderId}})">
|
||||
<div class="ui-col">
|
||||
<img src="__ROOT__/{{d[i].list[g].goodsImg}}" class="o-Img">
|
||||
</div>
|
||||
<div class="ui-col ui-col-3 o-gInfo">
|
||||
<p class="o-gName ui-nowrap-multi ui-whitespace">{{d[i].list[g].goodsName}}</p>
|
||||
|
||||
{{# if(d[i].list[g].goodsSpecNames){ }}
|
||||
<p class="o-gSpec ui-nowrap-flex ui-whitespace">规格:{{d[i].list[g].goodsSpecNames}}</p>
|
||||
{{# } }}
|
||||
|
||||
</div>
|
||||
<div class="ui-col order-tr" style="word-break:break-all;padding:5px 0;">
|
||||
{{# if(d[i].list[g].goodsCode=='gift'){ }}
|
||||
【赠品】
|
||||
{{# }else{ }}
|
||||
<p>¥ {{d[i].list[g].goodsPrice}}</p><p>x {{d[i].list[g].goodsNum}}</p>
|
||||
{{# } }}
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
|
||||
|
||||
<div style="padding-top:5px;padding-bottom:5px;">
|
||||
<div class="o-oListMoney">
|
||||
订单总价:<span>¥ {{d[i].realTotalMoney}}</span>
|
||||
</div>
|
||||
{{# if(d[i].orderStatus==-2){ }}
|
||||
<button class="ui-btn o-btn" onclick="showEditMoneyBox('editOrderMoney({{d[i].orderId}})')">
|
||||
修改价格
|
||||
</button>
|
||||
{{# } }}
|
||||
|
||||
{{# if(d[i].orderStatus==0){ }}
|
||||
<button class="ui-btn o-btn" onclick="toDeliver({{d[i].orderId}},{{d[i].deliverTypes}})">
|
||||
发货
|
||||
</button>
|
||||
{{# } }}
|
||||
|
||||
{{# if(d[i].payType==1 && WST.blank(d[i].refundId)!=''){ }}
|
||||
<button class="ui-btn o-btn" onclick="showRefundBox({{d[i].refundId}})">
|
||||
退款操作
|
||||
</button>
|
||||
{{# } }}
|
||||
{{# if(d[i].isAppraise==1){ }}
|
||||
<button class="ui-btn o-btn" onclick="toAppr({{d[i].orderId}})">
|
||||
查看评价
|
||||
</button>
|
||||
{{# } }}
|
||||
<div class="wst-clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
</script>
|
||||
|
||||
<section class="ui-container" id="shopBox">
|
||||
<div class="ui-tab">
|
||||
<ul class="ui-tab-nav order-tab">
|
||||
<?php $shopMenus = WSTShopOrderMenus();?>
|
||||
{if (count($shopMenus)==6)}
|
||||
<li class="tab-item {if $type=='all'}tab-curr{/if}" type="all" >全部</li>
|
||||
{/if}
|
||||
{if array_key_exists("waitPay",$shopMenus)}
|
||||
<li class="tab-item {if $type=='waitPay'}tab-curr{/if}" type="waitPay" >待付款</li>
|
||||
{/if}
|
||||
{if array_key_exists("waitDeliver",$shopMenus)}
|
||||
<li class="tab-item {if $type=='waitDeliver'}tab-curr{/if}" type="waitDeliver" >待发货</li>
|
||||
{/if}
|
||||
{if array_key_exists("waitReceive",$shopMenus)}
|
||||
<li class="tab-item {if $type=='waitReceive'}tab-curr{/if}" type="waitReceive" >待收货</li>
|
||||
{/if}
|
||||
{if array_key_exists("waitAppraise",$shopMenus)}
|
||||
<li class="tab-item {if $type=='waitAppraise'}tab-curr{/if}" type="waitAppraise" >待评价</li>
|
||||
{/if}
|
||||
{if array_key_exists("finish",$shopMenus)}
|
||||
<li class="tab-item {if $type=='finish'}tab-curr{/if}" type="finish" >已完成</li>
|
||||
{/if}
|
||||
{if array_key_exists("abnormal",$shopMenus)}
|
||||
<li class="tab-item {if $type=='abnormal'}tab-curr{/if}" type="abnormal" >取消拒收</li>
|
||||
{/if}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div id="order-box">
|
||||
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script type="text/html" id="detailBox">
|
||||
<div id="detailBox">
|
||||
<div class="detail-head" style="margin-top:0;">
|
||||
{{# if($.inArray(d.orderStatus,[-2,0,1,2])!=-1){ }}
|
||||
<div class="wst-or-process">
|
||||
<div class="ui-row-flex">
|
||||
{{# if(d.payType==1) { }}
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if($.inArray(d.orderStatus,[-2,0,1,2])!=-1){ }}class="active"{{# } }}></span>
|
||||
<span {{# if($.inArray(d.orderStatus,[0,1,2])!=-1){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if($.inArray(d.orderStatus,[-2,0,1,2])!=-1){ }}active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>待付款</p></div>
|
||||
{{# } }}
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if($.inArray(d.orderStatus,[0,1,2])!=-1){ }}class="active"{{# } }}></span>
|
||||
<span {{# if($.inArray(d.orderStatus,[1,2])!=-1){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if($.inArray(d.orderStatus,[0,1,2])!=-1){ }}active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>待发货</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if($.inArray(d.orderStatus,[1,2])!=-1){ }}class="active"{{# } }}></span>
|
||||
<span {{# if(d.orderStatus==2){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if($.inArray(d.orderStatus,[1,2])!=-1){ }}active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>已发货</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if(d.orderStatus==2){ }}class="active"{{# } }}></span>
|
||||
<span {{# if(d.orderStatus==2){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if(d.orderStatus==2){ }}active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>已收货</p></div>
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
{{# if($.inArray(d.orderStatus,[-1,-3])!=-1 && d.payType==1 && d.isPay==1){ }}
|
||||
<div class="wst-or-process">
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span class="active"></span>
|
||||
<span {{# if(d.refundStatus==1 || d.refundStatus==2 || d.refundStatus==0){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block active"></i></p>
|
||||
<div class="wst-clear"></div></p><p>买家申请退款</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if(d.refundStatus==1 || d.refundStatus==2 || d.refundStatus==0){ }}class="active"{{# } }}></span>
|
||||
<span {{# if(d.refundStatus==2){ }}class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if(d.refundStatus==1 || d.refundStatus==2 || d.refundStatus==0){ }}active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>商家申请退款处理</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span {{# if(d.refundStatus==2) { }} class="active"{{# } }}></span>
|
||||
<span {{# if(d.refundStatus==2) { }} class="active"{{# } }}></span>
|
||||
<p class="icon"><i class="ui-icon-success-block {{# if(d.refundStatus==2) { }} active{{# } }}"></i></p>
|
||||
<div class="wst-clear"></div></p><p>退款完成</p></div>
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
<div class="detail-head" style="margin-top:0;">
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">订单状态:</span>
|
||||
<span class="o-status">{{d.status}}
|
||||
{{# if($.inArray(d.orderStatus,[-1,-3])!=-1){ }}
|
||||
{{# if(d.payType==1 && d.isPay==1) { }}
|
||||
{{# if(d.isRefund==1) { }}
|
||||
(已退款)
|
||||
{{# }else{ }}
|
||||
(未退款)
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
{{# } }}</span></div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">订单编号:</span>{{d.orderNo}}</div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">下单时间:</span>{{d.createTime}}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="detail-head">
|
||||
{{# if(d.userName){ }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">收货人:</span>{{d.userName}} <span class="d-utel">{{d.userPhone}}</span></div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">收货地址:</span><span class="d-uaddr">{{d.userAddress}}<i></i></span></div>
|
||||
</div>
|
||||
{{# } }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">支付信息:</span>{{d.payInfo}}</div>
|
||||
</div>
|
||||
{{# if(d.payTime){ }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">支付时间:</span>{{d.payTime}}</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">配送信息:</span>{{d.deliverInfo}}</div>
|
||||
</div>
|
||||
{{# if(WST.blank(d.expressNo)!=''){ }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">快递公司:</span>{{d.expressName}}</div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">快递号:</span>{{d.expressNo}}</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">发票信息:</span>{{# if(d.isInvoice==1) { }}需要{{# } else{ }}不需要{{# } }}</div>
|
||||
</div>
|
||||
{{# if(d.isInvoice==1) { }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">发票抬头:</span>{{d.invoiceClient}}</div>
|
||||
</div>
|
||||
{{#
|
||||
var inv_json = JSON.parse(d.invoiceJson);
|
||||
var inv_code = (inv_json!=null && inv_json.invoiceCode!=undefined)?inv_json.invoiceCode:'';
|
||||
if(inv_json!=null && inv_json.type!=undefined && inv_json.type==0){
|
||||
}}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">发票税号:</span>{{inv_code}}</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">订单备注:</span>{{d.orderRemarks}}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{# if(d.isRefund==1){ }}
|
||||
<div class="detail-head">
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">退款金额:</span>¥ {{d.backMoney}}</div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">退款备注:</span>{{d.refundRemark}}</div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe">退款时间:</span>{{d.refundTime}}</div>
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
|
||||
|
||||
<div class="detail-head">
|
||||
<div class="ui-row-flex o-shops">
|
||||
<div class="ui-col ui-col wst-or-term"><p class="shops" onclick="javascript:WST.intoShops({{d.shopId}});"><i></i>{{d.shopName}}<p></div>
|
||||
</div>
|
||||
{{# for(var i=0;i<d.goods.length;i++){ }}
|
||||
<p>商品编号: {{d.goods[i].goodsSn}}</p>
|
||||
<div class="ui-row-flex ui-whitespace border-b d-goodsitme" onclick="javascript:WST.intoGoods({{d.goods[i].goodsId}})">
|
||||
<div class="ui-col">
|
||||
<img src="__ROOT__/{{d.goods[i].goodsImg}}" class="o-Img">
|
||||
</div>
|
||||
<div class="ui-col ui-col-3 o-gInfo">
|
||||
<p class="o-gName ui-nowrap-multi ui-whitespace">{{d.goods[i].goodsName}}</p>
|
||||
<p class="o-gSpec d-gSpec">
|
||||
{{# if(d.goods[i].goodsSpecNames){ }}
|
||||
{{d.goods[i].goodsSpecNames.replace(/@@_@@/g,'<br />')}}
|
||||
{{# } }}
|
||||
</p>
|
||||
</div>
|
||||
<div class="ui-col order-tr" style="word-break:break-all;padding:5px 0;">
|
||||
{{# if(d.goods[i].goodsCode=='gift'){ }}
|
||||
【赠品】
|
||||
{{# }else{ }}
|
||||
<p>¥ {{d.goods[i].goodsPrice}}</p><p>x {{d.goods[i].goodsNum}}</p>
|
||||
{{# } }}
|
||||
</div>
|
||||
</div>
|
||||
{{# if(d.goods[i].goodsType==1 && d.orderStatus==2){ }}
|
||||
{{# for(var e=0;e<d.goods[i].extraJson.length;e++){ }}
|
||||
<div class="ui-row-flex ui-row-flex-ver d-uInfo">
|
||||
<div class="ui-col">
|
||||
<p>卡券号:{{d.goods[i].extraJson[e].cardNo}}</p>
|
||||
<p>卡券密码:{{d.goods[i].extraJson[e].cardPwd}}</p>
|
||||
</div>
|
||||
</div>
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
{{# } }}
|
||||
</div>
|
||||
|
||||
<div class="detail-head">
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe2">获得积分</span><span class="o-status2">{{d.orderScore}} 个</span></div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe2">商品总额</span><span class="o-status2">¥ {{d.goodsMoney}}</span></div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe2">运费</span><span class="o-status2">¥ {{d.deliverMoney}}</span></div>
|
||||
</div>
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe2">积分抵扣金额</span><span class="o-status2">¥ -{{d.scoreMoney}}</span></div>
|
||||
</div>
|
||||
{{# if(d.useScore>0){ }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term"><span class="wst-or-describe2">使用积分数</span><span class="o-status2">{{d.useScore}} 个</span></div>
|
||||
</div>
|
||||
{{# } }}
|
||||
{{ d['hook']?d['hook']:"" }}
|
||||
<div class="ui-row-flex">
|
||||
<div class="ui-col ui-col wst-or-term2"><span class="wst-or-describe2">实付款</span><span class="o-status2"><span style="font-size:0.13rem;">¥ </span>{{d.realTotalMoney}}</span></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
{/* 遮盖层 */}
|
||||
<div class="wst-cover" id="cover"></div>
|
||||
{/* 订单详情层 */}
|
||||
<div class="wst-fr-box" id="frame">
|
||||
<div class="title" id="boxTitle"><span>订单详情</span><i class="ui-icon-close-page" onclick="javascript:dataHide();"></i><div class="wst-clear"></div></div>
|
||||
<div class="content" id="content">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{/* 退款层 */}
|
||||
<div class="wst-fr-box" id="refundFrame">
|
||||
<div class="title"><span>申请退款</span><i class="ui-icon-close-page" onclick="javascript:reFundDataHide();"></i><div class="wst-clear"></div></div>
|
||||
<div class="content" id="refund-content">
|
||||
<div class="detail-head" style="margin-top:0;">
|
||||
<div class="wst-or-process">
|
||||
<div class="ui-row-flex" style="padding:10px;border-bottom:RGB(242,242,242) 2px dashed;">
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span class="active"></span>
|
||||
<span class="active"></span>
|
||||
<p class="icon"><i class="ui-icon-success-block active"></i></p>
|
||||
<div class="wst-clear"></div></p><p>卖家申请退款</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span class="active"></span>
|
||||
<span></span>
|
||||
<p class="icon"><i class="ui-icon-success-block active"></i></p>
|
||||
<div class="wst-clear"></div></p><p>商家申请退款处理</p></div>
|
||||
<div class="ui-col ui-col process"><p class="line">
|
||||
<span></span>
|
||||
<span></span>
|
||||
<p class="icon"><i class="ui-icon-success-block"></i></p>
|
||||
<div class="wst-clear"></div></p><p>退款完成</p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="wst-or-refund">
|
||||
<p class="term" style="padding: 3px 5px 0 5px;">订单号:<span id="refundOid"></span></p>
|
||||
<p class="term" style="padding: 3px 5px 0 5px;">实付金额:<span id="realTotalMoney"></span></p>
|
||||
<p class="term" style="padding: 3px 5px 0 5px;">退款金额:<span id="refundMoney" class="sign"></span></p>
|
||||
<p class="term" style="padding: 3px 5px 0 5px;">退款积分:<span id="useScore" class="sign">0</span> 个(积分抵扣<span id="scoreMoney" class="sign">¥ 0</span>)</p>
|
||||
<p style="padding: 3px 5px 0 5px;">商家意见:
|
||||
<label><input type='radio' onclick='WST.showHide(0,"#tr")' name='refundStatus' id='refundStatus' value='1' checked/>同意</label>
|
||||
<label style='margin-left:15px;'><input type='radio' onclick='WST.showHide(1,"#tr")' name='refundStatus' id='refundStatus' value='-1'/>不同意</label>
|
||||
</p>
|
||||
<div class="term">
|
||||
<div id='tr' style="width:99%;display:none;" >
|
||||
<span class="sign">*</span>原因
|
||||
<textarea id='shopRejectReason' style='width:100%;height:80px;padding: 5px;' maxLength='200'></textarea>
|
||||
</div>
|
||||
</div>
|
||||
<p class="cancel-btn-box ui-flex ui-flex-pack-center">
|
||||
<button id="wst-event8" type="button" class="ui-btn-s wst-dialog-b2">确定</button>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
{block name="include"}
|
||||
{include file="default/dialog" /}<!-- 对话框模板 -->
|
||||
{/* 发货 */}
|
||||
<div class="ui-dialog" id="deliveryBox">
|
||||
<div class="ui-dialog-cnt">
|
||||
<div class="ui-dialog-bd">
|
||||
快递公司:<br>
|
||||
<select id='expressId' style="height:30px;width:100%;">
|
||||
{volist name="$express" id="vo"}
|
||||
<option value='{$vo["expressId"]}'>{$vo["expressName"]}</option>
|
||||
{/volist}
|
||||
</select><br>
|
||||
快递号:<br>
|
||||
<input type="text" id="expressNo" style="float: left;height:30px;width:100%;"/>
|
||||
|
||||
<p class="cancel-btn-box">
|
||||
<button id="wst-event1" type="button" class="ui-btn-s wst-dialog-b1" data-role="button">取消</button>
|
||||
<button id="wst-event0" type="button" class="ui-btn-s wst-dialog-b2">确定</button>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* 修改价格 */}
|
||||
<div class="ui-dialog" id="editMoneyBox">
|
||||
<div class="ui-dialog-cnt">
|
||||
<div class="ui-dialog-bd">
|
||||
新价格:<input type='text' id='newOrderMoney' maxLength='10' style='width:150px;height:30px' onkeyup="javascript:WST.isChinese(this,1)" onkeypress="return WST.isNumberdoteKey(event,true)" onblur='javascript:WST.limitDecimal(this,2)'>
|
||||
|
||||
<p class="cancel-btn-box">
|
||||
<button id="wst-event1" type="button" class="ui-btn-s wst-dialog-b1" data-role="button">取消</button>
|
||||
<button id="wst-event3" type="button" class="ui-btn-s wst-dialog-b2">确定</button>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
{block name="js"}
|
||||
<script type='text/javascript' src='__WECHAT__/js/jquery.min.js'></script>
|
||||
<script type='text/javascript' src='__WECHAT__/users/sellerorders/orders_list.js?v={$v}'></script>
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
// 弹出层
|
||||
var w = WST.pageWidth();
|
||||
$("#frame").css('top',0);
|
||||
$("#frame").css('right',-w);
|
||||
});
|
||||
</script>
|
||||
{/block}
|
285
hyhproject/wechat2/view/default/users/sellerorders/orders_list.js
Executable file
285
hyhproject/wechat2/view/default/users/sellerorders/orders_list.js
Executable file
@ -0,0 +1,285 @@
|
||||
jQuery.noConflict();
|
||||
// 获取订单列表
|
||||
function getOrderList(){
|
||||
$('#Load').show();
|
||||
loading = true;
|
||||
var param = {};
|
||||
param.type = $('#type').val();
|
||||
param.pagesize = 10;
|
||||
param.page = Number( $('#currPage').val() ) + 1;
|
||||
param.deliverType = -1;
|
||||
param.payType = -1;
|
||||
$.post(WST.U('wechat/orders/getSellerOrderList'), param, function(data){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status>0){
|
||||
var html = '';
|
||||
json = json.data;
|
||||
if(json && json.Rows && json.Rows.length>0){
|
||||
var gettpl = document.getElementById('shopList').innerHTML;
|
||||
laytpl(gettpl).render(json.Rows, function(html){
|
||||
$('#order-box').append(html);
|
||||
});
|
||||
|
||||
$('#currPage').val(json.CurrentPage);
|
||||
$('#totalPage').val(json.TotalPage);
|
||||
}else{
|
||||
html += '<div class="wst-prompt-icon"><img src="'+ window.conf.WECHAT +'/img/nothing-order.png"></div>';
|
||||
html += '<div class="wst-prompt-info">';
|
||||
html += '<p>暂无相关订单</p>';
|
||||
html += '</div>';
|
||||
$('#order-box').html(html);
|
||||
}
|
||||
WST.imgAdapt('j-imgAdapt');
|
||||
loading = false;
|
||||
$('#Load').hide();
|
||||
echo.init();//图片懒加载
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
}
|
||||
var currPage = totalPage = 0;
|
||||
var loading = false;
|
||||
$(document).ready(function(){
|
||||
$('#type').val(jQuery("#shopBox li:first").attr("type"));
|
||||
jQuery("#shopBox li:first").addClass("tab-curr");
|
||||
getOrderList();
|
||||
WST.initFooter('user');
|
||||
// Tab切换卡
|
||||
$('.tab-item').click(function(){
|
||||
$(this).addClass('tab-curr').siblings().removeClass('tab-curr');
|
||||
var type = $(this).attr('type');
|
||||
$('#type').val(type);
|
||||
reFlashList();
|
||||
});
|
||||
// 弹出层
|
||||
$("#frame").css('top',0);
|
||||
|
||||
$(window).scroll(function(){
|
||||
if (loading) return;
|
||||
if ((5 + $(window).scrollTop()) >= ($(document).height() - screen.height)) {
|
||||
currPage = Number( $('#currPage').val() );
|
||||
totalPage = Number( $('#totalPage').val() );
|
||||
if( totalPage > 0 && currPage < totalPage ){
|
||||
getOrderList();
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
// 刷新列表页
|
||||
function reFlashList(){
|
||||
$('#currPage').val('0');
|
||||
$('#order-box').html(' ');
|
||||
getOrderList();
|
||||
}
|
||||
|
||||
|
||||
// 拒收
|
||||
function showEditMoneyBox(event){
|
||||
$("#wst-event3").attr("onclick","javascript:"+event);
|
||||
$("#editMoneyBox").dialog("show");
|
||||
}
|
||||
|
||||
function editOrderMoney(oid){
|
||||
var newOrderMoney = $('#newOrderMoney').val();
|
||||
$.post(WST.U('wechat/orders/editOrderMoney'),{id:oid,orderMoney:newOrderMoney},function(data){
|
||||
hideDialog('#editMoneyBox');
|
||||
var json = WST.toJson(data);
|
||||
if(json.status>0){
|
||||
$('#newOrderMoney').val(' ');
|
||||
WST.msg(json.msg,'success');
|
||||
reFlashList();
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// 退款
|
||||
function showRefundBox(id){
|
||||
$.post(WST.U('wechat/orders/toShopRefund'),{id:id},function(data){
|
||||
var json = WST.toJson(data);
|
||||
$('#refundOid').html(json.orderNo);
|
||||
$('#realTotalMoney').html('¥ '+json.realTotalMoney);
|
||||
$('#refundMoney').html('¥ '+json.backMoney);
|
||||
$('#useScore').html(json.useScore);
|
||||
$('#scoreMoney').html('¥ '+json.scoreMoney);
|
||||
// 弹出层滚动条
|
||||
var clientH = WST.pageHeight();// 屏幕高度
|
||||
var boxheadH = $('#refund-boxTitle').height();// 弹出层标题高度
|
||||
var contentH = $('#refund-content').height(); // 弹出层内容高度
|
||||
$('#refund-content').css('height',clientH-boxheadH+'px');
|
||||
$("#wst-event8").attr("onclick","javascript:refund("+id+")");
|
||||
reFundDataShow();
|
||||
})
|
||||
}
|
||||
//弹框
|
||||
function reFundDataHide(){
|
||||
$('#shopBox').show();
|
||||
var dataHeight = $("#refundFrame").css('height');
|
||||
var dataWidth = $("#refundFrame").css('width');
|
||||
jQuery('#refundFrame').animate({'right': '-'+dataWidth}, 500);
|
||||
jQuery('#cover').hide();
|
||||
}
|
||||
function reFundDataShow(){
|
||||
jQuery('#cover').attr("onclick","javascript:reFundDataHide();").show();
|
||||
jQuery('#refundFrame').animate({"right": 0}, 500);
|
||||
setTimeout(function(){$('#shopBox').hide();},600)
|
||||
}
|
||||
// 退款
|
||||
function refund(id){
|
||||
|
||||
var params = {};
|
||||
params.refundStatus = $('#refundStatus')[0].checked?1:-1;
|
||||
params.content = $.trim($('#shopRejectReason').val());
|
||||
params.id = id;
|
||||
if(params.refundStatus==-1 && params.content==''){
|
||||
WST.msg('请输入原因','info');
|
||||
return;
|
||||
}
|
||||
$.post(WST.U('wechat/orderrefunds/shoprefund'),params,function(data){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
WST.msg('操作成功','success');
|
||||
history.go(0);
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
// 隐藏对话框
|
||||
function hideDialog(id){
|
||||
$(id).dialog("hide");
|
||||
}
|
||||
|
||||
// 确认收货
|
||||
function receive(oid){
|
||||
hideDialog('#wst-di-prompt');
|
||||
$.post(WST.U('wechat/orders/receive'),{id:oid},function(data){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
reFlashList();// 刷新列表
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*********************** 订单详情 ****************************/
|
||||
//弹框
|
||||
function dataShow(){
|
||||
jQuery('#cover').attr("onclick","javascript:dataHide();").show();
|
||||
jQuery('#frame').animate({"right": 0}, 500);
|
||||
setTimeout(function(){$('#shopBox').hide();},600)
|
||||
|
||||
}
|
||||
function dataHide(){
|
||||
$('#shopBox').show();
|
||||
var dataHeight = $("#frame").css('height');
|
||||
var dataWidth = $("#frame").css('width');
|
||||
jQuery('#frame').animate({'right': '-'+dataWidth}, 500);
|
||||
jQuery('#cover').hide();
|
||||
}
|
||||
|
||||
|
||||
|
||||
function getOrderDetail(oid){
|
||||
$.post(WST.U('wechat/orders/getDetail'),{id:oid},function(data){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status!=-1){
|
||||
var gettpl1 = document.getElementById('detailBox').innerHTML;
|
||||
laytpl(gettpl1).render(json, function(html){
|
||||
$('#content').html(html);
|
||||
// 弹出层滚动条
|
||||
var clientH = WST.pageHeight();// 屏幕高度
|
||||
var boxheadH = $('#boxTitle').height();// 弹出层标题高度
|
||||
var contentH = $('#content').height(); // 弹出层内容高度
|
||||
if((clientH-boxheadH) < contentH){
|
||||
$('#content').css('height',clientH-boxheadH+'px');
|
||||
}
|
||||
dataShow();
|
||||
});
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
}
|
||||
// 跳转到评价页
|
||||
function toAppr(oid){
|
||||
location.href=WST.U('wechat/orders/orderappraise',{'oId':oid});
|
||||
}
|
||||
// 投诉
|
||||
function complain(oid){
|
||||
location.href=WST.U('wechat/ordercomplains/complain',{'oId':oid});
|
||||
}
|
||||
|
||||
//修改价格
|
||||
function editPrice(orderNo){
|
||||
alert('修改价格');
|
||||
}
|
||||
|
||||
// 发货
|
||||
var deliverType
|
||||
function toDeliver(id,type){
|
||||
deliverType = type
|
||||
if(type==0){
|
||||
delivery('orderDelivery('+id+')');
|
||||
}else{
|
||||
WST.dialog('确定发货吗?','orderDelivery('+id+')');
|
||||
}
|
||||
}
|
||||
function delivery(event){
|
||||
$("#wst-event0").attr("onclick","javascript:"+event);
|
||||
$("#deliveryBox").dialog("show");
|
||||
}
|
||||
function orderDelivery(oid){
|
||||
if(deliverType==0){
|
||||
hideDialog('#deliveryBox');
|
||||
}else{
|
||||
WST.dialogHide('prompt');
|
||||
}
|
||||
$.post(WST.U('wechat/orders/deliver'),{id:oid,expressId:$('#expressId').val(),expressNo:$('#expressNo').val()},function(data){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status>0){
|
||||
$('#order-box').html(' ');
|
||||
reFlashList();
|
||||
}else{
|
||||
WST.msg(json.msg,'info');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/*************** 修改价格需要用到的方法 ******************/
|
||||
|
||||
//只能輸入數字和小數點
|
||||
WST.isNumberdoteKey = function(evt){
|
||||
var e = evt || window.event;
|
||||
var srcElement = e.srcElement || e.target;
|
||||
|
||||
var charCode = (evt.which) ? evt.which : event.keyCode;
|
||||
if (charCode > 31 && ((charCode < 48 || charCode > 57) && charCode!=46)){
|
||||
return false;
|
||||
}else{
|
||||
if(charCode==46){
|
||||
var s = srcElement.value;
|
||||
if(s.length==0 || s.indexOf(".")!=-1){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
WST.limitDecimal = function(obj,len){
|
||||
var s = obj.value;
|
||||
if(s.indexOf(".")>-1){
|
||||
if((s.length - s.indexOf(".")-1)>len){
|
||||
obj.value = s.substring(0,s.indexOf(".")+len+1);
|
||||
}
|
||||
}
|
||||
s = null;
|
||||
}
|
Reference in New Issue
Block a user