Skip to content

Commit

Permalink
fix(query): sorting by user for Query History list view (#11897)
Browse files Browse the repository at this point in the history
* fix: sorting by user for Query History list view

* fix filter exception
  • Loading branch information
nytai committed Dec 3, 2020
1 parent 71c567b commit 8c063ef
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
6 changes: 5 additions & 1 deletion superset-frontend/src/views/CRUD/data/query/QueryList.tsx
Expand Up @@ -277,7 +277,7 @@ function QueryList({ addDangerToast, addSuccessToast }: QueryListProps) {
disableSortBy: true,
},
{
accessor: QueryObjectColumns.user,
accessor: QueryObjectColumns.user_first_name,
Header: t('User'),
size: 'xl',
Cell: ({
Expand All @@ -286,6 +286,10 @@ function QueryList({ addDangerToast, addSuccessToast }: QueryListProps) {
},
}: any) => `${user.first_name} ${user.last_name}`,
},
{
accessor: QueryObjectColumns.user,
hidden: true,
},
{
accessor: QueryObjectColumns.rows,
Header: t('Rows'),
Expand Down
1 change: 1 addition & 0 deletions superset-frontend/src/views/CRUD/types.ts
Expand Up @@ -104,6 +104,7 @@ export enum QueryObjectColumns {
status = 'status',
tab_name = 'tab_name',
user = 'user',
user_first_name = 'user.first_name',
start_time = 'start_time',
end_time = 'end_time',
rows = 'rows',
Expand Down

0 comments on commit 8c063ef

Please sign in to comment.