diff --git a/src/store/form.ts b/src/store/form.ts index 9e9abea71..810244e50 100644 --- a/src/store/form.ts +++ b/src/store/form.ts @@ -290,7 +290,7 @@ export const FormStore = ServiceStore.named('FormStore') const items = getItemsByPath(key); if (Array.isArray(items) && items.length) { - items.forEach(item => item.setError(errors[key])); + items.forEach(item => item.setError(`${errors[key]}`)); delete errors[key]; } } diff --git a/src/store/formItem.ts b/src/store/formItem.ts index 3f09656af..cb30615c5 100644 --- a/src/store/formItem.ts +++ b/src/store/formItem.ts @@ -212,6 +212,11 @@ export const FormItemStore = StoreNode.named('FormItemStore') }); return selectedOptions; + }, + getItemsByName(name: string): any { + return (this as any).type === 'table' + ? [this.subFormItems[name]] + : [this]; } }; })