|
@@ -79,7 +79,7 @@ const filterSearchSchema = (crudSchema: CrudSchema[]): FormSchema[] => {
|
|
|
for (let i = 0; i < length; i++) {
|
|
|
const schemaItem = crudSchema[i]
|
|
|
// 判断是否隐藏
|
|
|
- if (!schemaItem?.search?.hidden) {
|
|
|
+ if (!schemaItem?.search?.remove) {
|
|
|
const searchSchemaItem = {
|
|
|
component: schemaItem?.search?.component || 'Input',
|
|
|
...schemaItem.search,
|
|
@@ -87,9 +87,6 @@ const filterSearchSchema = (crudSchema: CrudSchema[]): FormSchema[] => {
|
|
|
label: schemaItem.search?.label || schemaItem.label
|
|
|
}
|
|
|
|
|
|
- // 删除不必要的字段
|
|
|
- delete searchSchemaItem.hidden
|
|
|
-
|
|
|
searchSchema.push(searchSchemaItem)
|
|
|
}
|
|
|
}
|
|
@@ -127,7 +124,7 @@ const filterFormSchema = (crudSchema: CrudSchema[]): FormSchema[] => {
|
|
|
for (let i = 0; i < length; i++) {
|
|
|
const formItem = crudSchema[i]
|
|
|
// 判断是否隐藏
|
|
|
- if (!formItem?.form?.hidden) {
|
|
|
+ if (!formItem?.form?.remove) {
|
|
|
const formSchemaItem = {
|
|
|
component: formItem?.form?.component || 'Input',
|
|
|
...formItem.form,
|
|
@@ -135,9 +132,6 @@ const filterFormSchema = (crudSchema: CrudSchema[]): FormSchema[] => {
|
|
|
label: formItem.form?.label || formItem.label
|
|
|
}
|
|
|
|
|
|
- // 删除不必要的字段
|
|
|
- delete formSchemaItem.hidden
|
|
|
-
|
|
|
formSchema.push(formSchemaItem)
|
|
|
}
|
|
|
}
|