Skip to content

Commit

Permalink
Merge pull request alibaba#951 from alibaba/fix/use-fustion-table
Browse files Browse the repository at this point in the history
fix: useFusitionTable reset to default
  • Loading branch information
brickspert authored May 17, 2021
2 parents 6bd177e + 9386b06 commit c3779ff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/hooks/src/useFusionTable/__tests__/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ describe('useFusionTable', () => {
...values,
};
},
reset: () => {
resetToDefault: () => {
field.fieldsValue = { ...field.initialValue };
},
validate: (callback) => {
Expand Down
2 changes: 1 addition & 1 deletion packages/hooks/src/useFusionTable/fusionAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const fieldAdapter = (field: Field) =>
getFieldInstance: (name: string) => field.getNames().includes(name),
setFieldsValue: field.setValues,
getFieldsValue: field.getValues,
resetFields: field.reset,
resetFields: field.resetToDefault,
validateFields: (fields, callback) => {
field.validate(callback);
},
Expand Down

0 comments on commit c3779ff

Please sign in to comment.