参数错了

This commit is contained in:
2betop 2020-07-24 10:45:45 +08:00
parent 4b363882c6
commit 423ee53a09
1 changed files with 2 additions and 1 deletions

View File

@ -57,12 +57,13 @@ export class ServiceRenderer extends BasicService {
const formStore: IFormStore = this.props.formStore;
const onChange = this.props.onChange;
// 有可能有很多层 serivce这里需要注意。
if (formStore && this.isFormMode()) {
const keys = Object.keys(payload.data);
if (keys.length) {
formStore.setValues(payload.data);
onChange(keys[0], payload.data[keys[0]]);
onChange(payload.data[keys[0]], keys[0]);
}
}