修复combo验证唯一值时,修改非唯一值报错的问题

This commit is contained in:
catchonme 2019-05-14 10:34:15 +08:00
parent 7b31280ac5
commit 4bdcd5c924

View File

@ -306,7 +306,7 @@ export default class FormControl extends React.Component<FormControlProps, any>
if (form.parentStore && form.parentStore.storeType === 'ComboStore') {
const combo = form.parentStore as IComboStore;
const group = combo.uniques.get(this.model.name) as IUniqueGroup;
group.items.forEach(item => item.validate());
group && group.items.forEach(item => item.validate());
} else {
this.model.validate(this.hook);
form.getItemsByName(this.model.name)