Skip to content

Commit

Permalink
fix: Fix rows counter in the Edit Grade modal window
Browse files Browse the repository at this point in the history
  • Loading branch information
Lunyachek committed Apr 4, 2024
1 parent acdad5a commit 777e55e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ exports[`OverrideTable component render snapshot 1`] = `
},
]
}
itemCount={2}
itemCount={3}
/>
`;
20 changes: 11 additions & 9 deletions src/components/GradesView/EditModal/OverrideTable/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,20 @@ export const OverrideTable = () => {

if (hide) { return null; }

const tableData = [
...data,
{
adjustedGrade: <AdjustedGradeInput />,
date: formatDateForDisplay(new Date()),
reason: <ReasonInput />,
},
];

return (
<DataTable
columns={columns}
data={[
...data,
{
adjustedGrade: <AdjustedGradeInput />,
date: formatDateForDisplay(new Date()),
reason: <ReasonInput />,
},
]}
itemCount={data.length}
data={tableData}
itemCount={tableData.length}
/>
);
};
Expand Down

0 comments on commit 777e55e

Please sign in to comment.