| | |
| | |
|
| | |
|
| | | @Override
|
| | | public List<IntegralTaskRecord> listNotReceivedExcludeId(int count, long uid, Set<Long> idList) {
|
| | | if (idList != null && idList.size() == 0) {
|
| | | idList = null;
|
| | | }
|
| | | return integralTaskRecordMapper.listNotReceivedExcludeId(count, uid, idList);
|
| | | }
|
| | | |
| | | |
| | | @Override
|
| | | @Transactional
|
| | | public Integer receiveGoldCoinALL(Long uid) throws IntegralTaskRecordException {
|
| | | UserInfoExtra userInfoExtra = userInfoExtraService.getUserInfoExtra(uid);
|
| | | if (userInfoExtra == null) |
| | | throw new IntegralTaskRecordException(1, "用户信息不全");
|
| | | |
| | | int totalGoldCoin = integralTaskRecordMapper.countTotalGoldCoin(uid);
|
| | | if (totalGoldCoin > 0) {
|
| | | integralTaskRecordMapper.updateReceived(uid);
|
| | | }
|
| | | |
| | | Integer goldCoin = userInfoExtra.getGoldCoin();
|
| | | if (goldCoin == null) |
| | | goldCoin = 0;
|
| | | |
| | | UserInfoExtra extra = new UserInfoExtra();
|
| | | extra.setId(userInfoExtra.getId());
|
| | | extra.setGoldCoin(goldCoin + totalGoldCoin);
|
| | | try {
|
| | | userInfoExtraService.saveUserInfoExtra(extra);
|
| | | } catch (UserInfoExtraException e) {
|
| | | throw new IntegralTaskRecordException(1, "用户信息不全");
|
| | | }
|
| | | |
| | | return extra.getGoldCoin();
|
| | | }
|
| | | |
| | | |
| | | |
| | | @Override
|
| | | @Transactional
|
| | | public Integer receiveGoldCoin(Long uid, Set<Long> idList) throws IntegralTaskRecordException {
|
| | | if(idList == null || idList.size() == 0) {
|