Commit 58704a0f by 张立顺

fix 修改提示

1 parent 9cfc06d9
......@@ -434,6 +434,30 @@ export default {
periodList
})
this.getStaff()
// 确定是否可以提交
this.checkMerchantRule()
},
checkMerchantRule() {
const { merchantId, sceneType } = this.storeConfigConObj
// console.log(
// merchantId && (sceneType === 0 || sceneType === 1),
// "sceneType"
// )
console.log(sceneType, "sceneType")
if (merchantId && (sceneType === 0 || sceneType === 1)) {
merchantTargetConfigDetail({ merchantId, sceneType })
.then((res) => {
console.log(res)
this.storeConfigConObj.canSubmit = Boolean(res)
if (res) {
return this.$message.warning("该园区店场景已配置过")
}
// this.getStaff()
})
.catch((err) => {
console.log(err)
})
}
},
saveDraft() {
console.log("submitForm")
......@@ -446,6 +470,9 @@ export default {
if (![0, 1, '0', '1'].includes(params.sceneType)) {
return this.$message.warning("请选择场景")
}
if (params.canSubmit) {
return this.$message.warning("该园区店场景已配置过")
}
params.saveDraft = true
params.edit = this.routerParams.idEdit == true || this.routerParams.idEdit == 'true'
merchantTargetConfigUpdate(params)
......@@ -571,6 +598,9 @@ export default {
// params = params.map(item=>{
// })
if (params.canSubmit) {
return this.$message.warning("该园区店场景已配置过")
}
params.edit = this.routerParams.idEdit == true || this.routerParams.idEdit == 'true'
merchantTargetConfigUpdate(params)
.then((res) => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!