|
|
@ -54,7 +54,8 @@ |
|
|
|
<view class="mask" @click="changeMenu(index)"> |
|
|
|
<view class="mask" @click="changeMenu(index)"> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="menulist"> |
|
|
|
<view class="menulist"> |
|
|
|
<view class="" v-if="item.order_status == OrderStatusEnum.COMPLETED.value &&item.pay_status == PayStatusEnum.SUCCESS.value" |
|
|
|
<view class="" |
|
|
|
|
|
|
|
v-if="item.order_status == OrderStatusEnum.COMPLETED.value &&item.pay_status == PayStatusEnum.SUCCESS.value" |
|
|
|
@click="onInvoicing(item.order_id,item)"> |
|
|
|
@click="onInvoicing(item.order_id,item)"> |
|
|
|
申请开票 |
|
|
|
申请开票 |
|
|
|
</view> |
|
|
|
</view> |
|
|
@ -273,9 +274,14 @@ |
|
|
|
app.getOrderList(1) |
|
|
|
app.getOrderList(1) |
|
|
|
}, |
|
|
|
}, |
|
|
|
changeMenu(index) { |
|
|
|
changeMenu(index) { |
|
|
|
this.list.forEach((item, ind) => { |
|
|
|
let that = this; |
|
|
|
item.menushow = !item.menushow; |
|
|
|
this.list.map((item, inx) => { |
|
|
|
}); |
|
|
|
if (index == inx) { |
|
|
|
|
|
|
|
item.menushow = item.menushow == true ? false : true |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
item.menushow = false |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
toggleImage() { |
|
|
|
toggleImage() { |
|
|
|
this.isToggle = !this.isToggle |
|
|
|
this.isToggle = !this.isToggle |
|
|
@ -307,7 +313,7 @@ |
|
|
|
}); |
|
|
|
}); |
|
|
|
if (status == 200) { |
|
|
|
if (status == 200) { |
|
|
|
uni.hideLoading(); |
|
|
|
uni.hideLoading(); |
|
|
|
this.list = this.arrayUnique(this.list.concat(data.list.data),'order_id') |
|
|
|
this.list = this.arrayUnique(this.list.concat(data.list.data), 'order_id') |
|
|
|
this.total = data.list.total |
|
|
|
this.total = data.list.total |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
@ -334,7 +340,7 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
onCopyLink(str){ |
|
|
|
onCopyLink(str) { |
|
|
|
uni.setClipboardData({ |
|
|
|
uni.setClipboardData({ |
|
|
|
data: str, // 这里是个坑接受字符串类型 value转化为字符串 |
|
|
|
data: str, // 这里是个坑接受字符串类型 value转化为字符串 |
|
|
|
success: function() { |
|
|
|
success: function() { |
|
|
@ -360,9 +366,11 @@ |
|
|
|
// 显示成功信息 |
|
|
|
// 显示成功信息 |
|
|
|
app.$toast(result.message) |
|
|
|
app.$toast(result.message) |
|
|
|
// 刷新订单列表 |
|
|
|
// 刷新订单列表 |
|
|
|
|
|
|
|
setTimeout(() => { |
|
|
|
app.list = [] |
|
|
|
app.list = [] |
|
|
|
app.pageNum = 1 |
|
|
|
app.pageNum = 1 |
|
|
|
app.getOrderList() |
|
|
|
app.getOrderList() |
|
|
|
|
|
|
|
}, 1500) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -382,10 +390,11 @@ |
|
|
|
.then(result => { |
|
|
|
.then(result => { |
|
|
|
// 显示成功信息 |
|
|
|
// 显示成功信息 |
|
|
|
app.$toast(result.message) |
|
|
|
app.$toast(result.message) |
|
|
|
// 刷新订单列表 |
|
|
|
setTimeout(() => { |
|
|
|
app.list = [] |
|
|
|
app.list = [] |
|
|
|
app.pageNum = 1 |
|
|
|
app.pageNum = 1 |
|
|
|
app.getOrderList() |
|
|
|
app.getOrderList() |
|
|
|
|
|
|
|
}, 1500) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -411,9 +420,11 @@ |
|
|
|
// 显示成功信息 |
|
|
|
// 显示成功信息 |
|
|
|
app.$success(result.message) |
|
|
|
app.$success(result.message) |
|
|
|
// 刷新订单列表 |
|
|
|
// 刷新订单列表 |
|
|
|
|
|
|
|
setTimeout(() => { |
|
|
|
app.list = [] |
|
|
|
app.list = [] |
|
|
|
app.pageNum = 1 |
|
|
|
app.pageNum = 1 |
|
|
|
app.getOrderList() |
|
|
|
app.getOrderList() |
|
|
|
|
|
|
|
}, 1500) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -462,13 +473,13 @@ |
|
|
|
}, |
|
|
|
}, |
|
|
|
//数组对象去重 |
|
|
|
//数组对象去重 |
|
|
|
arrayUnique(arr, name) { |
|
|
|
arrayUnique(arr, name) { |
|
|
|
var hash = {}; |
|
|
|
var hash = {}; |
|
|
|
return arr.reduce(function (item, next) { |
|
|
|
return arr.reduce(function(item, next) { |
|
|
|
hash[next[name]] |
|
|
|
hash[next[name]] ? |
|
|
|
? "" |
|
|
|
"" : |
|
|
|
: (hash[next[name]] = true && item.push(next)); |
|
|
|
(hash[next[name]] = true && item.push(next)); |
|
|
|
return item; |
|
|
|
return item; |
|
|
|
}, []); |
|
|
|
}, []); |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 点击去物流 |
|
|
|
// 点击去物流 |
|
|
|
onLogistics(orderId, item) { |
|
|
|
onLogistics(orderId, item) { |
|
|
|