From 663ec86cda7d68c7809860fa258bcb8790bde248 Mon Sep 17 00:00:00 2001
From: 快乐的昕的电脑 <快乐的昕的电脑@DESKTOP-C2BQPQU>
Date: 星期五, 24 十月 2025 17:26:02 +0800
Subject: [PATCH] 调试
---
components/mold.vue | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/components/mold.vue b/components/mold.vue
index c590c23..9042451 100644
--- a/components/mold.vue
+++ b/components/mold.vue
@@ -466,6 +466,18 @@
};
});
+ // 鏂板锛氭寜涓婂垁鏃堕棿鍗囧簭鎺掑簭锛堣秺鏃╃殑瓒婁笂闈級
+ mapped.sort((a, b) => {
+ // 鏃堕棿鏍煎紡濡� "10-24 16:03"锛岃浆涓� Date 瀵硅薄姣旇緝
+ const parse = s => {
+ if (!s) return 0;
+ // 琛ュ勾浠斤紝鍋囪閮芥槸浠婂勾
+ const year = new Date().getFullYear();
+ return new Date(`${year}-${s.replace(/-/g, '-')}:00`).getTime();
+ };
+ return parse(a.upTime) - parse(b.upTime);
+ });
+
this.toolRecords = mapped;
const totalFromRes = Number(
res.data?.total ?? res.data?.totalCount ?? res.total ?? res.totalCount ?? mapped.length
--
Gitblit v1.9.3