fix: BUG修改

This commit is contained in:
kun 2024-02-19 18:47:38 +08:00
parent 09493ae652
commit 0dca61a3b5
2 changed files with 2 additions and 2 deletions

View File

@ -347,7 +347,7 @@ const saveItem = async (formEl: FormInstance | undefined, form: any) => {
if (!formEl) return;
await formEl.validate(async (valid, fields) => {
if (valid) {
if (store.enterpriseType && !store.enterpriseType.includes(1)) {
if (store.enterpriseType && store.enterpriseType.length > 0 && !store.enterpriseType.includes(1)) {
delete form.roleType;
}
if (form.roleId) {

View File

@ -391,7 +391,7 @@ const saveItem = async (formEl: FormInstance | undefined, form: any) => {
if (!formEl) return;
await formEl.validate(async (valid, fields) => {
if (valid) {
if (store.enterpriseType && !store.enterpriseType.includes(1)) {
if (store.enterpriseType && store.enterpriseType.length > 0 && !store.enterpriseType.includes(1)) {
delete form.accountType;
}
if (form.userId) {