fix:超市购物卡支付、选择钱包、称重商品小数精度不够的问题

This commit is contained in:
dzc committed 2025-08-15 17:27:57 +08:00
1 parent 6d68dcc8ef
commit 6c3af87b7b
3 files changed
+31 -20

No files matched your search

+2 -2
View File
@@ -12,7 +12,7 @@ ENV = 'development'
# VITE_ADMIN_PROXY_PATH = http://123.156.230.15:8089/api/ # 测试线上-过期
# VITE_ADMIN_PROXY_PATH = http://pjcloud.center.takin.cc/
# VITE_ADMIN_PROXY_PATH = http://localhost:9999/
VITE_ADMIN_PROXY_PATH = http://192.168.101.174:9999/ # 邓-本地
VITE_ADMIN_PROXY_PATH = http://192.168.101.185:9999/ # 邓-本地
# VITE_ADMIN_PROXY_PATH = http://59.202.170.152:81/api # 正式环境线上
# 图片访问基础地址
@@ -20,7 +20,7 @@ VITE_ADMIN_PROXY_PATH = http://192.168.101.174:9999/ # 邓-本地
# VITE_IMAGE_BASE_PATH = http://123.156.230.15:8089/api/ # 测试线上-过期
# VITE_IMAGE_BASE_PATH = http://pjcloud.center.takin.cc
# VITE_IMAGE_BASE_PATH = http://localhost:9999
VITE_IMAGE_BASE_PATH = http://192.168.101.174:9999 # 邓-本地
VITE_IMAGE_BASE_PATH = http://192.168.101.185:9999 # 邓-本地
# VITE_IMAGE_BASE_PATH = http://59.202.170.152:81/api/ # 正式环境线上
# 代码生成服务地址
+27 -18
View File
@@ -76,24 +76,32 @@
</el-table-column>
<el-table-column width="200px" prop="paymentInformation" label="付款信息">
<template #default="{ row }">
<div class="status">
<span>商品总价</span>
<span class="color-success">
{{ displayPrice(row.totalPrice, "元", 2) }}
</span>
</div>
<div class="status">
<span>额外支付</span>
<span class="color-danger">
{{ displayPrice(row.extraPrice, "元", 2) }}
</span>
</div>
<div class="status">
<span>实际支付</span>
<span class="color-primary">
{{ displayPrice(row.payPrice, "元", 2) }}
</span>
<div class="flex justify-between items-start">
<div class="w-[200px] h-[25px]">
<dict-tag :options="wallet_type" :value="row.walletTypeUniqueCode" />
</div>
<div class="ml-2">
<div class="status">
<span>商品总价</span>
<span class="color-success">
{{ displayPrice(row.totalPrice, "元", 2) }}
</span>
</div>
<div class="status">
<span>额外支付</span>
<span class="color-danger">
{{ displayPrice(row.extraPrice, "元", 2) }}
</span>
</div>
<div class="status">
<span>实际支付</span>
<span class="color-primary">
{{ displayPrice(row.payPrice, "元", 2) }}
</span>
</div>
</div>
</div>
</template>
</el-table-column>
<el-table-column label="支付时间" align="center" prop="payTime" width="250px">
@@ -262,13 +270,14 @@ const AdminRefundDialog = defineAsyncComponent(() => import("./admin-refund-dial
const ShopCar = defineAsyncComponent(() => import("../components/shop-car.vue"))
const TransactionList = defineAsyncComponent(() => import("/@/views/wallet/components/transaction-list.vue"))
// 定义查询字典
const { hard_pay_type, hard_order_type, hard_order_status, hard_type, hard_refund_status, daily_menu } = useDict(
const { hard_pay_type, hard_order_type, hard_order_status, hard_type, hard_refund_status, daily_menu, wallet_type } = useDict(
"hard_pay_type",
"hard_order_type",
"hard_order_status",
"hard_type",
"hard_refund_status",
"daily_menu",
"wallet_type",
)
// 定义变量内容
const formDialogRef = ref()
@@ -224,9 +224,11 @@ const syncSupermarket = async () => {
try {
const res = await HardMqApi.syncSupermarket({})
console.log("商品分类同步至消费机:", res);
useMessage().success("同步成功")
loading.close()
} catch (error: any) {
console.error("商品分类同步至消费机:", error);
useMessage().error(error.msg)
loading.close()
}
}