From 2bf46d983ae33f1453f0e8e054c3dd02b6f0b41f Mon Sep 17 00:00:00 2001
From: Gdpao <1341331954@qq.com>
Date: Fri, 14 Aug 2020 20:48:14 +0800
Subject: [PATCH] gdpaoup
---
components/order-item/index.vue | 11 ++++++++---
components/order-item/testlist.vue | 1 +
pages/index/details.vue | 21 ++++++++++++++-------
pages/index/index.vue | 2 ++
4 files changed, 25 insertions(+), 10 deletions(-)
diff --git a/components/order-item/index.vue b/components/order-item/index.vue
index b825eb4..ba2b481 100644
--- a/components/order-item/index.vue
+++ b/components/order-item/index.vue
@@ -19,6 +19,7 @@
共{{info.count_number}}件商品
实付¥{{info.order_amount}}
+ {{ info.payment_time.slice(5,16) }}
@@ -48,14 +49,14 @@ export default {
height: 220rpx;
background: rgba(255,255,255,1);
border-radius: 10rpx;
- padding: 30rpx;
+ padding: 20rpx 10rpx;
display: flex;
align-items: center;
> image {
width: 160rpx;
height: 160rpx;
flex-shrink: 0;
- margin-right: 25rpx;
+ margin-right: 20rpx;
}
.goods {
display: flex;
@@ -82,9 +83,10 @@ export default {
margin-bottom: 30rpx;
}
.info {
- width: 100%;
+ width: 470rpx;
display: flex;
align-items: center;
+ justify-content: space-between;
font-size: 26rpx;
color: rgba(102,102,102,1);
.price {
@@ -94,6 +96,9 @@ export default {
}
}
}
+ .time {
+ font-size: 20rpx;
+ }
}
}
\ No newline at end of file
diff --git a/components/order-item/testlist.vue b/components/order-item/testlist.vue
index a5bd6aa..1b77b24 100644
--- a/components/order-item/testlist.vue
+++ b/components/order-item/testlist.vue
@@ -16,6 +16,7 @@
共{{info.goods_try_num}}件商品
实付¥{{info.price}}
+
diff --git a/pages/index/details.vue b/pages/index/details.vue
index 591a6e9..95361f9 100644
--- a/pages/index/details.vue
+++ b/pages/index/details.vue
@@ -181,9 +181,6 @@ export default {
};
},
onLoad(option) {
- let pages = getCurrentPages();
- let prePage = pages[pages.length - 2];
- console.log(prePage);
this.type = option.type;
console.log(this.type)
this.orderid = option.id;
@@ -269,11 +266,18 @@ export default {
//
confirm() {
this.showRefunds = false;
+ if (!this.refundid) {
+ this.$refs.uToast.show({
+ title: "请选择商品",
+ type: "warning"
+ });
+ return;
+ }
if (this.cur == 0) {
// 确定退款
this.$u.api.refund({
refund_id: this.refundid,
- seller_state: 2,
+ seller_state: 3,
seller_message: ""
}).then(res => {
if (res.errCode != 0) {
@@ -286,18 +290,21 @@ export default {
title: res.message,
type: 'success'
});
+ let pages = getCurrentPages();
+ let prePage = pages[pages.length - 2];
+ console.log(prePage.$vm);
+ prePage.$vm.del_id = this.orderid;
uni.navigateBack({
delta: 1
});
- console.log(res);
}
});
} else {
// 不进行退款
this.$u.api.refund({
refund_id: this.refundid,
- seller_state:3,
- seller_message:""
+ seller_state: 2,
+ seller_message: ""
}).then(res => {
if (res.errCode != 0) {
this.$refs.uToast.show({
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 2ea0062..454d64b 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -135,6 +135,7 @@ export default {
carlist: [], //可投诉订单列表
reportinfo: null, //投诉信息
reportcontent: '', //投诉内容
+ del_id: 0, // 删除id
};
},
onLoad() {
@@ -152,6 +153,7 @@ export default {
},
onShow() {
this.publishstate = false;
+ this.getallorder(1);
},
onReachBottom() {
this.num++;
--
2.45.2