Commit 4a7180a2 by gonglei

加入前端代码

1 parent 1fe04e2a
...@@ -175,7 +175,7 @@ public class DepositController { ...@@ -175,7 +175,7 @@ public class DepositController {
@GetMapping("getDepositStat") @GetMapping("getDepositStat")
public DepositStat getDepositStat() { public DepositStat getDepositStat() {
DepositStat depositStat = depositService.getDepositStat(); DepositStat depositStat = depositService.getDepositStat();
// depositStat.setUnauditedWithdrawAmount(withdrawService.getUnauditedWithdrawAmount()); depositStat.setUnauditedWithdrawAmount(withdrawService.getUnauditedWithdrawAmount());
return depositStat; return depositStat;
} }
......
...@@ -166,8 +166,8 @@ public class DepositService extends AbstractAuctionService { ...@@ -166,8 +166,8 @@ public class DepositService extends AbstractAuctionService {
public DepositStat getDepositStat() { public DepositStat getDepositStat() {
DepositStat depositStat = new DepositStat(); DepositStat depositStat = new DepositStat();
// Optional<Double> totalAmount = accountDao.sumAllSurplus(); Optional<Double> totalAmount = accountDao.sumAllSurplus();
Optional<Double> totalAmount = depositDao.sumAll(); // Optional<Double> totalAmount = depositDao.sumAll();
Optional<Double> depositAmount = depositDao.sumAccountByDepositState(Deposit.DepositState.FREEZE); Optional<Double> depositAmount = depositDao.sumAccountByDepositState(Deposit.DepositState.FREEZE);
Optional<Double> freezeAmount = depositDao.sumByDepositState(Deposit.DepositState.FREEZE); Optional<Double> freezeAmount = depositDao.sumByDepositState(Deposit.DepositState.FREEZE);
depositStat.setTotalAmount(Math.abs(totalAmount.orElse(0.0))); depositStat.setTotalAmount(Math.abs(totalAmount.orElse(0.0)));
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
</a-col> </a-col>
<a-col :span="6"> <a-col :span="6">
<a-card class="stat-card"> <a-card class="stat-card">
<a-statistic title="当前可用总额" :value="depositStat.depositAmount" :precision="0" prefix="¥" suffix="元"></a-statistic> <a-statistic title="当前可用总额" :value="depositStat.totalAmount-depositStat.freezeAmount" :precision="0" prefix="¥" suffix="元"></a-statistic>
</a-card> </a-card>
</a-col> </a-col>
<a-col :span="6"> <a-col :span="6">
...@@ -16,9 +16,9 @@ ...@@ -16,9 +16,9 @@
</a-card> </a-card>
</a-col> </a-col>
<a-col :span="6"> <a-col :span="6">
<!-- <a-card class="stat-card">--> <a-card class="stat-card">
<!-- <a-statistic title="待处理提现总额" :value="depositStat.unauditedWithdrawAmount" :precision="0" prefix="¥" suffix="元"></a-statistic>--> <a-statistic title="待处理提现总额" :value="depositStat.unauditedWithdrawAmount" :precision="0" prefix="¥" suffix="元"></a-statistic>
<!-- </a-card>--> </a-card>
</a-col> </a-col>
</a-row> </a-row>
<!--查询栏--> <!--查询栏-->
...@@ -56,8 +56,7 @@ ...@@ -56,8 +56,7 @@
{{ $t('enum.transaction.transactionType.' + record.transaction.transactionType) }} {{ $t('enum.transaction.transactionType.' + record.transaction.transactionType) }}
</template> </template>
<template v-if="column.key === 'depositState'"> <template v-if="column.key === 'depositState'">
<deposit-state-tag v-if="record.paymentTime" :deposit-state="record.depositState"></deposit-state-tag> <deposit-state-tag :deposit-state="record.depositState"></deposit-state-tag>
<a-tag v-else>未支付</a-tag>
</template> </template>
</template> </template>
...@@ -135,7 +134,7 @@ export default class DepositPage extends PaginationComponent<Deposit> { ...@@ -135,7 +134,7 @@ export default class DepositPage extends PaginationComponent<Deposit> {
{ {
title: '冻结状态', dataIndex: 'depositState', key: 'depositState', align: 'center', fixed: 'right', width: 110, resizable: true, ellipsis: true, sorter: true, title: '冻结状态', dataIndex: 'depositState', key: 'depositState', align: 'center', fixed: 'right', width: 110, resizable: true, ellipsis: true, sorter: true,
}, },
{title: '操作', key: 'action', width: 90, align: 'center', fixed: 'right'}, {title: '操作', key: 'action', width: 170, align: 'center', fixed: 'right'},
]; ];
depositStat: DepositStat = null; depositStat: DepositStat = null;
......
...@@ -10,14 +10,14 @@ ...@@ -10,14 +10,14 @@
<a-col :span="6"> <a-col :span="6">
<a-card class="stat-card"> <a-card class="stat-card">
<a-tooltip title="平台所有车商可用余额的总和"> <a-tooltip title="平台所有车商可用余额的总和">
<a-statistic title="当前可用总额" :value="depositStat.totalAmount+depositStat.freezeAmount" :precision="2" prefix="¥" suffix="元"></a-statistic> <a-statistic title="当前可用总额" :value="depositStat.totalAmount-depositStat.freezeAmount" :precision="2" prefix="¥" suffix="元"></a-statistic>
</a-tooltip> </a-tooltip>
</a-card> </a-card>
</a-col> </a-col>
<a-col :span="6"> <a-col :span="6">
<a-card class="stat-card"> <a-card class="stat-card">
<a-tooltip title="平台所有车商冻结金额的总和"> <a-tooltip title="平台所有车商冻结金额的总和">
<a-statistic title="当前冻结总额" :value="-depositStat.freezeAmount" :precision="2" prefix="¥" suffix="元"></a-statistic> <a-statistic title="当前冻结总额" :value="depositStat.freezeAmount" :precision="2" prefix="¥" suffix="元"></a-statistic>
</a-tooltip> </a-tooltip>
</a-card> </a-card>
</a-col> </a-col>
......
...@@ -161,4 +161,45 @@ ALTER TABLE account ...@@ -161,4 +161,45 @@ ALTER TABLE account
# COMMENT '审核状态' NULL after AUDIT_REMARK; # COMMENT '审核状态' NULL after AUDIT_REMARK;
# #
# ALTER TABLE recharge ADD REJECT_REASON VARCHAR(255) # ALTER TABLE recharge ADD REJECT_REASON VARCHAR(255)
# COMMENT '驳回原因' NULL after AUDIT_STATE;
\ No newline at end of file \ No newline at end of file
# COMMENT '驳回原因' NULL after AUDIT_STATE;
# 2026-01-08
/* Build Table Structure */
CREATE TABLE refund
(
REFUND_ID INTEGER AUTO_INCREMENT PRIMARY KEY
COMMENT 'REFUND_ID' NOT NULL,
OUT_REFUND_NO VARCHAR(64)
COMMENT '微信退款订单号' NOT NULL,
REFUND_AMOUNT DECIMAL(12, 2)
COMMENT '退款金额' NOT NULL,
REFUND_TIME DATETIME
COMMENT '退款时间' NOT NULL,
REFUND_SUCCESS_TIME DATETIME
COMMENT '退款成功时间' NULL,
RECHARGE_ID INTEGER
COMMENT 'RECHARGE_ID' NOT NULL,
WITHDRAW_ID INTEGER
COMMENT 'WITHDRAW_ID' NOT NULL
) ENGINE=InnoDB;
/* Add Comments */
ALTER TABLE refund COMMENT = '退款';
/************ Add Foreign Keys ***************/
/* Add Foreign Key: fk_refund_recharge */
ALTER TABLE refund ADD CONSTRAINT fk_refund_recharge
FOREIGN KEY (RECHARGE_ID) REFERENCES recharge (RECHARGE_ID)
ON UPDATE NO ACTION ON DELETE NO ACTION;
/* Add Foreign Key: fk_refund_withdraw */
ALTER TABLE refund ADD CONSTRAINT fk_refund_withdraw
FOREIGN KEY (WITHDRAW_ID) REFERENCES withdraw (WITHDRAW_ID)
ON UPDATE NO ACTION ON DELETE NO ACTION;
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!