Browse Source

党建积分记录修改

dev
zhaoqifeng 3 years ago
parent
commit
d2cebe0188
  1. 1
      epmet-module/epmet-point/epmet-point-client/src/main/java/com/epmet/dto/result/PartyPointResultDTO.java
  2. 11
      epmet-module/epmet-point/epmet-point-server/src/main/java/com/epmet/service/impl/UserPointActionLogServiceImpl.java

1
epmet-module/epmet-point/epmet-point-client/src/main/java/com/epmet/dto/result/PartyPointResultDTO.java

@ -25,6 +25,7 @@ public class PartyPointResultDTO implements Serializable {
private String time; private String time;
private String point; private String point;
private String actId; private String actId;
private String actTopic;
private String actType; private String actType;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date actDate; private Date actDate;

11
epmet-module/epmet-point/epmet-point-server/src/main/java/com/epmet/service/impl/UserPointActionLogServiceImpl.java

@ -623,6 +623,7 @@ public class UserPointActionLogServiceImpl extends BaseServiceImpl<UserPointActi
@Override @Override
public List<PartyPointRecordResultDTO> pagePartyPoint(PartyPointFormDTO formDTO) { public List<PartyPointRecordResultDTO> pagePartyPoint(PartyPointFormDTO formDTO) {
List<PartyPointRecordResultDTO> result = new LinkedList<>(); List<PartyPointRecordResultDTO> result = new LinkedList<>();
if (StringUtils.isNotBlank(formDTO.getYear())) {
if (StringUtils.isNotBlank(formDTO.getQuarter())) { if (StringUtils.isNotBlank(formDTO.getQuarter())) {
if (StringUtils.isNotBlank(formDTO.getMonth())) { if (StringUtils.isNotBlank(formDTO.getMonth())) {
formDTO.setStartDate(formDTO.getYear().concat(formDTO.getMonth())); formDTO.setStartDate(formDTO.getYear().concat(formDTO.getMonth()));
@ -657,6 +658,9 @@ public class UserPointActionLogServiceImpl extends BaseServiceImpl<UserPointActi
formDTO.setStartDate(formDTO.getYear()); formDTO.setStartDate(formDTO.getYear());
formDTO.setDateType(NumConstant.ONE_STR); formDTO.setDateType(NumConstant.ONE_STR);
} }
} else {
formDTO.setDateType(NumConstant.FOUR_STR);
}
PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize()); PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize());
List<PartyPointResultDTO> list =baseDao.getPagePartyPoint(formDTO); List<PartyPointResultDTO> list =baseDao.getPagePartyPoint(formDTO);
if (CollectionUtils.isNotEmpty(list)) { if (CollectionUtils.isNotEmpty(list)) {
@ -666,6 +670,7 @@ public class UserPointActionLogServiceImpl extends BaseServiceImpl<UserPointActi
item.setActType(actInfo.getData().getActTypeName()); item.setActType(actInfo.getData().getActTypeName());
item.setActAddress(actInfo.getData().getAddress()); item.setActAddress(actInfo.getData().getAddress());
item.setActDate(actInfo.getData().getHoldTime()); item.setActDate(actInfo.getData().getHoldTime());
item.setActTopic(actInfo.getData().getTopic());
} }
}); });
@ -675,10 +680,10 @@ public class UserPointActionLogServiceImpl extends BaseServiceImpl<UserPointActi
Map<String, List<PartyPointResultDTO>> sortedMap = Maps.newLinkedHashMap(); Map<String, List<PartyPointResultDTO>> sortedMap = Maps.newLinkedHashMap();
map.entrySet().stream().sorted(Map.Entry.<String, List<PartyPointResultDTO>>comparingByKey().reversed()) map.entrySet().stream().sorted(Map.Entry.<String, List<PartyPointResultDTO>>comparingByKey().reversed())
.forEachOrdered(e -> sortedMap.put(e.getKey(), e.getValue())); .forEachOrdered(e -> sortedMap.put(e.getKey(), e.getValue()));
sortedMap.entrySet().forEach(e -> { sortedMap.forEach((key, value) -> {
PartyPointRecordResultDTO o = new PartyPointRecordResultDTO(); PartyPointRecordResultDTO o = new PartyPointRecordResultDTO();
o.setDate(e.getKey()); o.setDate(key);
o.setDailyList(e.getValue()); o.setDailyList(value);
result.add(o); result.add(o);
}); });

Loading…
Cancel
Save