Commit c08613dbefbda843dda5f55a4045ca0e49237006
Merge remote-tracking branch 'origin/fix/zfl' into perf/main_dev
Showing
3 changed files
with
9 additions
and
4 deletions
| @@ -2,6 +2,7 @@ import type { NodeDataType } from '@/api/node/model' | @@ -2,6 +2,7 @@ import type { NodeDataType } from '@/api/node/model' | ||
| 2 | 2 | ||
| 3 | export interface ProductAndDevice { | 3 | export interface ProductAndDevice { |
| 4 | name: string | 4 | name: string |
| 5 | + profileName?: string | ||
| 5 | profileId: string | 6 | profileId: string |
| 6 | deviceList: { | 7 | deviceList: { |
| 7 | deviceId: string | 8 | deviceId: string |
| @@ -86,7 +86,13 @@ export interface NodeDataDataSourceJsonType { | @@ -86,7 +86,13 @@ export interface NodeDataDataSourceJsonType { | ||
| 86 | chartOption?: ChartOptionType | 86 | chartOption?: ChartOptionType |
| 87 | videoOption?: VideoOptionType | 87 | videoOption?: VideoOptionType |
| 88 | alarmListOption?: AlarmListOptionType | 88 | alarmListOption?: AlarmListOptionType |
| 89 | - | 89 | + deviceInfo?: { |
| 90 | + code?: string | ||
| 91 | + transportType?: string | ||
| 92 | + deviceType?: string | ||
| 93 | + deviceProfileId?: string | ||
| 94 | + label?: string | ||
| 95 | + } | ||
| 90 | circularFlowMeterOption?: FlowMeterOptionType// 圆形水球图数据暂定any | 96 | circularFlowMeterOption?: FlowMeterOptionType// 圆形水球图数据暂定any |
| 91 | additional?: any// 圆形水球图颜色配置数据暂定any | 97 | additional?: any// 圆形水球图颜色配置数据暂定any |
| 92 | rectFlowMeterOption?: FlowMeterOptionType// 方形水球图颜色配置数据暂定any | 98 | rectFlowMeterOption?: FlowMeterOptionType// 方形水球图颜色配置数据暂定any |
| @@ -25,9 +25,7 @@ export const formSchemas = (componentKey?: string): FormSchema[] => { | @@ -25,9 +25,7 @@ export const formSchemas = (componentKey?: string): FormSchema[] => { | ||
| 25 | required: !!isTemplate, | 25 | required: !!isTemplate, |
| 26 | componentProps: ({ formModel }) => { | 26 | componentProps: ({ formModel }) => { |
| 27 | return { | 27 | return { |
| 28 | - options: (unref(contentDataStore.getProductAndDevice) || []).map((item: ProductAndDevice) => ({ label: item.name, value: item.profileId })), | ||
| 29 | - // labelField: 'name', | ||
| 30 | - // valueField: 'profileId', | 28 | + options: (unref(contentDataStore.getProductAndDevice) || []).map((item: ProductAndDevice) => ({ label: item.profileName || item.name, value: item.profileId })), |
| 31 | placeholder: '请选择产品', | 29 | placeholder: '请选择产品', |
| 32 | onSelect(value: string) { | 30 | onSelect(value: string) { |
| 33 | formModel[ContentDataFieldsEnum.DEVICE_PROFILE_ID] = value | 31 | formModel[ContentDataFieldsEnum.DEVICE_PROFILE_ID] = value |