|
|
@@ -74,8 +74,8 @@ const selectedCoupon = ref({
|
|
|
minAmount: 0,
|
|
|
name: '',
|
|
|
expireDate: '',
|
|
|
- validDays: 90,
|
|
|
- description: '周一、周五不可用'
|
|
|
+ specifiedDay: '',
|
|
|
+ supplementaryInstruction: ''
|
|
|
});
|
|
|
|
|
|
// 优惠券数据(接口返回)
|
|
|
@@ -108,7 +108,9 @@ function normalizeCouponItem(raw) {
|
|
|
couponType,
|
|
|
nominalValue,
|
|
|
discountRate,
|
|
|
- conditionText
|
|
|
+ conditionText,
|
|
|
+ specifiedDay: raw.specifiedDay ?? raw.validDays ?? '',
|
|
|
+ supplementaryInstruction: raw.supplementaryInstruction ?? raw.description ?? ''
|
|
|
};
|
|
|
}
|
|
|
|
|
|
@@ -148,11 +150,7 @@ const getCouponCardClass = (coupon) => {
|
|
|
|
|
|
// 查看使用规则
|
|
|
const handleShowRules = (coupon) => {
|
|
|
- selectedCoupon.value = {
|
|
|
- ...coupon,
|
|
|
- validDays: 90,
|
|
|
- description: '周一、周五不可用'
|
|
|
- };
|
|
|
+ selectedCoupon.value = { ...coupon };
|
|
|
showRulesModal.value = true;
|
|
|
};
|
|
|
|