Showing
1 changed file
with
1 additions
and
1 deletions
... | ... | @@ -7,7 +7,7 @@ export const validateDevicePicker = () => { |
7 | 7 | validateTrigger: 'blur', |
8 | 8 | validator(_rule: Recordable, value: Recordable, _callback: Fn) { |
9 | 9 | const device = Reflect.get(value || {}, FormFieldsEnum.DEVICE); |
10 | - if (!device) return Promise.reject('请选择设备'); | |
10 | + if (!device || !device.length) return Promise.reject('请选择设备'); | |
11 | 11 | return Promise.resolve(); |
12 | 12 | }, |
13 | 13 | } as Rule; | ... | ... |