添加筛选条件

h5
ihzero 2023-08-07 12:54:56 +08:00
parent 060dc82350
commit 3e98e1a390
3 changed files with 51 additions and 2 deletions

View File

@ -75,6 +75,20 @@ export const searchFormSchema: FormSchema[] = [
componentProps: {},
colProps: { span: 8 },
},
{
field: 'industry',
label: '农业类型',
component: 'ApiSelect',
componentProps: {
api: async () => {
const res = await getKeywordsIndustry()
return res
},
labelField: 'name',
valueField: 'key',
},
colProps: { span: 8 },
},
]
export const accountFormSchema: FormSchema[] = [
@ -111,7 +125,7 @@ export const accountFormSchema: FormSchema[] = [
{
field: 'industry_key',
label: '业类型',
label: '业类型',
required: true,
component: 'ApiSelect',
componentProps: {

View File

@ -139,6 +139,40 @@ export const searchFormSchema: FormSchema[] = [
component: 'Input',
colProps: { span: 8 },
},
{
field: 'sn',
label: '设备编号',
component: 'Input',
colProps: { span: 8 },
},
{
field: 'supplier_key',
label: '设备厂商',
component: 'ApiSelect',
componentProps: {
api: async () => {
const res = await getKeywords({ type_key: 'device-supplier' })
return res
},
labelField: 'name',
valueField: 'key',
},
colProps: { span: 8 },
},
{
field: 'project_key',
label: '项目',
component: 'ApiSelect',
componentProps: {
api: async () => {
const res = await getKeywords({ type_key: 'device-project' })
return res
},
labelField: 'name',
valueField: 'key',
},
colProps: { span: 8 },
},
]
export const accountFormSchema: FormSchema[] = [

View File

@ -166,7 +166,8 @@
})
Object.keys(resData).map((e) => {
const zindex = Data.list.findIndex(({ key }: any) => key == e)
Data.list[zindex].value = resData[e].slice(1)
if (zindex >= 0) Data.list[zindex].value = resData[e].slice(1)
})
}
let timerTabIndex = 1