|
@ -196,29 +196,30 @@ public class PointsLogsServiceImpl extends BaseServiceImpl<PointsLogsDao, Points |
|
|
pointsLogsEntity.setBehaviorCode(formDto.getBehaviorCode()); |
|
|
pointsLogsEntity.setBehaviorCode(formDto.getBehaviorCode()); |
|
|
this.insert(pointsLogsEntity); |
|
|
this.insert(pointsLogsEntity); |
|
|
//给用户发送消息通知
|
|
|
//给用户发送消息通知
|
|
|
this.issueSmsNotification(pointsLogsEntity); |
|
|
this.issueSmsNotification(pointsLogsEntity,formDto); |
|
|
return new Result(); |
|
|
return new Result(); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* @param pointsLogsEntity |
|
|
* @param pointsLogsEntity |
|
|
|
|
|
* @param formDto |
|
|
* @return void |
|
|
* @return void |
|
|
* @Author yinzuomei |
|
|
* @Author yinzuomei |
|
|
* @Description 调整积分完成后-给用户发送消息通知 |
|
|
* @Description 调整积分完成后-给用户发送消息通知 |
|
|
* @Date 2020/2/7 22:12 |
|
|
* @Date 2020/2/7 22:12 |
|
|
**/ |
|
|
**/ |
|
|
private void issueSmsNotification(PointsLogsEntity pointsLogsEntity) { |
|
|
private void issueSmsNotification(PointsLogsEntity pointsLogsEntity, EpdcAdjustVolunteerPointsDTO formDto) { |
|
|
EpdcInformationFormDTO informationFormDTO = new EpdcInformationFormDTO(); |
|
|
EpdcInformationFormDTO informationFormDTO = new EpdcInformationFormDTO(); |
|
|
informationFormDTO.setUserId(pointsLogsEntity.getUserId()); |
|
|
informationFormDTO.setUserId(pointsLogsEntity.getUserId()); |
|
|
String content = ""; |
|
|
String content = ""; |
|
|
//积分操作类型(0-减积分,1-加积分)
|
|
|
//积分操作类型(0-减积分,1-加积分)
|
|
|
if (PointsOperationEnum.OPERATION_TYPE_ADD.getOperationType().equals(pointsLogsEntity.getOperationType())) { |
|
|
if (PointsOperationEnum.OPERATION_TYPE_ADD.getOperationType().equals(pointsLogsEntity.getOperationType())) { |
|
|
informationFormDTO.setTitle(PointsNoticeConstant.ADD_POINTS_NOTICE); |
|
|
informationFormDTO.setTitle(PointsNoticeConstant.ADD_POINTS_NOTICE); |
|
|
content = PointsNoticeConstant.ADD_POINTS + pointsLogsEntity.getPoints() + PointsNoticeConstant.REASON + pointsLogsEntity.getOperationDesc(); |
|
|
content = PointsNoticeConstant.ADD_POINTS + pointsLogsEntity.getPoints() + PointsNoticeConstant.REASON + formDto.getAdjustReason(); |
|
|
|
|
|
|
|
|
} else if (PointsOperationEnum.OPERATION_TYPE_SUBSTRACT.getOperationType().equals(pointsLogsEntity.getOperationType())) { |
|
|
} else if (PointsOperationEnum.OPERATION_TYPE_SUBSTRACT.getOperationType().equals(pointsLogsEntity.getOperationType())) { |
|
|
informationFormDTO.setTitle(PointsNoticeConstant.SUBTRACT_POINTS_NOTICE); |
|
|
informationFormDTO.setTitle(PointsNoticeConstant.SUBTRACT_POINTS_NOTICE); |
|
|
content = PointsNoticeConstant.SUBTRACT_POINTS + pointsLogsEntity.getPoints() + PointsNoticeConstant.REASON + pointsLogsEntity.getOperationDesc(); |
|
|
content = PointsNoticeConstant.SUBTRACT_POINTS + pointsLogsEntity.getPoints() + PointsNoticeConstant.REASON + formDto.getAdjustReason(); |
|
|
} |
|
|
} |
|
|
informationFormDTO.setContent(content); |
|
|
informationFormDTO.setContent(content); |
|
|
informationFormDTO.setType(PointsNoticeConstant.NOTICE_TYPE_INTERACTIVE_NOTICE); |
|
|
informationFormDTO.setType(PointsNoticeConstant.NOTICE_TYPE_INTERACTIVE_NOTICE); |
|
|