takedetail.js
1.1 KB
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
var oid=GetQueryString("oid");
console.log(oid);
new Vue({
el:'#takedetail',
filters:{
stoptype:function(type){
return type=='1'?'自提':type=='2'?'堂食':""
},
payment:function(pay){
return pay=='1'?'余额支付':pay=='2'?'微信支付':""
}
},
data:{
orderinfo:[],
ordergood:[]
},
created: function() {
this.details();
},
methods: {
//获取信息
details: function() {
var that = this;
var url = '/UserCenter/orderDetail'
var params = {
oid:oid
}
ajaxsend(url, params, function(res) {
/*console.log(JSON.stringify(res))*/
console.log(res);
var data=res.data;
console.log(data)
that.orderinfo=data.order_info;
that.ordergood=data.order_goods;
console.log(that.orderinfo);
console.log(that.ordergood);
})
},
//导航去取货
navigation:function(){
var that = this;
var url = '/Map/goMap'
var params = {
oid:oid
}
ajaxsend(url, params, function(res) {
/*console.log(JSON.stringify(res))*/
console.log(res);
})
},
},
})