|
@@ -7,17 +7,18 @@
|
|
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
|
|
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
|
|
<title>订单详情</title>
|
|
|
- <link rel="stylesheet" type="text/css" href="//s.iamberry.com/wechat/aiberle/css/mui.min.css" />
|
|
|
- <link rel="stylesheet" type="text/css" href="//s.iamberry.com/wechat/aiberle/css/iconfont.css" />
|
|
|
+ <link rel="stylesheet" type="text/css" href="css/mui.min.css" />
|
|
|
+ <link rel="stylesheet" type="text/css" href="css/iconfont.css" />
|
|
|
<link rel="stylesheet" type="text/css" href="css/main.css" />
|
|
|
<script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script>
|
|
|
<script>
|
|
|
//屏蔽分享
|
|
|
-// document.addEventListener('WeixinJSBridgeReady', function onBridgeReady() {
|
|
|
-// WeixinJSBridge.call('hideOptionMenu');
|
|
|
-// });
|
|
|
+ // document.addEventListener('WeixinJSBridgeReady', function onBridgeReady() {
|
|
|
+ // WeixinJSBridge.call('hideOptionMenu');
|
|
|
+ // });
|
|
|
</script>
|
|
|
</head>
|
|
|
+
|
|
|
<body>
|
|
|
<div class="loading-bg">
|
|
|
<div class="mui-loading">
|
|
@@ -28,44 +29,44 @@
|
|
|
</div>
|
|
|
<div class="mui-content">
|
|
|
<div style="margin:14px 14px 0 14px;background-color: #f3f3f3;text-align: center;">
|
|
|
- <ul class="mui-table-view mui-table-view-striped my-grid-view-no mui-table-view-condensed">
|
|
|
- <li class="mui-table-view-cell" style="background-color: #f3f3f3;border-radius: 5px;padding: 11px 8px;">
|
|
|
- <div class="mui-table" style="height: 80px;">
|
|
|
- <div class="mui-table-cell mui-col-xs-12 table-middle" style="display: none;">
|
|
|
- <div style="height: 20px;position: relative;width: 150px; margin: 0 auto;"><span class="iconfont icon-jia" style="position: absolute;left:0%;top: 0;font-size: 20px;"></span>添加收货地址</div>
|
|
|
- </div>
|
|
|
- <div class="mui-table-cell mui-col-xs-1 mui-text-left table-middle">
|
|
|
- <p><span class="iconfont icon-dingwei"></span></p>
|
|
|
- </div>
|
|
|
- <div class="mui-table-cell mui-col-xs-10 mui-text-left table-middle">
|
|
|
- <div>收货人:林笑笑 <span class="mui-pull-right">16899996678</span></div>
|
|
|
- <p>收货地址:广东省深圳市福田区莲花街道深圳特区 报业大厦12b</p>
|
|
|
- </div>
|
|
|
- <div class="mui-table-cell mui-col-xs-1 mui-text-right table-middle">
|
|
|
- <p><span class="mui-icon mui-icon-arrowright"></span></p>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </li>
|
|
|
- </ul>
|
|
|
+ <ul class="mui-table-view mui-table-view-striped my-grid-view-no mui-table-view-condensed">
|
|
|
+ <li class="mui-table-view-cell" style="background-color: #f3f3f3;border-radius: 5px;padding: 11px 8px;">
|
|
|
+ <div class="mui-table" style="height: 80px;">
|
|
|
+ <div class="mui-table-cell mui-col-xs-12 table-middle" style="display: none;">
|
|
|
+ <div style="height: 20px;position: relative;width: 150px; margin: 0 auto;"><span class="iconfont icon-jia" style="position: absolute;left:0%;top: 0;font-size: 20px;"></span></div>
|
|
|
+ </div>
|
|
|
+ <div class="mui-table-cell mui-col-xs-1 mui-text-left table-middle">
|
|
|
+ <p><span class="iconfont icon-dingwei"></span></p>
|
|
|
+ </div>
|
|
|
+ <div class="mui-table-cell mui-col-xs-10 mui-text-left table-middle">
|
|
|
+ <div><span id="addressName"></span> <span class="mui-pull-right" id="salesAddressTel"></span></div>
|
|
|
+ <p id="addressInfo"></p>
|
|
|
+ </div>
|
|
|
+ <div class="mui-table-cell mui-col-xs-1 mui-text-right table-middle">
|
|
|
+ <!--<p><span class="mui-icon mui-icon-arrowright"></span></p>-->
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
</div>
|
|
|
<div class="clearing-box">
|
|
|
<ul class="mui-table-view mui-table-view-striped my-grid-view-no mui-table-view-condensed shopping-cart-list">
|
|
|
-
|
|
|
+
|
|
|
</ul>
|
|
|
<ul class="mui-table-view my-view-no-top">
|
|
|
<li class="mui-table-view-cell cl-red" style="padding: 11px 2px;">
|
|
|
- 共2件<span class="mui-pull-right">合计:¥5998.00</span>
|
|
|
+ 共2件<span class="mui-pull-right">合计:¥<span id="salesYetAmount"></span>5998.00</span>
|
|
|
</li>
|
|
|
</ul>
|
|
|
<ul class="my-table-view">
|
|
|
<li>
|
|
|
- 订单状态:已发货
|
|
|
+ 订单状态:<span id="statusName"></span>
|
|
|
</li>
|
|
|
<li>
|
|
|
- 订单编号:12914903247082750294
|
|
|
+ 订单编号:<span id="orderId"></span>
|
|
|
</li>
|
|
|
<li>
|
|
|
- 下单时间:2017-11-23 12:12:12
|
|
|
+ 下单时间:<span id="salesCreateDate"></span>
|
|
|
</li>
|
|
|
</ul>
|
|
|
<textarea id="textarea" rows="1" placeholder="如您选择退款,请先输入退款原因!" style="background-color: #f9f9f9;border: 0;margin:0;padding: 15px;font-size: 14px;"></textarea>
|
|
@@ -73,74 +74,129 @@
|
|
|
<button type="button" class="mui-btn my-btn-request" disabled="disabled">我要退款</button>
|
|
|
</div>
|
|
|
</div>
|
|
|
-
|
|
|
+
|
|
|
</div>
|
|
|
- <script src="//s.iamberry.com/wechat/aiberle/js/mui.min.js"></script>
|
|
|
- <script src="//s.iamberry.com/wechat/aiberle/js/jquery-2.1.1.min.js"></script>
|
|
|
+ <script src="js/mui.min.js"></script>
|
|
|
+ <script src="js/jquery-2.1.1.min.js"></script>
|
|
|
<script src="js/main.js"></script>
|
|
|
<script>
|
|
|
- var orderId=getParam("orderId");
|
|
|
- var isPay = true; // 是否在请求支付,false表示正在请求,true可以请求
|
|
|
- var isEfficacious = true; //商品是否有效,有效则可以支付,无效则不能支付
|
|
|
- mui.ready(function(){
|
|
|
-
|
|
|
-// var str="";
|
|
|
-// for (i=0;i<3;i++) {
|
|
|
-// str+='<div class="mui-table"><div class="mui-table-cell mui-col-xs-4"><img class="mui-media-object wh-100" src="images/chanpin-1.jpg"></div><div class="mui-table-cell table-middle mui-col-xs-8">Aiberle美国智能净饮水一体机<h6>颜色:优雅白<span class="center">数量:2</span></h6><div>¥2999.00</div><h6>(赠品:美国aiberle咖啡杯 数量:3)</h6></div></div>';
|
|
|
-// }
|
|
|
-// document.querySelector('.shopping-cart-list').innerHTML=str;
|
|
|
- var table = document.body.querySelector('.shopping-cart-list');
|
|
|
-$.ajax(base_path+'/wechat/cart/getShopOrderByOrderId', {
|
|
|
- data: {
|
|
|
- orderId: orderId
|
|
|
- },
|
|
|
- dataType: 'json',
|
|
|
- xhrFields: {
|
|
|
- withCredentials: true
|
|
|
- },
|
|
|
- crossDomain: true,
|
|
|
- type: 'post',
|
|
|
- timeout: 15000,
|
|
|
- success: function(dt) {
|
|
|
- //服务器返回响应
|
|
|
- if(dt.isRedirect) {
|
|
|
- location.href = dt.redirectURL;
|
|
|
- } else {
|
|
|
- if(dt.status) {
|
|
|
- console.log(dt)
|
|
|
- mui.each(dt.data.orderItemList,function(){
|
|
|
-
|
|
|
- });
|
|
|
- document.querySelector('.loading-bg').style.display = 'none';
|
|
|
- }
|
|
|
- }
|
|
|
- },
|
|
|
- error: function(xhr, type, errorThrown) {
|
|
|
- console.log(xhr);
|
|
|
- }
|
|
|
- });
|
|
|
-});
|
|
|
-
|
|
|
+ var orderId = getParam("orderId");
|
|
|
+ var isPay = true; // 是否在请求支付,false表示正在请求,true可以请求
|
|
|
+ var isEfficacious = true; //商品是否有效,有效则可以支付,无效则不能支付
|
|
|
+ mui.ready(function() {
|
|
|
|
|
|
+ // var str="";
|
|
|
+ // for (i=0;i<3;i++) {
|
|
|
+ // str+='<div class="mui-table"><div class="mui-table-cell mui-col-xs-4"><img class="mui-media-object wh-100" src="images/chanpin-1.jpg"></div><div class="mui-table-cell table-middle mui-col-xs-8">Aiberle美国智能净饮水一体机<h6>颜色:优雅白<span class="center">数量:2</span></h6><div>¥2999.00</div><h6>(赠品:美国aiberle咖啡杯 数量:3)</h6></div></div>';
|
|
|
+ // }
|
|
|
+ // document.querySelector('.shopping-cart-list').innerHTML=str;
|
|
|
+ var table = document.body.querySelector('.shopping-cart-list');
|
|
|
+ $.ajax(base_path + '/wechat/cart/getShopOrderByOrderId', {
|
|
|
+ data: {
|
|
|
+ orderId: orderId
|
|
|
+ },
|
|
|
+ dataType: 'json',
|
|
|
+ xhrFields: {
|
|
|
+ withCredentials: true
|
|
|
+ },
|
|
|
+ crossDomain: true,
|
|
|
+ type: 'post',
|
|
|
+ timeout: 15000,
|
|
|
+ success: function(dt) {
|
|
|
+ //服务器返回响应
|
|
|
+ if(dt.isRedirect) {
|
|
|
+ location.href = dt.redirectURL;
|
|
|
+ } else {
|
|
|
+ if(dt.status) {
|
|
|
+ console.log(dt)
|
|
|
+ var order = dt.data;
|
|
|
+
|
|
|
+ $("#addressInfo").html(order.salesAddressInfo);
|
|
|
+ $("#addressName").html(order.salesAddressName);
|
|
|
+ $("#salesAddressTel").html(order.salesAddressTel);
|
|
|
+
|
|
|
+ var str = '';
|
|
|
+ mui.each(order.orderItemList, function(index) {
|
|
|
+ str += '<div class="mui-table"><div class="mui-table-cell mui-col-xs-5"><img class="mui-media-object wh-100" src="'+ this.itemProductPic +'"></div><div class="mui-table-cell table-middle mui-col-xs-7" style="line-height:2.5">'+ this.itemProductName +'<h6>颜色:'+ this.productColor +'<span class="center">数量:'+ this.itemNum +'</span></h6><div>¥'+ accDiv(this.itemProductDiscount,100) +'</div></div></div>';
|
|
|
+ });
|
|
|
+ document.querySelector('.shopping-cart-list').innerHTML = str;
|
|
|
+ document.querySelector('.loading-bg').style.display = 'none';
|
|
|
+
|
|
|
+ /*订单状态*/
|
|
|
+ var statusName = "";
|
|
|
+ switch (parseInt(order.salesStatus)){
|
|
|
+ case 0 :
|
|
|
+ statusName = "取消订单";
|
|
|
+ break;
|
|
|
+ case 1 :
|
|
|
+ statusName = "待支付";
|
|
|
+ break;
|
|
|
+ case 2 :
|
|
|
+ statusName = "已支付";
|
|
|
+ break;
|
|
|
+ case 3 :
|
|
|
+ statusName = "退款申请中";
|
|
|
+ break;
|
|
|
+ case 4 :
|
|
|
+ statusName = "已退款";
|
|
|
+ break;
|
|
|
+ case 5 :
|
|
|
+ statusName = "已发货";
|
|
|
+ break;
|
|
|
+ case 6 :
|
|
|
+ statusName = "申请退货中";
|
|
|
+ break;
|
|
|
+ case 7 :
|
|
|
+ statusName = "退货中";
|
|
|
+ break;
|
|
|
+ case 8 :
|
|
|
+ statusName = "订单退货完成";
|
|
|
+ break;
|
|
|
+ case 9 :
|
|
|
+ statusName = "换货中";
|
|
|
+ break;
|
|
|
+ case 10 :
|
|
|
+ statusName = "换货完成";
|
|
|
+ break;
|
|
|
+ case 11 :
|
|
|
+ statusName = "申请换货中";
|
|
|
+ break;
|
|
|
+ case 12 :
|
|
|
+ statusName = "订单完成";
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ $("#statusName").html(statusName);
|
|
|
+ $("#orderId").html(order.salesOrderid);
|
|
|
+ $("#salesCreateDate").html(order.salesCreateDate);
|
|
|
+ $("#salesYetAmount").html(order.salesYetAmount);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error: function(xhr, type, errorThrown) {
|
|
|
+ console.log(xhr);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ });
|
|
|
|
|
|
-mui('body').on('tap','.go_web_shop',function(){
|
|
|
- mui.openWindow({
|
|
|
- url: 'chanpin_list.html'
|
|
|
- });
|
|
|
-});
|
|
|
+ mui('body').on('tap', '.go_web_shop', function() {
|
|
|
+ mui.openWindow({
|
|
|
+ url: 'chanpin_list.html'
|
|
|
+ });
|
|
|
+ });
|
|
|
|
|
|
-mui('body').on('tap','.go-clearing',function(){
|
|
|
- if($("input[type='checkbox']:checked").length>0){
|
|
|
- mui.openWindow({
|
|
|
- url: 'clearing.html'
|
|
|
- });
|
|
|
- }else{
|
|
|
- mui.alert('您没有选中任何商品', '爱贝源-消息提醒', function() {
|
|
|
- console.log("您关闭了警告框");
|
|
|
- });
|
|
|
- }
|
|
|
-});
|
|
|
-
|
|
|
+ mui('body').on('tap', '.go-clearing', function() {
|
|
|
+ if($("input[type='checkbox']:checked").length > 0) {
|
|
|
+ mui.openWindow({
|
|
|
+ url: 'clearing.html'
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ mui.alert('您没有选中任何商品', '爱贝源-消息提醒', function() {
|
|
|
+ console.log("您关闭了警告框");
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
</script>
|
|
|
</body>
|
|
|
|