|
@@ -32,9 +32,10 @@ public class MsgNewUtil {
|
|
|
String conType = ruleSimpleDTO.getConType(); // 禁忌类型
|
|
|
String unionMsg = ruleSimpleDTO.getMsg(); // 原因及建议
|
|
|
String msg = redisUtil.getByKeyAndField(RedisEnum.msg.getName(), orderType + "_" + conType);
|
|
|
- // if (StringUtil.isBlank(msg)) {
|
|
|
- // msg = redisUtil.getByKeyAndField(RedisEnum.msg.getName(), "通用" + "_" + "默认提示语");
|
|
|
- // }
|
|
|
+ if (StringUtil.isBlank(msg)) {
|
|
|
+ // msg = redisUtil.getByKeyAndField(RedisEnum.msg.getName(), "通用" + "_" + "默认提示语");
|
|
|
+ msg = "";
|
|
|
+ }
|
|
|
BillMsg billMsg = new BillMsg();
|
|
|
// 出现2个“具有”,去除一个为空
|
|
|
if (ConEnum.medEqu.getName().equals(conType) && StringUtil.isNotBlank(content)
|
|
@@ -46,6 +47,16 @@ public class MsgNewUtil {
|
|
|
} else {
|
|
|
msg = msg.replaceAll("\\[原因及建议]", "");
|
|
|
}
|
|
|
+ // [性别取反]标签替换
|
|
|
+ if (ConEnum.gender.getName().equals(conType)) {
|
|
|
+ if ("男".equals(content)) {
|
|
|
+ msg = msg.replaceAll("\\[性别取反]", "女");
|
|
|
+ } else if ("女".equals(content)) {
|
|
|
+ msg = msg.replaceAll("\\[性别取反]", "男");
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ // 放到最后统一替换【多处匹配】
|
|
|
msg = msg.replaceAll("\\[匹配内容]", content);
|
|
|
msg = msg.replaceAll("\\[开单名称]", orderName);
|
|
|
billMsg.setMsg(msg);
|