Commit 019e0676 authored by Smile's avatar Smile

fix:app站内信多语言修改

parent ea678a8b
...@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.customer.service.customer.complaint; ...@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.customer.service.customer.complaint;
import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService; import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService;
import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils; import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils;
import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils;
...@@ -92,8 +93,12 @@ public class CustomerComplaintServiceImpl extends AbstractService<CustomerCompla ...@@ -92,8 +93,12 @@ public class CustomerComplaintServiceImpl extends AbstractService<CustomerCompla
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(updateReqVO.getCustomerId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(updateReqVO.getCustomerId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.customer.complain.title")) .title(I18nMessage.getMessage("app.message.customer.complain.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.customer.complain.content")) .titleEn(I18nMessage.getMessage("app.message.customer.complain.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.customer.complain.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.customer.complain.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.customer.complain.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.customer.complain.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
......
...@@ -28,11 +28,19 @@ public class InternalMessageCreateDto { ...@@ -28,11 +28,19 @@ public class InternalMessageCreateDto {
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private Date sendTime; private Date sendTime;
@ApiModelProperty(value = "标题") @ApiModelProperty(value = "标题中文")
private String title; private String title;
@ApiModelProperty(value = "标题英文")
private String titleEn;
@ApiModelProperty(value = "标题法文")
private String titleFr;
@ApiModelProperty(value = "内容") @ApiModelProperty(value = "内容中文")
private String content; private String content;
@ApiModelProperty(value = "内容英文")
private String contentEn;
@ApiModelProperty(value = "内容法文")
private String contentFr;
@ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息") @ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息")
private Integer type; private Integer type;
......
...@@ -22,7 +22,7 @@ import java.util.Date; ...@@ -22,7 +22,7 @@ import java.util.Date;
public class WebInternalMessageDO extends BaseDO { public class WebInternalMessageDO extends BaseDO {
/** /**
* *
*/ */
@TableId @TableId
private Long id; private Long id;
...@@ -35,13 +35,29 @@ public class WebInternalMessageDO extends BaseDO { ...@@ -35,13 +35,29 @@ public class WebInternalMessageDO extends BaseDO {
*/ */
private Date sendTime; private Date sendTime;
/** /**
* 标题 * 标题中文
*/ */
private String title; private String title;
/** /**
* 内容 * 标题英文
*/
private String titleEn;
/**
* 标题法文
*/
private String titleFr;
/**
* 内容中文
*/ */
private String content; private String content;
/**
* 内容英文
*/
private String contentEn;
/**
* 内容法文
*/
private String contentFr;
/** /**
* 1订单消息,2出货消息,3提醒消息 * 1订单消息,2出货消息,3提醒消息
*/ */
......
...@@ -32,14 +32,30 @@ public class InternalMessageBackVO { ...@@ -32,14 +32,30 @@ public class InternalMessageBackVO {
@ApiModelProperty(value = "发送时间") @ApiModelProperty(value = "发送时间")
private Date sendTime; private Date sendTime;
@ExcelProperty("标题") @ExcelProperty("标题中文")
@ApiModelProperty(value = "标题") @ApiModelProperty(value = "标题中文")
private String title; private String title;
@ExcelProperty("内容") @ExcelProperty("标题英文")
@ApiModelProperty(value = "内容") @ApiModelProperty(value = "标题英文")
private String titleEn;
@ExcelProperty("标题法文")
@ApiModelProperty(value = "标题法文")
private String titleFr;
@ExcelProperty("内容中文")
@ApiModelProperty(value = "内容中文")
private String content; private String content;
@ExcelProperty("内容英文")
@ApiModelProperty(value = "内容英文")
private String contentEn;
@ExcelProperty("内容法文")
@ApiModelProperty(value = "内容法文")
private String contentFr;
@ExcelProperty("1订单消息,2出货消息,3提醒消息") @ExcelProperty("1订单消息,2出货消息,3提醒消息")
@ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息") @ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息")
private Integer type; private Integer type;
......
...@@ -24,12 +24,24 @@ public class InternalMessageBaseVO { ...@@ -24,12 +24,24 @@ public class InternalMessageBaseVO {
@JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY) @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY)
private Date sendTime; private Date sendTime;
@ApiModelProperty(value = "标题") @ApiModelProperty(value = "标题中文")
private String title; private String title;
@ApiModelProperty(value = "内容") @ApiModelProperty(value = "标题英文")
private String titleEn;
@ApiModelProperty(value = "标题法文")
private String titleFr;
@ApiModelProperty(value = "内容中文")
private String content; private String content;
@ApiModelProperty(value = "内容英文")
private String contentEn;
@ApiModelProperty(value = "内容法文")
private String contentFr;
@ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息") @ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息")
private Integer type; private Integer type;
......
...@@ -24,12 +24,24 @@ public class InternalMessageQueryVO { ...@@ -24,12 +24,24 @@ public class InternalMessageQueryVO {
@ApiModelProperty(value = "结束发送时间") @ApiModelProperty(value = "结束发送时间")
private Date endSendTime; private Date endSendTime;
@ApiModelProperty(value = "标题") @ApiModelProperty(value = "标题中文")
private String title; private String title;
@ApiModelProperty(value = "内容") @ApiModelProperty(value = "标题英文")
private String titleEn;
@ApiModelProperty(value = "标题法文")
private String titleFr;
@ApiModelProperty(value = "内容中文")
private String content; private String content;
@ApiModelProperty(value = "内容英文")
private String contentEn;
@ApiModelProperty(value = "内容法文")
private String contentFr;
@ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息") @ApiModelProperty(value = "1订单消息,2出货消息,3提醒消息")
private Integer type; private Integer type;
......
...@@ -4,6 +4,7 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult; ...@@ -4,6 +4,7 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.excel.util.ExcelUtils; import cn.iocoder.yudao.framework.excel.util.ExcelUtils;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO; import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO;
import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog;
...@@ -295,8 +296,12 @@ public class MemberUserController { ...@@ -295,8 +296,12 @@ public class MemberUserController {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuth.getUserId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuth.getUserId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.kyc.success.title")) .title(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.success.content")) .titleEn(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
...@@ -305,8 +310,12 @@ public class MemberUserController { ...@@ -305,8 +310,12 @@ public class MemberUserController {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuth.getUserId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuth.getUserId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.kyc.failed.title")) .title(I18nMessage.getMessage("app.message.kyc.failed.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.failed.content") + reqVO.getAuditRemark()) .titleEn(I18nMessage.getMessage("app.message.kyc.failed.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.kyc.failed.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.failed.content", LangEnum.ZH.getLang()) + reqVO.getAuditRemark())
.contentEn(I18nMessage.getMessage("app.message.kyc.failed.content", LangEnum.EN.getLang()) + reqVO.getAuditRemark())
.contentFr(I18nMessage.getMessage("app.message.kyc.failed.content", LangEnum.FR.getLang()) + reqVO.getAuditRemark())
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
...@@ -342,8 +351,12 @@ public class MemberUserController { ...@@ -342,8 +351,12 @@ public class MemberUserController {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuthId)) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userCardAuthId))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.kyc.success.title")) .title(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.success.content")) .titleEn(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.kyc.success.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.kyc.success.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
......
...@@ -9,6 +9,7 @@ import cn.iocoder.yudao.framework.common.util.spring.enums.CommonStatusEnum; ...@@ -9,6 +9,7 @@ import cn.iocoder.yudao.framework.common.util.spring.enums.CommonStatusEnum;
import cn.iocoder.yudao.framework.common.util.spring.enums.UserTypeEnum; import cn.iocoder.yudao.framework.common.util.spring.enums.UserTypeEnum;
import cn.iocoder.yudao.framework.common.util.validation.PhoneUtil; import cn.iocoder.yudao.framework.common.util.validation.PhoneUtil;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.security.core.LoginUser; import cn.iocoder.yudao.framework.security.core.LoginUser;
import cn.iocoder.yudao.framework.security.core.authentication.MultiUsernamePasswordAuthenticationToken; import cn.iocoder.yudao.framework.security.core.authentication.MultiUsernamePasswordAuthenticationToken;
import cn.iocoder.yudao.module.customer.dal.dataobject.customer.CustomerDO; import cn.iocoder.yudao.module.customer.dal.dataobject.customer.CustomerDO;
...@@ -400,8 +401,12 @@ public class MemberAuthServiceImpl implements MemberAuthService { ...@@ -400,8 +401,12 @@ public class MemberAuthServiceImpl implements MemberAuthService {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userId)) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userId))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.update.password.title")) .title(I18nMessage.getMessage("app.message.update.password.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.update.password.content")) .titleEn(I18nMessage.getMessage("app.message.update.password.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.update.password.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.update.password.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.update.password.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.update.password.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
...@@ -423,8 +428,12 @@ public class MemberAuthServiceImpl implements MemberAuthService { ...@@ -423,8 +428,12 @@ public class MemberAuthServiceImpl implements MemberAuthService {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userDO.getId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userDO.getId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.update.password.title")) .title(I18nMessage.getMessage("app.message.update.password.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.update.password.content")) .titleEn(I18nMessage.getMessage("app.message.update.password.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.update.password.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.update.password.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.update.password.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.update.password.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
...@@ -442,8 +451,12 @@ public class MemberAuthServiceImpl implements MemberAuthService { ...@@ -442,8 +451,12 @@ public class MemberAuthServiceImpl implements MemberAuthService {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userId)) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userId))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.update.control.password.title")) .title(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.update.control.password.content")) .titleEn(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
...@@ -465,8 +478,12 @@ public class MemberAuthServiceImpl implements MemberAuthService { ...@@ -465,8 +478,12 @@ public class MemberAuthServiceImpl implements MemberAuthService {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userDO.getId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(userDO.getId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.update.control.password.title")) .title(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.update.control.password.content")) .titleEn(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.update.control.password.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.update.control.password.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
//记录日志 //记录日志
......
...@@ -10,6 +10,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult; ...@@ -10,6 +10,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.common.util.date.DateUtils; import cn.iocoder.yudao.framework.common.util.date.DateUtils;
import cn.iocoder.yudao.framework.common.util.spring.enums.CommonStatusEnum; import cn.iocoder.yudao.framework.common.util.spring.enums.CommonStatusEnum;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils; import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils;
import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO; import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO;
...@@ -230,8 +231,12 @@ public class MemberUserServiceImpl implements MemberUserService { ...@@ -230,8 +231,12 @@ public class MemberUserServiceImpl implements MemberUserService {
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(user.getId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(user.getId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.reg.success.title")) .title(I18nMessage.getMessage("app.message.reg.success.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.reg.success.content")) .titleEn(I18nMessage.getMessage("app.message.reg.success.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.reg.success.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.reg.success.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.reg.success.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.reg.success.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
......
...@@ -4,6 +4,7 @@ import java.util.*; ...@@ -4,6 +4,7 @@ import java.util.*;
import javax.annotation.Resource; import javax.annotation.Resource;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.module.ecw.api.internalMessage.ClientInternalMessageApi; import cn.iocoder.yudao.module.ecw.api.internalMessage.ClientInternalMessageApi;
import cn.iocoder.yudao.module.ecw.api.internalMessage.dto.InternalMessageCreateDto; import cn.iocoder.yudao.module.ecw.api.internalMessage.dto.InternalMessageCreateDto;
import cn.iocoder.yudao.module.member.enums.UserAuditStatusEnum; import cn.iocoder.yudao.module.member.enums.UserAuditStatusEnum;
...@@ -72,8 +73,12 @@ public class UserCardAuthServiceImpl extends AbstractService<UserCardAuthMapper, ...@@ -72,8 +73,12 @@ public class UserCardAuthServiceImpl extends AbstractService<UserCardAuthMapper,
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(createReqVO.getUserId())) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(Arrays.asList(createReqVO.getUserId()))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.kyc.submit.title")) .title(I18nMessage.getMessage("app.message.kyc.submit.title", LangEnum.ZH.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.submit.content")) .titleEn(I18nMessage.getMessage("app.message.kyc.submit.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.kyc.submit.title", LangEnum.FR.getLang()))
.content(I18nMessage.getMessage("app.message.kyc.submit.content", LangEnum.ZH.getLang()))
.contentEn(I18nMessage.getMessage("app.message.kyc.submit.content", LangEnum.EN.getLang()))
.contentFr(I18nMessage.getMessage("app.message.kyc.submit.content", LangEnum.FR.getLang()))
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
......
package cn.iocoder.yudao.module.member.vo.userLevel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotNull;
@Data
@ApiModel("管理后台 - 等级规则id请求 VO")
public class IdReqVo {
@ApiModelProperty(value = "主键", required = true)
@NotNull(message = "主键不能为空")
private Long id;
}
...@@ -8,6 +8,7 @@ import cn.iocoder.yudao.framework.common.util.date.DateUtils; ...@@ -8,6 +8,7 @@ import cn.iocoder.yudao.framework.common.util.date.DateUtils;
import cn.iocoder.yudao.framework.common.util.spring.enums.UserTypeEnum; import cn.iocoder.yudao.framework.common.util.spring.enums.UserTypeEnum;
import cn.iocoder.yudao.framework.dict.core.dto.DictDataRespDTO; import cn.iocoder.yudao.framework.dict.core.dto.DictDataRespDTO;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService; import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService;
import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils; import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils;
import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO; import cn.iocoder.yudao.framework.mybatis.core.vo.PageVO;
...@@ -380,8 +381,14 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo ...@@ -380,8 +381,14 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(new ArrayList<>(userIds)) InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(new ArrayList<>(userIds))
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(I18nMessage.getMessage("app.message.pick.title")) .title(I18nMessage.getMessage("app.message.pick.title", LangEnum.ZH.getLang()))
.content(MessageFormat.format(I18nMessage.getMessage("app.message.pick.content"), .titleEn(I18nMessage.getMessage("app.message.pick.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("app.message.pick.title", LangEnum.FR.getLang()))
.content(MessageFormat.format(I18nMessage.getMessage("app.message.pick.content", LangEnum.ZH.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), DateUtil.format(now, "yyyy年MM月dd日"), createReqVO.getPickNum()))
.contentEn(MessageFormat.format(I18nMessage.getMessage("app.message.pick.content", LangEnum.EN.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), DateUtil.format(now, "yyyy年MM月dd日"), createReqVO.getPickNum()))
.contentFr(MessageFormat.format(I18nMessage.getMessage("app.message.pick.content", LangEnum.FR.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), DateUtil.format(now, "yyyy年MM月dd日"), createReqVO.getPickNum())) orderDO.getOrderNo(), orderDO.getMarks(), DateUtil.format(now, "yyyy年MM月dd日"), createReqVO.getPickNum()))
.type(1).build(); .type(1).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
......
...@@ -11,6 +11,7 @@ import cn.iocoder.yudao.framework.apollo.core.event.LineChannelUpdateAirWeightEv ...@@ -11,6 +11,7 @@ import cn.iocoder.yudao.framework.apollo.core.event.LineChannelUpdateAirWeightEv
import cn.iocoder.yudao.framework.common.exception.enums.GlobalErrorCodeConstants; import cn.iocoder.yudao.framework.common.exception.enums.GlobalErrorCodeConstants;
import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.query.QueryWrapperX; import cn.iocoder.yudao.framework.mybatis.core.query.QueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService; import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService;
import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils; import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils;
...@@ -296,7 +297,17 @@ public class OrderExceptionServiceImpl extends AbstractService<OrderExceptionMap ...@@ -296,7 +297,17 @@ public class OrderExceptionServiceImpl extends AbstractService<OrderExceptionMap
if (ids.size() > 0 && (orderDO.getInWarehouseState() > 0 || orderDO.getShipmentState() > 0)) { if (ids.size() > 0 && (orderDO.getInWarehouseState() > 0 || orderDO.getShipmentState() > 0)) {
// 判断入仓状态或出货状态不为0,则表示订单肯定入仓了 // 判断入仓状态或出货状态不为0,则表示订单肯定入仓了
//发送站内信 //发送站内信
InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(new ArrayList<>(ids)).fromId("").sendTime(new Date()).title(I18nMessage.getMessage("order.exception.internalmessage.title")).content(StrUtil.format(I18nMessage.getMessage("order.exception.internalmessage.content"), orderDO.getOrderNo(), orderDO.getMarks(), createReqVO.getOrderExceptionDescVO().getDescZh())).type(1).build(); InternalMessageCreateDto dto = InternalMessageCreateDto.builder().toIdList(new ArrayList<>(ids))
.fromId("")
.sendTime(new Date())
.title(I18nMessage.getMessage("order.exception.internalmessage.title", LangEnum.ZH.getLang()))
.titleEn(I18nMessage.getMessage("order.exception.internalmessage.title", LangEnum.EN.getLang()))
.titleFr(I18nMessage.getMessage("order.exception.internalmessage.title", LangEnum.FR.getLang()))
.content(StrUtil.format(I18nMessage.getMessage("order.exception.internalmessage.content", LangEnum.ZH.getLang()), orderDO.getOrderNo(), orderDO.getMarks(), createReqVO.getOrderExceptionDescVO().getDescZh()))
.contentEn(StrUtil.format(I18nMessage.getMessage("order.exception.internalmessage.content", LangEnum.EN.getLang()), orderDO.getOrderNo(), orderDO.getMarks(), createReqVO.getOrderExceptionDescVO().getDescZh()))
.contentFr(StrUtil.format(I18nMessage.getMessage("order.exception.internalmessage.content", LangEnum.FR.getLang()), orderDO.getOrderNo(), orderDO.getMarks(), createReqVO.getOrderExceptionDescVO().getDescZh()))
.type(1)
.build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
} }
} }
......
...@@ -16,6 +16,7 @@ import cn.iocoder.yudao.framework.common.util.date.DateUtils; ...@@ -16,6 +16,7 @@ import cn.iocoder.yudao.framework.common.util.date.DateUtils;
import cn.iocoder.yudao.framework.dict.core.dto.DictDataRespDTO; import cn.iocoder.yudao.framework.dict.core.dto.DictDataRespDTO;
import cn.iocoder.yudao.framework.dict.core.util.DictFrameworkUtils; import cn.iocoder.yudao.framework.dict.core.util.DictFrameworkUtils;
import cn.iocoder.yudao.framework.i18n.core.I18nMessage; import cn.iocoder.yudao.framework.i18n.core.I18nMessage;
import cn.iocoder.yudao.framework.i18n.core.LangEnum;
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService; import cn.iocoder.yudao.framework.mybatis.core.service.AbstractService;
...@@ -2620,26 +2621,56 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI ...@@ -2620,26 +2621,56 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
UserRespDTO user = memberUserApi.getUser(userId); UserRespDTO user = memberUserApi.getUser(userId);
if (user != null && StringUtils.isNotEmpty(user.getNickname())) { if (user != null && StringUtils.isNotEmpty(user.getNickname())) {
String title = ""; String title = "";
String titleEn = "";
String titleFr = "";
String content = ""; String content = "";
String contentEn = "";
String contentFr = "";
if (orderDO.getTransportId() == 3) { if (orderDO.getTransportId() == 3) {
if (StringUtils.isNotBlank(exceptionContent)) { if (StringUtils.isNotBlank(exceptionContent)) {
// 空运有异常入仓 // 空运有异常入仓
title = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.title"), orderDO.getOrderNo()); title = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.title", LangEnum.ZH.getLang()), orderDO.getOrderNo());
titleEn = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.title", LangEnum.EN.getLang()), orderDO.getOrderNo());
titleFr = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.title", LangEnum.FR.getLang()), orderDO.getOrderNo());
// 订单号:%s(唛头:%s)已入仓,存在异常:%s 请联系售前客服协助处理。如有疑问请于工作时间内(9:00--18:00)与我司客服联系:400-900-9962 // 订单号:%s(唛头:%s)已入仓,存在异常:%s 请联系售前客服协助处理。如有疑问请于工作时间内(9:00--18:00)与我司客服联系:400-900-9962
content = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content"), content = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.ZH.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
contentEn = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.EN.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
contentFr = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.FR.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent); orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
} else { } else {
// 空运无异常入仓 // 空运无异常入仓
title = String.format(I18nMessage.getMessage("app.message.air.warehousein.title"), orderDO.getOrderNo()); title = String.format(I18nMessage.getMessage("app.message.air.warehousein.title"), orderDO.getOrderNo(), LangEnum.ZH.getLang());
titleEn = String.format(I18nMessage.getMessage("app.message.air.warehousein.title"), orderDO.getOrderNo(), LangEnum.EN.getLang());
titleFr = String.format(I18nMessage.getMessage("app.message.air.warehousein.title"), orderDO.getOrderNo(), LangEnum.FR.getLang());
// 尊敬的 %s(先生/女士),捷道货运通知您:您的唛头为%s,%s箱, %sCBM, %sKg, 入仓号为%s的货物已于%s 送到%s(起运港仓库),如有疑问请于工作时间内(9:00--18:00)与我司客服联系:400-900-9962 // 尊敬的 %s(先生/女士),捷道货运通知您:您的唛头为%s,%s箱, %sCBM, %sKg, 入仓号为%s的货物已于%s 送到%s(起运港仓库),如有疑问请于工作时间内(9:00--18:00)与我司客服联系:400-900-9962
content = String.format(I18nMessage.getMessage("app.message.air.warehousein.content"), content = String.format(I18nMessage.getMessage("app.message.air.warehousein.content", LangEnum.ZH.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName);
contentEn = String.format(I18nMessage.getMessage("app.message.air.warehousein.content", LangEnum.EN.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName);
contentFr = String.format(I18nMessage.getMessage("app.message.air.warehousein.content", LangEnum.FR.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(), user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"), orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName); startWarehouseName);
} }
} else { } else {
title = String.format(I18nMessage.getMessage("app.message.warehousein.title"), orderDO.getOrderNo()); title = String.format(I18nMessage.getMessage("app.message.warehousein.title", LangEnum.ZH.getLang()), orderDO.getOrderNo());
content = String.format(I18nMessage.getMessage("app.message.warehousein.content"), titleEn = String.format(I18nMessage.getMessage("app.message.warehousein.title", LangEnum.EN.getLang()), orderDO.getOrderNo());
titleFr = String.format(I18nMessage.getMessage("app.message.warehousein.title", LangEnum.FR.getLang()), orderDO.getOrderNo());
content = String.format(I18nMessage.getMessage("app.message.warehousein.content", LangEnum.ZH.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName);
contentEn = String.format(I18nMessage.getMessage("app.message.warehousein.content", LangEnum.EN.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName);
contentFr = String.format(I18nMessage.getMessage("app.message.warehousein.content", LangEnum.FR.getLang()),
user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(), user.getNickname(), orderDO.getMarks(), orderDO.getSumNum(), orderDO.getSumVolume().toPlainString(),
orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"), orderDO.getSumWeight().toPlainString(), orderDO.getOrderNo(), DateUtil.format(ruchang, "yyyy年MM月dd日"),
startWarehouseName); startWarehouseName);
...@@ -2649,7 +2680,11 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI ...@@ -2649,7 +2680,11 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
.fromId("") .fromId("")
.sendTime(new Date()) .sendTime(new Date())
.title(title) .title(title)
.titleEn(titleEn)
.titleFr(titleFr)
.content(content) .content(content)
.contentEn(contentEn)
.contentFr(contentFr)
.type(3).build(); .type(3).build();
clientInternalMessageApi.createInternalMessage(dto); clientInternalMessageApi.createInternalMessage(dto);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment