mirror of
https://github.com/portainer/portainer.git
synced 2025-07-23 07:19:41 +02:00
fix(notifications): sort by newest first by default [EE-4467] (#7891)
This commit is contained in:
parent
58947fee69
commit
c1f94be9b2
3 changed files with 10 additions and 5 deletions
|
@ -24,10 +24,11 @@ export interface SortableTableSettings {
|
|||
|
||||
export function sortableSettings(
|
||||
set: Set<SortableTableSettings>,
|
||||
initialSortBy = 'name'
|
||||
initialSortBy = 'name',
|
||||
desc = false
|
||||
): SortableTableSettings {
|
||||
return {
|
||||
sortBy: { id: initialSortBy, desc: false },
|
||||
sortBy: { id: initialSortBy, desc },
|
||||
setSortBy: (id: string, desc: boolean) => set({ sortBy: { id, desc } }),
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue