Skip to content

Commit

Permalink
[#2754] improvement(web): list metalakes sort by created time as defa…
Browse files Browse the repository at this point in the history
…ult (#2764)

<!--
1. Title: [#<issue>] <type>(<scope>): <subject>
   Examples:
     - "[#123] feat(operator): support xxx"
     - "[#233] fix: check null before access result in xxx"
     - "[MINOR] refactor: fix typo in variable name"
     - "[MINOR] docs: fix typo in README"
     - "[#255] test: fix flaky test NameOfTheTest"
   Reference: https://www.conventionalcommits.org/en/v1.0.0/
2. If the PR is unfinished, please mark this PR as draft.
-->

### What changes were proposed in this pull request?

When listing metalakes they get sorted by their createdTime value

### Why are the changes needed?


Its requested in the issue
Fix: #2754  (issue)

### Does this PR introduce _any_ user-facing change?

metalakes will be shown in ASC order


### How was this patch tested?

N/A

---------

Co-authored-by: CHEYNE <contact@ch3yne.com>
  • Loading branch information
ibaiway and ch3yne authored Apr 2, 2024
1 parent 2bfefb9 commit a9f2ccc
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions web/src/lib/store/metalakes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ export const fetchMetalakes = createAsyncThunk('appMetalakes/fetchMetalakes', as

const { metalakes } = res

metalakes.sort((a, b) => new Date(b.audit.createTime) - new Date(a.audit.createTime))

return { metalakes }
})

Expand Down

0 comments on commit a9f2ccc

Please sign in to comment.