This commit is contained in:
BianLzhaoMin 2025-01-03 15:17:33 +08:00
parent 2bce41582e
commit 5dd0386da4
1 changed files with 8 additions and 1 deletions

View File

@ -226,6 +226,7 @@ export default {
}, },
methods: { methods: {
handleClose() { handleClose() {
this.$refs.addOrEditFormRef.resetFields()
this.$emit('update:formDialogVisible', false) this.$emit('update:formDialogVisible', false)
}, },
onSubmitForm() { onSubmitForm() {
@ -239,7 +240,8 @@ export default {
logo, logo,
nickName, nickName,
phonenumber, phonenumber,
userName, deptId,
parentId,
} = this.addOrEditForm } = this.addOrEditForm
const params = { const params = {
deptName, deptName,
@ -254,6 +256,11 @@ export default {
password, password,
}, },
} }
if (this.formType == 2) {
params.deptId = deptId
params.parentId = parentId
}
const SEND_FUN = const SEND_FUN =
this.formType == 2 ? editCompanyAPI : addCompanyAPI this.formType == 2 ? editCompanyAPI : addCompanyAPI
const res = await SEND_FUN(params) const res = await SEND_FUN(params)