-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpayment.html
155 lines (146 loc) · 4.62 KB
/
payment.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>支付结果</title>
<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<!--标准mui.css-->
<link rel="stylesheet" href="css/mui.min.css">
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/font-awesome.css">
<!--App自定义的css-->
<link rel="stylesheet" type="text/css" href="css/app.css" />
<script src="js/mui.min.js"></script>
<script src="js/jquery.min.js"></script>
<script src="js/app.js"></script>
<script src="js/vue.min.js"></script>
<script type="text/javascript" src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js"></script>
</head>
<body>
<!--<header class="mui-bar mui-bar-nav">
<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
<h1 class="mui-title">支付结果</h1>
</header>-->
<nav class="mui-bar mui-bar-tab no-border">
<a class=" mui-col-xs-12 mui-btn mui-btn-blue" onclick="goIndex()">
返回首页
</a>
</nav>
<div class="mui-content my" id="content" v-cloak>
<div class="mui-card">
<div class="mui-table-view">
<div class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img src="images/success.png" class="mui-media-object mui-pull-left mui-media-objectx" />
<div class="mui-media-body" v-if="data.goods != null">
<h5>{{data.goods.title}}</h5>
<h5>{{data.goods.subTitle}}</h5>
</div>
</a>
</div>
</div>
</div>
<div class="mui-card orderdetail">
<div class="title">订单详情</div>
<div class=" pos-rel">
<p>订单号:<span>{{data.ordernumber}}</span></p>
<p>下单时间:<span>{{data.ordertime}}</span> </p>
<p v-if="data.goods != null">单价:<span class=" blue">¥{{data.goods.price}}</span></p>
<p>商品数量:<span>{{data.size}}</span></p>
<p>金额:<span class="blue">¥{{data.amount}}</span></p>
<p> 付款方式:<span>微信支付</span></p>
<p> 付款时间:<span>{{data.paytime}}</span></p>
<div class="pos-abs" v-if="data.goods != null">
<img :src="data.goods.cover" class=" img-responsive" /></div>
</div>
</div>
<ul class="mui-table-view orderdetail">
<li class="mui-table-view-cell" v-on:click="toNavigation(data.goods)">
<a class="mui-navigate-right">
到店自取地址
</a>
<p v-if="data.goods != null">
{{data.goods.address}}
</p>
</li>
<li class="mui-table-view-cell" v-for="item in data.links" v-on:click="toDetail(item.lineid)">
<a class="mui-navigate-right">
{{item.linename}}
</a>
<div class=" mui-col-sm-12">
<span><i class=" fa fa-map-marker"></i>{{item.recordcount}}</span>
<span><i class="fa fa-clock-o"></i>{{item.timelabel}}min</span>
</div>
</li>
</ul>
</div>
<script type="text/javascript">
var param = getRequest();
var orderId = param.orderId;
function goIndex() {
console.log("回首页");
wx.miniProgram.redirectTo({
url: '/pages/index/index'
})
}
var vue1 = new Vue({
el: '#content',
data: {
data: {}
},
updated: function() {
this.$nextTick(function() {})
},
methods: {
chooseCity: function(event) {
wx.miniProgram.navigateBack();
},
toDetail: function(id) {
console.log("到详情页");
myLocalStorage.setItem("lineid", id)
wx.miniProgram.navigateTo({
url: '/pages/detail/detail'
})
},
toNavigation: function(goods) {
console.log(goods);
console.log("到导航页");
myLocalStorage.setItem("goods", goods)
wx.miniProgram.navigateTo({
url: '/pages/navigation/navigation'
})
}
}
});
function loadOrderDetail() {
$.ajax({
dataType: "json",
type: "get",
headers: {
'Content-Type': 'application/json',
'token': myLocalStorage.getItem("token")
},
url: basePath + "services/xcx/goods/order/" + orderId,
data: {},
success: function(res) {
if(res.status == 0) {
vue1.data = res.result;
} else {
mui.toast(
mui.toast(res.errmsg)
)
}
},
error: function(result) {
mui.toast("请求遇到问题!")
}
});
}
$(function() {
loadOrderDetail();
})
</script>
</body>
</html>