Fix:3315 【礼品功能】待发货订单退款详情页不要显示物流信息

This commit is contained in:
linxi
2025-02-28 16:03:30 +08:00
parent 1baf5de741
commit c3d6b25a5e
6 changed files with 70 additions and 23 deletions
+11 -1
View File
@@ -9,6 +9,7 @@
<view class="cover-picker">
<view class="cover-title">选择封面</view>
<swiper
:current="currentIndex"
:autoplay="false"
:circular="true"
:indicator-dots="false"
@@ -43,6 +44,10 @@
<script>
export default {
props: {
index: {
type: Number,
default: 0
},
show: {
type: Boolean,
default: true
@@ -62,7 +67,12 @@ export default {
},
data() {
return {
currentIndex: 0
currentIndex: this.index
}
},
watch: {
index(val) {
this.currentIndex = val
}
},
methods: {
+1 -1
View File
@@ -236,7 +236,7 @@ export default {
}
.auto-text-color {
color: #fff;
font-size: 28rpx;
font-size: 32rpx;
opacity: 0.8;
margin-top: 150rpx;
width: 400rpx;
+9 -5
View File
@@ -12,7 +12,9 @@
<!-- 标题 -->
<view class="title">赠礼须知</view>
<!-- 富文本内容 -->
<u-parse :content="richText" />
<view class="text-wrap">
<u-parse :content="richText" />
</view>
</view>
</u-popup>
</view>
@@ -36,10 +38,12 @@ export default {
</script>
<style lang="scss" scoped>
.popup-content {
width: 600rpx;
.text-wrap{
height: 800rpx;
overflow: auto;
}
.popup-content {
width: 600rpx;
padding:0 40rpx 40rpx 40rpx;
box-sizing: border-box;
.title {
@@ -48,10 +52,10 @@ export default {
font-size: 36rpx;
font-weight: bold;
text-align: center;
margin-bottom: 30rpx;
position: sticky;
top: 0;
background: #fff;
background-color: #fff;
z-index: 11;
}
.close-btn {
+39 -15
View File
@@ -107,7 +107,7 @@
<view class="gift-submit" @click="showPayPicker = true">付款并赠送</view>
</view>
<view class="btn-wrap v12-mt-16 v12-justify-center" v-if="isPayOk">
<view class="gift-submit">再送一份</view>
<view class="gift-submit" @click="makeAgain">再送一份</view>
</view>
<view class="tip-wrap v12-justify-center">
<view class="tip-text v12-mr-1">好友未收下礼包将于24小时后自动退款</view>
@@ -119,6 +119,7 @@
:list="coverList"
:product="goodsInfo.productInfo"
@confirm="onCoverConfirm"
:index="defaultIndex"
:message="message"
/>
<passkeyborad
@@ -139,7 +140,8 @@
<script>
import passkeyborad from '@/components/yzc-paykeyboard/yzc-paykeyboard'
import { getGiftCardSendOrderConfirm, getGiftCardSendOrder, getGiftCardSendOrderAmount } from '@/api/gift'
import { getGiftCardSendOrderConfirm, getGiftCardSendOrder, getGiftCardSendOrderAmount, getGiftCardResend } from '@/api/gift'
import { weappPay } from "@/libs/wechat";
import {mapGetters} from "vuex";
import giftTips from './components/giftTips.vue'
import CoverPicker from './components/CoverPicker.vue'
@@ -176,7 +178,9 @@ export default {
payType: '',
isPayOk: false,
giftKey: '',
payPrice: 0
payPrice: 0,
orderId: '',
defaultIndex:0
}
},
onLoad(opts) {
@@ -200,8 +204,27 @@ export default {
})
},
methods: {
makeAgain() {
const params = {
orderId: this.orderId,
}
getGiftCardResend(params).then(res => {
this.isPayOk = false
this.coverList = [...res.data.giftCardTemplates, res.data.specialGiftCardTemplate]
this.cartId = res.data.cartInfo[0].id
this.giftNotice = res.data.giftCardGiftNotice
this.orderKey = res.data.orderKey
this.goodsInfo = res.data.cartInfo[0]
this.templateId = res.data.specialGiftCardTemplate.id
this.defaultIndex = this.coverList.findIndex(item => item.id === this.templateId)
console.log(this.defaultIndex, 'defaultIndex');
this.selectedCover = res.data.specialGiftCardTemplate.cover
this.giftImage = res.data.specialGiftCardTemplate.image
this.couponId = ''
this.computedPrice(this.goodsInfo.cartNum)
})
},
messageChange(e) {
console.log(e);
this.message = e.substring(0, 30)
},
numberChange(e) {
@@ -247,6 +270,8 @@ export default {
this.templateId = res.data.specialGiftCardTemplate.id
this.selectedCover = res.data.specialGiftCardTemplate.cover
this.giftImage = res.data.specialGiftCardTemplate.image
this.defaultIndex = this.coverList.findIndex(item => item.id === this.templateId)
console.log(this.defaultIndex, 'defaultIndex');
if(!this.couponId) {
this.couponId = res.data.couponList.usable[0] && res.data.couponList.usable[0].id || ''
}
@@ -329,6 +354,7 @@ export default {
});
this.isPayOk = true;
this.giftKey = data.giftCard.code;
this.orderId = data.result.orderId || ''
break;
case "WECHAT_H5_PAY":
// H5支付
@@ -341,12 +367,13 @@ export default {
// 小程序支付
weappPay(data.result.jsConfig).finally(() => {
uni.showToast({
title: res.msg,
icon: "none",
duration: 2000
});
this.isPayOk = true;
this.giftKey = data.giftCard.code;
title: res.msg,
icon: "none",
duration: 2000
});
this.isPayOk = true;
this.giftKey = data.giftCard.code;
this.orderId = data.result.orderId || ''
});
break;
@@ -358,13 +385,10 @@ export default {
break;
}
}) .catch(err => {
console.log(err);
uni.hideLoading();
uni.showToast({
title:
err.msg ||
err.response.data.msg ||
err.response.data.message ||
"创建订单失败",
title:"创建订单失败",
icon: "none",
duration: 2000
});