update:修改店铺数据库配置编辑页面弹出显示逻辑,父组件控制子组件关
This commit is contained in:
parent
3588d62dd1
commit
f3dc093edf
@ -288,13 +288,16 @@
|
|||||||
this.$refs.formRef.validate((valid) => {
|
this.$refs.formRef.validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.$emit('save', this.cloneData(this.innerFormData))
|
this.$emit('save', this.cloneData(this.innerFormData))
|
||||||
this.myVisible=false
|
|
||||||
} else {
|
} else {
|
||||||
this.$message.error('请完善表单信息')
|
this.$message.error('请检查表单信息是否正确或者完整')
|
||||||
return false
|
return false;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
// 新增:供父组件调用,手动关闭抽屉
|
||||||
|
closeDrawer() {
|
||||||
|
this.myVisible = false;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -271,8 +271,10 @@
|
|||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
this.$message.success('操作成功')
|
this.$message.success('操作成功')
|
||||||
this.fetchDbConfigList()
|
this.fetchDbConfigList()
|
||||||
|
this.$refs.storeConfDrawerRef.closeDrawer(); // 成功:调用子组件关闭抽屉
|
||||||
|
}else{
|
||||||
|
this.$message.error(res.msg)
|
||||||
}
|
}
|
||||||
this.drawerVisible = false
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// 处理删除
|
// 处理删除
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user