Skip to content

Commit

Permalink
- KBDEV-1254
Browse files Browse the repository at this point in the history
- Fix bug in main view where new records of abstract classes (e.g.: ontology, relationship) required admin permission
- Fix rowData typos for ag grid calls
- Code lint
  • Loading branch information
bnguyen-bcgsc committed Sep 17, 2024
1 parent 8179a92 commit 0475cb9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/components/QueryResultsTable/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ const QueryResultsTable = ({
<AgGridReact
{...grid.props}
columnDefs={columnDefs}
data={data}
rowData={data}
deltaRowDataMode

Check failure on line 81 in src/components/QueryResultsTable/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
enableCellTextSelection

Check failure on line 82 in src/components/QueryResultsTable/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
frameworkComponents={{ JumpToRecord }}

Check failure on line 83 in src/components/QueryResultsTable/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
Expand Down
4 changes: 2 additions & 2 deletions src/views/ActivityView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ const ActivityView = () => {
}),
]);
const result = [...records, ...edges]
.sort((rec1, rec2) => (rec2.updatedAt || rec2.createdAt) - (rec1.updatedAt || rec1.createdAt));
.sort((rec1: any, rec2: any) => (rec2.updatedAt || rec2.createdAt) - (rec1.updatedAt || rec1.createdAt));
return result;
});

Expand Down Expand Up @@ -133,7 +133,7 @@ const ActivityView = () => {
sortable: true,
},
]}
data={recentRecords}
rowData={recentRecords}
deltaRowDataMode

Check failure on line 137 in src/views/ActivityView/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
enableCellTextSelection

Check failure on line 138 in src/views/ActivityView/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
frameworkComponents={{ JumpToRecord }}

Check failure on line 139 in src/views/ActivityView/index.tsx

View workflow job for this annotation

GitHub Actions / build

Props should be sorted alphabetically
Expand Down
2 changes: 1 addition & 1 deletion src/views/MainView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ const Main = () => {
})}
{generateAuthenticatedRoutes(['new'], [...ABSTRACT_CLASSES, ...ABSTRACT_CLASSES.map((m) => m.toLowerCase())], {
component: NewRecordSelectView,
admin: true,
admin: false,
})}
<Route element={<AuthenticatedRoute component={NewRecordView} />} path="/new/:modelName" />
<Route element={<AuthenticatedRoute component={DataView} />} path="/data/table" />
Expand Down

0 comments on commit 0475cb9

Please sign in to comment.