新增财务仪表盘并统一金额到角

This commit is contained in:
yml
2026-06-09 00:13:03 +08:00
parent a2a0489158
commit 2dfa2611fd
40 changed files with 1324 additions and 70 deletions
@@ -8,6 +8,7 @@ import QRCode from 'qrcode'
import { fetchOrderChat } from '@/features/chats/api/chats'
import { createDispute } from '@/features/disputes'
import { uploadFile } from '@/shared/api/files'
import { formatMoney } from '@/shared/utils/money'
import {
acceptCheckout,
cancelOrder,
@@ -588,7 +589,7 @@ function readUnitPrice(priceText: string) {
}
function roundMoney(value: number) {
return Math.round(value)
return Math.round(Number(value || 0) * 10) / 10
}
function roundQuantity(value: number) {
@@ -596,7 +597,7 @@ function roundQuantity(value: number) {
}
function money(value: unknown) {
return `${roundMoney(readNumber(value))}`
return formatMoney(readNumber(value))
}
function orderRentAmount(item: Order) {
@@ -1252,7 +1253,7 @@ async function copyListingCode() {
<div class="pay-summary">
<div class="pay-summary-row">
<span>支付金额</span>
<strong>¥{{ (activePayment.amount_cent / 100).toFixed(2) }}</strong>
<strong>¥{{ formatMoney(activePayment.amount_cent / 100) }}</strong>
</div>
</div>
<div v-if="paymentPayURL()" class="pay-qr-section">