合并master,解决冲突

This commit is contained in:
pikachu1995@126.com
2023-03-01 11:50:54 +08:00
11 changed files with 135 additions and 11 deletions

View File

@@ -221,7 +221,7 @@ public enum ResultCode {
PAY_POINT_ENOUGH(32010, "积分不足,不能兑换"),
PAY_NOT_EXIST_ORDER(32011, "支付订单不存在"),
CAN_NOT_RECHARGE_WALLET(32012, "不能使用余额进行充值"),
RECHARGE_PRICE_ERROR(32013, "充值金额错误"),
/**
* 售后
@@ -260,7 +260,7 @@ public enum ResultCode {
WALLET_EXIT_ERROR(34005, "钱包已存在,无法重复创建"),
WALLET_APPLY_ERROR(34006, "提现申请异常!"),
WALLET_APPLY_MIN_PRICE_ERROR(34007, "提现最低提现金额错误!"),
WALLET_WITHDRAWAL_AMOUNT_ERROR(34008, "申请提现金额异常!"),
/**
* 评价
*/
@@ -503,6 +503,7 @@ public enum ResultCode {
PURCHASE_ORDER_DEADLINE_ERROR(90004, "供求单,已超过报名截止时间"),
INDEX_BUILDING(90005, "索引正在生成");
private final Integer code;
private final String message;

View File

@@ -257,6 +257,9 @@ public class MemberWalletServiceImpl extends ServiceImpl<MemberWalletMapper, Mem
@Transactional(rollbackFor = Exception.class)
public Boolean applyWithdrawal(Double price, String realName, String connectNumber) {
if (price == null || price <= 0 || price > 1000000) {
throw new ServiceException(ResultCode.WALLET_WITHDRAWAL_AMOUNT_ERROR);
}
AuthUser authUser = UserContext.getCurrentUser();
//校验金额是否满足提现,因为是从余额扣减,所以校验的是余额
@@ -312,7 +315,6 @@ public class MemberWalletServiceImpl extends ServiceImpl<MemberWalletMapper, Mem
public Boolean withdrawal(String withdrawApplyId) {
MemberWithdrawApply memberWithdrawApply = memberWithdrawApplyService.getById(withdrawApplyId);
memberWithdrawApply.setInspectTime(new Date());
//获取提现设置
Setting setting = settingService.get(SettingEnum.WITHDRAWAL_SETTING.name());
WithdrawalSetting withdrawalSetting = new Gson().fromJson(setting.getSettingValue(), WithdrawalSetting.class);

View File

@@ -42,6 +42,11 @@ public class RechargeServiceImpl extends ServiceImpl<RechargeMapper, Recharge> i
@Override
public Recharge recharge(Double price) {
if (price == null || price <= 0 || price > 1000000) {
throw new ServiceException(ResultCode.RECHARGE_PRICE_ERROR);
}
//获取当前登录的会员
AuthUser authUser = UserContext.getCurrentUser();
//构建sn