| | |
| | | Long memberId = dappMemberEntity.getId(); |
| | | DappMemberEntity member = dappMemberDao.selectById(memberId); |
| | | int isOnHook = member.getIsOnHook() == null ? 2 : member.getIsOnHook(); |
| | | if(1 == isOnHook){ |
| | | if(2 != isOnHook){ |
| | | return new FebsResponse().fail().message(MessageSourceUtils.getString("Operation_002")); |
| | | } |
| | | //挂机金额的倍数 |
| | |
| | | dappWalletCoinDao.addTotalAndaddAvailableById(memberId,total); |
| | | //生成流水记录 |
| | | BigDecimal add = availableAmount.add(total); |
| | | DappAccountMoneyChangeEntity dappAccountMoneyChangeEntity = new DappAccountMoneyChangeEntity(memberId, availableAmount, total, add, "挂机收益", 5); |
| | | DappAccountMoneyChangeEntity dappAccountMoneyChangeEntity = new DappAccountMoneyChangeEntity(memberId, availableAmount, total, add, "投注盈利", 5); |
| | | dappAccountMoneyChangeDao.insert(dappAccountMoneyChangeEntity); |
| | | //更新用户表是否正在挂机状态字段为否 |
| | | DappMemberEntity dappMember= dappMemberDao.selectById(memberId); |
| | |
| | | return new FebsResponse().success().data(apiPlanInfoVo); |
| | | } |
| | | |
| | | @Override |
| | | public BigDecimal getTotalFrofit(Long memberId) { |
| | | BigDecimal totalProfit = igtOnHookPlanOrderDao.selectSumProfitByMemberId(memberId); |
| | | return totalProfit; |
| | | } |
| | | |
| | | private String getProfitCase(String identity,BigDecimal balance){ |
| | | //匹配会员等级获取对应的收益率 |
| | | List<DataDictionaryCustom> dataDictionaryCustoms = dataDictionaryCustomMapper.selectDicByType(DataDictionaryEnum.LEVEL_MB.getType()); |