周任务抽奖
This commit is contained in:
parent
e9807855b5
commit
53c5bd3fb8
|
|
@ -268,6 +268,7 @@ public class AppController {
|
||||||
}
|
}
|
||||||
Map<String, Object> map = BeanUtil.beanToMap(user);
|
Map<String, Object> map = BeanUtil.beanToMap(user);
|
||||||
map.putAll(BeanUtil.beanToMap(userInfo));
|
map.putAll(BeanUtil.beanToMap(userInfo));
|
||||||
|
map.put("userId",map.get("userId").toString());
|
||||||
if (StrUtil.isBlank(user.getZhiFuBaoName()) && StrUtil.isNotBlank(userInfo.getCertName())) {
|
if (StrUtil.isBlank(user.getZhiFuBaoName()) && StrUtil.isNotBlank(userInfo.getCertName())) {
|
||||||
map.put("zhiFuBaoName", userInfo.getCertName());
|
map.put("zhiFuBaoName", userInfo.getCertName());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -218,7 +218,7 @@ public class DiscSpinningController {
|
||||||
centerRecord.setTaskId(Long.valueOf(entry.getKey()));
|
centerRecord.setTaskId(Long.valueOf(entry.getKey()));
|
||||||
if (source.equals(2)) {
|
if (source.equals(2)) {
|
||||||
sourceId = Long.valueOf(entry.getKey());
|
sourceId = Long.valueOf(entry.getKey());
|
||||||
centerRecord.setSourceId(Long.getLong(entry.getKey()));
|
centerRecord.setSourceId(sourceId);
|
||||||
}
|
}
|
||||||
centerRecord.setName(source.equals(2) ? "周任务奖励" : "月任务奖励");
|
centerRecord.setName(source.equals(2) ? "周任务奖励" : "月任务奖励");
|
||||||
centerRecord.setType(9);
|
centerRecord.setType(9);
|
||||||
|
|
|
||||||
|
|
@ -348,7 +348,7 @@ public class TaskCenterServiceImpl extends ServiceImpl<TaskCenterDao, TaskCenter
|
||||||
if (CollectionUtil.isEmpty(rewardMap)) {
|
if (CollectionUtil.isEmpty(rewardMap)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
Map<Integer, Integer> taskWRedisMap = new HashMap<>();
|
Map<Long, Integer> taskWRedisMap = new HashMap<>();
|
||||||
if ("2".equals(type)) {
|
if ("2".equals(type)) {
|
||||||
//抽奖次数
|
//抽奖次数
|
||||||
Map<Long, Integer> taskWCount = signRecordService.getTaskWCount(userId, rewardMap.get(9));
|
Map<Long, Integer> taskWCount = signRecordService.getTaskWCount(userId, rewardMap.get(9));
|
||||||
|
|
@ -358,7 +358,7 @@ public class TaskCenterServiceImpl extends ServiceImpl<TaskCenterDao, TaskCenter
|
||||||
Integer value = entry.getValue();
|
Integer value = entry.getValue();
|
||||||
if (value > 0) {
|
if (value > 0) {
|
||||||
countTaskDisc = countTaskDisc + value;
|
countTaskDisc = countTaskDisc + value;
|
||||||
taskWRedisMap.put(key.intValue(), value);
|
taskWRedisMap.put(key, value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -374,7 +374,7 @@ public class TaskCenterServiceImpl extends ServiceImpl<TaskCenterDao, TaskCenter
|
||||||
Integer spinningCount = discSpinningRecordService.countSourceRecord(taskCenter.getId());
|
Integer spinningCount = discSpinningRecordService.countSourceRecord(taskCenter.getId());
|
||||||
countTaskDisc = rewardMap.get(9) + (spinningCount == null ? 0 : spinningCount);
|
countTaskDisc = rewardMap.get(9) + (spinningCount == null ? 0 : spinningCount);
|
||||||
if (countTaskDisc > 0) {
|
if (countTaskDisc > 0) {
|
||||||
taskWRedisMap.put(taskCenter.getId().intValue(), countTaskDisc);
|
taskWRedisMap.put(taskCenter.getId(), countTaskDisc);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue