1
0
mirror of https://github.com/ialley-workshop-open/uni-halo.git synced 2026-06-12 13:19:31 +08:00

fix: 修复图库分类排序问题

This commit is contained in:
小莫唐尼
2025-07-19 14:08:44 +08:00
parent d71022c224
commit 452d021816
+4 -2
View File
@@ -162,9 +162,11 @@ export default {
this.category.list = res.items.map(item => { this.category.list = res.items.map(item => {
return { return {
name: item.metadata.name, name: item.metadata.name,
displayName: item.spec.displayName displayName: item.spec.displayName,
priority: item.spec.priority
} }
}); }).sort((a,b) => a.priority - b.priority);
if (this.category.list.length !== 0) { if (this.category.list.length !== 0) {
this.queryParams.group = this.category.list[0].name; this.queryParams.group = this.category.list[0].name;
this.fnGetData(true); this.fnGetData(true);