fix(ui): assist sort selection
This commit is contained in:
parent
d41ea47347
commit
6b7a1499af
1 changed files with 5 additions and 4 deletions
|
|
@ -24,7 +24,7 @@ function LiveSessionList() {
|
||||||
const totalLiveSessions = sessionStore.totalLiveSessions;
|
const totalLiveSessions = sessionStore.totalLiveSessions;
|
||||||
const loading = sessionStore.loadingLiveSessions;
|
const loading = sessionStore.loadingLiveSessions;
|
||||||
const { currentPage } = searchStoreLive;
|
const { currentPage } = searchStoreLive;
|
||||||
const metaList = customFieldStore.list;
|
const metaList = customFieldStore.list
|
||||||
const metaListLoading = customFieldStore.isLoading;
|
const metaListLoading = customFieldStore.isLoading;
|
||||||
|
|
||||||
let timeoutId: any;
|
let timeoutId: any;
|
||||||
|
|
@ -32,9 +32,9 @@ function LiveSessionList() {
|
||||||
const hasUserFilter = filters.map((i: any) => i.key).includes(KEYS.USERID);
|
const hasUserFilter = filters.map((i: any) => i.key).includes(KEYS.USERID);
|
||||||
const sortOptions = [{ label: 'Start Time', value: 'timestamp' }].concat(
|
const sortOptions = [{ label: 'Start Time', value: 'timestamp' }].concat(
|
||||||
metaList
|
metaList
|
||||||
.map((i: any) => ({
|
.map(({ key} : any) => ({
|
||||||
label: capitalize(i),
|
label: capitalize(key),
|
||||||
value: i
|
value: key
|
||||||
}))
|
}))
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -66,6 +66,7 @@ function LiveSessionList() {
|
||||||
|
|
||||||
const onSortChange = ({ value }: any) => {
|
const onSortChange = ({ value }: any) => {
|
||||||
searchStoreLive.edit({ sort: value.value });
|
searchStoreLive.edit({ sort: value.value });
|
||||||
|
void searchStoreLive.fetchSessions();
|
||||||
};
|
};
|
||||||
|
|
||||||
const timeout = () => {
|
const timeout = () => {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue