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;