| | |
| | | |
| | | @Override |
| | | public FebsResponse forgetPwd(ForgetPwdDto forgetPwdDto) { |
| | | MallMember mallMember = this.baseMapper.selectInfoByAccount(forgetPwdDto.getPhone()); |
| | | // MallMember mallMember = this.baseMapper.selectInfoByAccount(forgetPwdDto.getAccount()); |
| | | // MallMember mallMember = this.baseMapper.selectInfoByAccount(forgetPwdDto.getPhone()); |
| | | MallMember mallMember = this.baseMapper.selectInfoByAccount(forgetPwdDto.getAccount()); |
| | | if (mallMember == null) { |
| | | throw new FebsException("账号不存在"); |
| | | } |
| | |
| | | public BigDecimal canMoney() { |
| | | Long memberId = LoginUserUtil.getLoginUser().getId(); |
| | | MallMemberWallet wallet = mallMemberWalletMapper.selectWalletByMemberId(memberId); |
| | | BigDecimal profit = mallMoneyFlowMapper.selectProfitByDateAndMemberId(memberId); |
| | | |
| | | BigDecimal canMoney = wallet.getCommission(); |
| | | if (profit != null) { |
| | | if(canMoney.compareTo(BigDecimal.ZERO) > 0) { |
| | | canMoney = canMoney.subtract(profit); |
| | | } |
| | | } |
| | | return canMoney; |
| | | return wallet.getBalance(); |
| | | } |
| | | |
| | | @Override |
| | |
| | | commissionVo.setLevelName(MemberLevelTagDicEnums.getDesc(mallMember.getSex(), mallMember.getLevel())); |
| | | |
| | | MallMemberWallet wallet = mallMemberWalletMapper.selectWalletByMemberId(id); |
| | | commissionVo.setCommission(wallet.getCommission()); |
| | | commissionVo.setCommission(wallet.getBalance()); |
| | | commissionVo.setToday(mallMoneyFlowMapper.selectCommissionIncome(1, new Date(), id)); |
| | | commissionVo.setMonth(mallMoneyFlowMapper.selectCommissionIncome(2, new Date(), id)); |
| | | commissionVo.setTotal(mallMoneyFlowMapper.selectCommissionIncome(null, null, id)); |
| | |
| | | @Override |
| | | public List<SkinTypeVo> findSkinList() { |
| | | MallMember loginUser = LoginUserUtil.getLoginUser(); |
| | | DataDictionaryCustom dic = dataDictionaryCustomMapper.selectDicDataByTypeAndCode(AppContants.SKIN_TYPE_LIST, loginUser.getLevel()); |
| | | String level = loginUser.getLevel(); |
| | | // 全网分红 -- 代理和股东当作是女王殿下级别 |
| | | if (MemberLevelEnum.getLevelCode(level) > MemberLevelEnum.FOUR_LEVEL.getCode()) { |
| | | level = MemberLevelEnum.FOUR_LEVEL.getType(); |
| | | } |
| | | DataDictionaryCustom dic = dataDictionaryCustomMapper.selectDicDataByTypeAndCode(AppContants.SKIN_TYPE_LIST, level); |
| | | if (dic == null || StrUtil.isBlank(dic.getValue())) { |
| | | throw new FebsException("请检查皮肤配置"); |
| | | } |