zs 2 years ago
parent
commit
9a05a24288
3 changed files with 38 additions and 26 deletions
  1. 6 0
      pages.json
  2. 4 26
      pagesMy/order/index.vue
  3. 28 0
      pagesMy/order/service.vue

+ 6 - 0
pages.json

@@ -77,6 +77,12 @@
 						"navigationBarTitleText": "售后列表"
 					}
 				},
+				{
+					"path": "order/service",
+					"style": {
+						"navigationBarTitleText": "选择售后"
+					}
+				},
 				{
 					"path": "discount/index",
 					"style": {

+ 4 - 26
pagesMy/order/index.vue

@@ -101,7 +101,7 @@
 				list: [ //订单列表
 					{
 						shop: '官方自营店',
-						status: '0',
+						status: '3',
 						url: [{
 							name: "20220928155634.jpg",
 							uri: "/files/point/20220928155634.jpg",
@@ -235,31 +235,9 @@
 			},
 			// 申请售后
 			toAfter(e) {
-				const that = this;
-				uni.showModal({
-					title: '提示',
-					content: '确定申请售后吗?',
-					success: async function(res) {
-						if (res.confirm) {
-							const arr = await that.$api(`/order/${e._id}`, 'POST', {
-								status: '-3'
-							});
-							if (arr.errcode == '0') {
-								uni.showToast({
-									title: '申请售后成功',
-									icon: 'none'
-								})
-								that.clearPage();
-								that.search();
-							} else {
-								uni.showToast({
-									title: arr.errmsg,
-									icon: 'none'
-								})
-							}
-						}
-					}
-				});
+				uni.navigateTo({
+					url: `/pagesMy/order/service?id=${e._id}`
+				})
 			},
 			// 申请退款
 			toRefund(e) {

+ 28 - 0
pagesMy/order/service.vue

@@ -0,0 +1,28 @@
+<template>
+	<mobile-frame>
+		选择售后
+	</mobile-frame>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+
+			};
+		},
+		onShow: function() {},
+		onLoad: async function(e) {
+			const that = this;
+			that.$set(that, `id`, e.id || '');
+			that.search();
+		},
+		methods: {
+			search() {},
+		}
+	}
+</script>
+
+<style lang="scss">
+
+</style>