From d91f9a4c649e7e8048c8912e9b7246f1a58e398e Mon Sep 17 00:00:00 2001 From: yziiy <15979918+mayday-yziiy@user.noreply.gitee.com> Date: Sat, 20 Dec 2025 16:54:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/newuser/newuserList/hook.tsx | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/src/views/newuser/newuserList/hook.tsx b/src/views/newuser/newuserList/hook.tsx index 13228da..e1d0ff0 100644 --- a/src/views/newuser/newuserList/hook.tsx +++ b/src/views/newuser/newuserList/hook.tsx @@ -131,11 +131,13 @@ export function useData() { }, { label: "金币", - prop: "coin" + prop: "coin", + sortable: true }, { label: "钻石", - prop: "earnings" + prop: "earnings", + sortable: true }, { label: "实名状态", @@ -174,10 +176,16 @@ export function useData() { page_limit: pagination.value.pageSize }); if (code) { - tableList.value = data.lists; + tableList.value = data.lists.map(ele => { + return { + ...ele, + coin: Number(ele.coin), + earnings: Number(ele.earnings) + } + }); pagination.value.total = data.count; - totalPrice.value.total_coin = data.total_coin; - totalPrice.value.total_earnings = data.total_earnings; + totalPrice.value.total_coin = Number(data.total_coin); + totalPrice.value.total_earnings = Number(data.total_earnings); pagination.value.currentPage = +data.page; } loading.value = false;