Browse Source

20260403 交易币种(消耗)

lijianlin/feature-20260401-现金管理四期
wangguorui 6 days ago
parent
commit
0841876f4d
  1. 2
      src/main/java/com/example/demo/serviceImpl/coin/ConsumeServiceImpl.java
  2. 2
      src/main/resources/mapper/ConsumeMapper.xml

2
src/main/java/com/example/demo/serviceImpl/coin/ConsumeServiceImpl.java

@ -238,6 +238,8 @@ public class ConsumeServiceImpl implements ConsumeService {
UserWalletRecord userWalletRecord = new UserWalletRecord(); UserWalletRecord userWalletRecord = new UserWalletRecord();
userWalletRecord.setJwcode(consumeUser.getJwcode()); userWalletRecord.setJwcode(consumeUser.getJwcode());
userWalletRecord.setWalletId(wallet.getWalletId()); userWalletRecord.setWalletId(wallet.getWalletId());
userWalletRecord.setType(1); // 1=消耗
userWalletRecord.setTransactionCurrency("金币"); // 交易币种
userWalletRecord.setAmount(-deductAmount.intValue()); userWalletRecord.setAmount(-deductAmount.intValue());
userWalletRecord.setOrderCode(userGoldRecord.getOrderCode()); userWalletRecord.setOrderCode(userGoldRecord.getOrderCode());
userWalletRecord.setDescription("购买" + consumeUser.getGoodsName()); userWalletRecord.setDescription("购买" + consumeUser.getGoodsName());

2
src/main/resources/mapper/ConsumeMapper.xml

@ -383,6 +383,7 @@
jwcode, jwcode,
wallet_id, wallet_id,
type, type,
transaction_currency,
amount, amount,
order_code, order_code,
description, description,
@ -394,6 +395,7 @@
#{jwcode}, #{jwcode},
#{walletId}, #{walletId},
1, 1,
#{transactionCurrency},
#{amount}, #{amount},
#{orderCode}, #{orderCode},
#{description}, #{description},

Loading…
Cancel
Save