Skip to content

Commit

Permalink
copy flow row for mutate it with index #58
Browse files Browse the repository at this point in the history
  • Loading branch information
mydu committed Jun 27, 2019
1 parent f78e28d commit 5842e3f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions importApp/src/containers/DataModification/DataModification.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ class DataModification extends React.Component {
}

if(payload.field === 'year') {
const rowNumbers = errors.map((e) => e.rowNumber)
const rowNumbers = errors.map((e) => e.rowNumber);
const columnIndex = flows[0].indexOf('year');
const source = [flows[0]].concat(errors.map((e) => {
const row = flows[e.rowNumber -1]
const row = [...flows[e.rowNumber -1]]
row[columnIndex] = payload.fixedValues['year'];
return row;
}));
Expand Down

0 comments on commit 5842e3f

Please sign in to comment.