Skip to content

Commit 2a3ac1a

Browse files
committed
rowIndex, isCreate are now dynamic fields for addNewRow per #126
1 parent fe7598d commit 2a3ac1a

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/actions/plugins/editor/EditorActions.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,16 @@ export const updateRow = ({ stateKey, rowIndex, values }) => ({
8989
});
9090

9191
export const addNewRow = ({
92-
columns, data, stateKey, editMode = 'inline'
92+
columns,
93+
data,
94+
stateKey,
95+
editMode = 'inline',
96+
rowIndex = 0,
97+
isCreate = true
9398
}) => (dispatch) => {
9499
const rowId = keyGenerator('row', getNewRowId());
95100
const top = 43;
96101
const rowData = data || {};
97-
const rowIndex = 0;
98-
const isCreate = true;
99102

100103
dispatch({ type: ADD_NEW_ROW, stateKey, rowId });
101104

0 commit comments

Comments
 (0)