|
@@ -103,7 +103,6 @@
|
|
|
},
|
|
|
orderData: {
|
|
|
orderId: '',
|
|
|
- orderStatus: 1,
|
|
|
addOrderTime: '',
|
|
|
recName: '',
|
|
|
recMobile: '',
|
|
@@ -135,59 +134,6 @@
|
|
|
},
|
|
|
onLoad(options) {
|
|
|
this.userData = uni.getStorageSync("userData")
|
|
|
- this.orderStatus = options.orderStatus
|
|
|
- switch (this.orderStatus) {
|
|
|
- case '1':
|
|
|
- this.buttonGroup = [{
|
|
|
- text: '取消订单',
|
|
|
- backgroundColor: '#75BD60',
|
|
|
- color: '#fff'
|
|
|
- }, {
|
|
|
- text: '立即支付',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }]
|
|
|
- break;
|
|
|
- case '2':
|
|
|
- this.buttonGroup = [{
|
|
|
- text: '申请售后',
|
|
|
- backgroundColor: '#75BD60',
|
|
|
- color: '#fff'
|
|
|
- }, {
|
|
|
- text: '自助采摘',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }]
|
|
|
- break;
|
|
|
- case '3':
|
|
|
- this.buttonGroup = [{
|
|
|
- text: '申请售后',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }, {
|
|
|
- text: '确认收货',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }, {
|
|
|
- text: '追踪物流',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }]
|
|
|
- break;
|
|
|
- case '4':
|
|
|
- this.buttonGroup = [{
|
|
|
- text: '申请售后',
|
|
|
- backgroundColor: '#75BD60',
|
|
|
- color: '#fff'
|
|
|
- }]
|
|
|
- break;
|
|
|
- default:
|
|
|
- this.buttonGroup = [{
|
|
|
- text: '申请售后',
|
|
|
- backgroundColor: '#52A63A',
|
|
|
- color: '#fff'
|
|
|
- }]
|
|
|
- }
|
|
|
NET.request(API.getOrderDetail, {
|
|
|
flag: 1,
|
|
|
orderId: options.orderId,
|
|
@@ -200,7 +146,59 @@
|
|
|
} else {
|
|
|
this.goodType = 2
|
|
|
}
|
|
|
- if (this.orderStatus == 4 && this.orderData.evaluateReplyStatus == 1) {
|
|
|
+ switch (JSON.stringify(this.orderData.orderStatus)) {
|
|
|
+ case '1':
|
|
|
+ this.buttonGroup = [{
|
|
|
+ text: '取消订单',
|
|
|
+ backgroundColor: '#75BD60',
|
|
|
+ color: '#fff'
|
|
|
+ }, {
|
|
|
+ text: '立即支付',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }]
|
|
|
+ break;
|
|
|
+ case '2':
|
|
|
+ this.buttonGroup = [{
|
|
|
+ text: '申请售后',
|
|
|
+ backgroundColor: '#75BD60',
|
|
|
+ color: '#fff'
|
|
|
+ }, {
|
|
|
+ text: '自助采摘',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }]
|
|
|
+ break;
|
|
|
+ case '3':
|
|
|
+ this.buttonGroup = [{
|
|
|
+ text: '申请售后',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }, {
|
|
|
+ text: '确认收货',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }, {
|
|
|
+ text: '追踪物流',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }]
|
|
|
+ break;
|
|
|
+ case '4':
|
|
|
+ this.buttonGroup = [{
|
|
|
+ text: '申请售后',
|
|
|
+ backgroundColor: '#75BD60',
|
|
|
+ color: '#fff'
|
|
|
+ }]
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ this.buttonGroup = [{
|
|
|
+ text: '申请售后',
|
|
|
+ backgroundColor: '#52A63A',
|
|
|
+ color: '#fff'
|
|
|
+ }]
|
|
|
+ }
|
|
|
+ if (this.orderData.orderStatus == 4 && this.orderData.evaluateReplyStatus == 1) {
|
|
|
this.buttonGroup.push({
|
|
|
text: '评价',
|
|
|
backgroundColor: '#52A63A',
|
|
@@ -259,7 +257,7 @@
|
|
|
},
|
|
|
// 操作
|
|
|
orderHandle(e) {
|
|
|
- if (this.orderStatus == 1) {
|
|
|
+ if (this.orderData.orderStatus == 1) {
|
|
|
if (e.index == 0) {
|
|
|
// 取消订单
|
|
|
this.modalContent = '请确定是否取消订单'
|
|
@@ -287,12 +285,12 @@
|
|
|
})
|
|
|
})
|
|
|
} else {
|
|
|
- if (this.orderStatus == 2) {
|
|
|
+ if (this.orderData.orderStatus == 2) {
|
|
|
// 自助采摘
|
|
|
uni.navigateTo({
|
|
|
url: '/pagesGood/pickVideo?orderId=' + this.orderData.orderId
|
|
|
});
|
|
|
- } else if (this.orderStatus == 3) {
|
|
|
+ } else if (this.orderData.orderStatus == 3) {
|
|
|
if (e.index == 1) {
|
|
|
// 确认收货
|
|
|
this.modalContent = '请确定是否确认收货'
|
|
@@ -373,7 +371,7 @@
|
|
|
}
|
|
|
},
|
|
|
// 跳转留言列表
|
|
|
- goToMessage(){
|
|
|
+ goToMessage() {
|
|
|
uni.navigateTo({
|
|
|
url: '/pagesMain/messageList?orderId=' + this.orderData.orderId + '&tenantCode=' + this.orderData.tenantCode
|
|
|
});
|
|
@@ -758,12 +756,13 @@
|
|
|
.message-img-box {
|
|
|
width: 100%;
|
|
|
float: left;
|
|
|
- .message-img{
|
|
|
+
|
|
|
+ .message-img {
|
|
|
width: 76px;
|
|
|
height: 76px;
|
|
|
object-fit: cover;
|
|
|
float: left;
|
|
|
- margin: 0 10px 10px 0;
|
|
|
+ margin: 0 10px 10px 0;
|
|
|
}
|
|
|
}
|
|
|
}
|