活动修改
This commit is contained in:
parent
d8eba6ea2e
commit
5b0b69bf97
|
|
@ -106,17 +106,27 @@ export default {
|
||||||
methods: {
|
methods: {
|
||||||
// 切换状态
|
// 切换状态
|
||||||
async statusChange(e, row) {
|
async statusChange(e, row) {
|
||||||
try {
|
if (row.couponName) {
|
||||||
this.tableData.loading = true
|
try {
|
||||||
const data = { ...row }
|
this.tableData.loading = true
|
||||||
data.isUseCoupon = e
|
const data = { ...row }
|
||||||
console.log(data.isUseCoupon)
|
data.isUseCoupon = e
|
||||||
await storageupActivate(data)
|
console.log(data.isUseCoupon)
|
||||||
this.getTableData()
|
await storageupActivate(data)
|
||||||
} catch (error) {
|
this.getTableData()
|
||||||
console.log(error)
|
} catch (error) {
|
||||||
this.tableData.loading = false
|
console.log(error)
|
||||||
|
this.tableData.loading = false
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(22)
|
||||||
|
this.$message({
|
||||||
|
message: '请选择优惠劵',
|
||||||
|
type: 'warning'
|
||||||
|
});
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
// 重置查询
|
// 重置查询
|
||||||
resetHandle() {
|
resetHandle() {
|
||||||
|
|
|
||||||
|
|
@ -64,8 +64,9 @@
|
||||||
<div class="name">{{ item.title }}</div>
|
<div class="name">{{ item.title }}</div>
|
||||||
<!-- <el-input style="width: 120px;" v-model="item.num" placeholder='请填写数量'
|
<!-- <el-input style="width: 120px;" v-model="item.num" placeholder='请填写数量'
|
||||||
@input="checkIfNum(item)"></el-input> -->
|
@input="checkIfNum(item)"></el-input> -->
|
||||||
<el-button type="text" @click="productIds.splice(index, 1)"
|
<!-- <el-button type="text" @click="productIds.splice(index, 1)"
|
||||||
style="margin-left: 20px;">删除</el-button>
|
style="margin-left: 20px;">删除</el-button> -->
|
||||||
|
<el-button type="text" @click="productIds = []" style="margin-left: 20px;">删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
@ -210,7 +211,11 @@ export default {
|
||||||
this.form = { ...obj }
|
this.form = { ...obj }
|
||||||
// let res = await activate(obj.id)
|
// let res = await activate(obj.id)
|
||||||
// this.productIds = res
|
// this.productIds = res
|
||||||
console.log(res, '调试1')
|
if (obj.couponName) {
|
||||||
|
this.productIds = [{ title: obj.couponName }]
|
||||||
|
|
||||||
|
}
|
||||||
|
console.log(obj, '调试1')
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue