|
|
@@ -137,11 +137,11 @@ class ArrayFieldComponent extends Component<ArrayFieldProps, ArrayFieldState> {
|
|
|
this.setState({ keys });
|
|
|
}
|
|
|
|
|
|
- addWithInitValue(lineObject: Record<string, any>) {
|
|
|
+ addWithInitValue(rowVal: Record<string, any> | string) {
|
|
|
const updater = this.context;
|
|
|
const { field } = this.props;
|
|
|
const newArrayFieldVal = updater.getValue(field) ? updater.getValue(field).slice() : [];
|
|
|
- newArrayFieldVal.push(lineObject);
|
|
|
+ newArrayFieldVal.push(rowVal);
|
|
|
updater.updateStateValue(field, newArrayFieldVal, {});
|
|
|
updater.updateArrayField(field, { updateKey: new Date().valueOf() });
|
|
|
}
|