重置vxe会导致新增表单无限增加用户名和密码

This commit is contained in:
gexinzhineng/gxzn27 2023-05-26 15:46:22 +08:00
parent 7c4025954a
commit 615ae3d651

View File

@ -128,7 +128,11 @@ const handleCreate = async () => {
setDialogTile('create')
await nextTick()
console.log(allSchemas.formSchema, 'allSchemas.formSchema')
if (allSchemas.formSchema[4].field !== 'username') {
let haveUser = allSchemas.formSchema.filter((res) => {
return res.field == 'username'
})
if (haveUser.length == 0) {
// if (allSchemas.formSchema[4].field !== 'username') {
unref(formRef)?.addSchema(
{
field: 'username',