zs 2 gadi atpakaļ
vecāks
revīzija
f3a1937eeb
2 mainītis faili ar 30 papildinājumiem un 10 dzēšanām
  1. 5 1
      pagesMy/order/index.vue
  2. 25 9
      pagesMy/order/info.vue

+ 5 - 1
pagesMy/order/index.vue

@@ -573,7 +573,11 @@
 				})
 				})
 				if (res.errcode == '0') {
 				if (res.errcode == '0') {
 					that.$set(that, `statusList`, res.data);
 					that.$set(that, `statusList`, res.data);
-					var menu = res.data.map((item) => {
+					let status = res.data.filter((i) => {
+						return i.value != '-2' && i.value != '-3';
+					});
+					console.log(status);
+					var menu = status.map((item) => {
 						return {
 						return {
 							title: item.label,
 							title: item.label,
 							active: item.value
 							active: item.value

+ 25 - 9
pagesMy/order/info.vue

@@ -25,7 +25,7 @@
 							<view class="two_0">
 							<view class="two_0">
 								<text>{{info.zhStatus||'未识别'}}</text>
 								<text>{{info.zhStatus||'未识别'}}</text>
 							</view>
 							</view>
-							<view class="two_1" v-if="info.status=='0'">
+							<view class="two_1" v-if="info.status=='0'||is_order=='true'">
 								<view class="list" v-for="(item,index) in info.goods" :key="index">
 								<view class="list" v-for="(item,index) in info.goods" :key="index">
 									<view class="list_1" v-if="item.is_set=='0'">
 									<view class="list_1" v-if="item.is_set=='0'">
 										<view class="r">
 										<view class="r">
@@ -40,7 +40,9 @@
 										<view class="goods" v-for="(tag,indexs) in item.goods" :key="indexs">
 										<view class="goods" v-for="(tag,indexs) in item.goods" :key="indexs">
 											<view class="goods_1">
 											<view class="goods_1">
 												<view class="url">
 												<view class="url">
-													<image class="image" :src="tag.goods.file&&tag.goods.file.length>0?tag.goods.file[0].url:tag.goods.goods.file[0].url" mode=""></image>
+													<image class="image"
+														:src="tag.goods.file&&tag.goods.file.length>0?tag.goods.file[0].url:tag.goods.goods.file[0].url"
+														mode=""></image>
 												</view>
 												</view>
 												<view class="goodsname">
 												<view class="goodsname">
 													{{tag.goods.name}}
 													{{tag.goods.name}}
@@ -71,7 +73,8 @@
 												</view>
 												</view>
 											</view>
 											</view>
 											<view class="goods_2" v-if="tag.gift.length>0">赠品</view>
 											<view class="goods_2" v-if="tag.gift.length>0">赠品</view>
-											<view class="goods_3" v-if="tag.gift.length>0" v-for="(tags,indexx) in tag.gift" :key="indexx">
+											<view class="goods_3" v-if="tag.gift.length>0"
+												v-for="(tags,indexx) in tag.gift" :key="indexx">
 												<view class="left">
 												<view class="left">
 													<view class="name">
 													<view class="name">
 														{{tags.goods_name}}
 														{{tags.goods_name}}
@@ -118,7 +121,9 @@
 										<view v-if="item.is_set=='0'">
 										<view v-if="item.is_set=='0'">
 											<view class="goods_1" v-for="(tag,indexc) in item.goods" :key="indexc">
 											<view class="goods_1" v-for="(tag,indexc) in item.goods" :key="indexc">
 												<view class="url">
 												<view class="url">
-													<image class="image" :src="tag.file&&tag.file.length>0?tag.file[0].url:tag.goods.file[0].url" mode="">
+													<image class="image"
+														:src="tag.file&&tag.file.length>0?tag.file[0].url:tag.goods.file[0].url"
+														mode="">
 													</image>
 													</image>
 												</view>
 												</view>
 												<view class="goodsname">
 												<view class="goodsname">
@@ -135,7 +140,9 @@
 										</view>
 										</view>
 										<view class="goods_1" v-else>
 										<view class="goods_1" v-else>
 											<view class="url">
 											<view class="url">
-												<image class="image" :src="item.file&&item.file.length>0?item.file[0].url:item.goods.file[0].url" mode="">
+												<image class="image"
+													:src="item.file&&item.file.length>0?item.file[0].url:item.goods.file[0].url"
+													mode="">
 												</image>
 												</image>
 											</view>
 											</view>
 											<view class="goodsname">
 											<view class="goodsname">
@@ -161,7 +168,8 @@
 											</view>
 											</view>
 										</view>
 										</view>
 										<view class="goods_2" v-if="item.gift.length>0">赠品</view>
 										<view class="goods_2" v-if="item.gift.length>0">赠品</view>
-										<view class="goods_3" v-if="item.gift.length>0" v-for="(tag,indexx) in item.gift" :key="indexx">
+										<view class="goods_3" v-if="item.gift.length>0"
+											v-for="(tag,indexx) in item.gift" :key="indexx">
 											<view class="left">
 											<view class="left">
 												<view class="name">
 												<view class="name">
 													{{tag.goods_name}}
 													{{tag.goods_name}}
@@ -260,10 +268,18 @@
 				let res;
 				let res;
 				// 待付款
 				// 待付款
 				if (that.id) {
 				if (that.id) {
-					if (JSON.parse(that.is_order)) {
-						res = await that.$api(`/order/${that.id}`);
+					if (that.is_order) {
+						if (JSON.parse(that.is_order)) {
+							res = await that.$api(`/order/${that.id}`);
+						} else {
+							res = await that.$api(`/orderDetail/${that.id}`);
+						}
 					} else {
 					} else {
-						res = await that.$api(`/orderDetail/${that.id}`);
+						if (that.status == '0') {
+							res = await that.$api(`/order/${that.id}`);
+						} else {
+							res = await that.$api(`/orderDetail/${that.id}`);
+						}
 					}
 					}
 					if (res.errcode == '0') {
 					if (res.errcode == '0') {
 						let status = that.statusList.find(i => i.value == res.data.status)
 						let status = that.statusList.find(i => i.value == res.data.status)