Commit 869244ccdda290fd38c636b0fcdf3ce23df095ca
Merge branch 'perf/object-model-service-input-params-require' into 'main_dev'
perf: 物模型新增输入参数为必填项 See merge request yunteng/thingskit-front!674
Showing
1 changed file
with
2 additions
and
0 deletions
@@ -116,6 +116,7 @@ export const serviceSchemas = (tcpDeviceFlag: boolean): FormSchema[] => { | @@ -116,6 +116,7 @@ export const serviceSchemas = (tcpDeviceFlag: boolean): FormSchema[] => { | ||
116 | field: FormField.SERVICE_COMMAND, | 116 | field: FormField.SERVICE_COMMAND, |
117 | label: '输入参数', | 117 | label: '输入参数', |
118 | component: 'Input', | 118 | component: 'Input', |
119 | + rules: [{ message: '输入参数为必填项', required: true }], | ||
119 | ifShow: tcpDeviceFlag, | 120 | ifShow: tcpDeviceFlag, |
120 | componentProps: { | 121 | componentProps: { |
121 | placeholder: '请输入ASCII或HEX服务命令', | 122 | placeholder: '请输入ASCII或HEX服务命令', |
@@ -127,6 +128,7 @@ export const serviceSchemas = (tcpDeviceFlag: boolean): FormSchema[] => { | @@ -127,6 +128,7 @@ export const serviceSchemas = (tcpDeviceFlag: boolean): FormSchema[] => { | ||
127 | component: 'StructForm', | 128 | component: 'StructForm', |
128 | valueField: 'value', | 129 | valueField: 'value', |
129 | changeEvent: 'update:value', | 130 | changeEvent: 'update:value', |
131 | + rules: [{ message: '输入参数为必填项', required: true, type: 'array' }], | ||
130 | ifShow: !tcpDeviceFlag, | 132 | ifShow: !tcpDeviceFlag, |
131 | colProps: { span: 24 }, | 133 | colProps: { span: 24 }, |
132 | }, | 134 | }, |