zhengfangyuan 3 лет назад
Родитель
Сommit
b2d8702e7d
28 измененных файлов: 482 добавлений и 322 удалений
  1. +1
    -1
      mallinkAdmin/src/main/java/com/iformall/controller/basic/WxProjectConfigController.java
  2. +38
    -38
      mallinkAdmin/src/main/java/com/iformall/controller/msg/WxMsgValidationcodeModelController.java
  3. +31
    -0
      mallinkAdmin/src/main/resources/db/migration/V202301200001__contract.sql
  4. +42
    -3
      mallinkSchedule/src/main/java/com/iformall/schedule/ContractSchedule.java
  5. +1
    -5
      mallinkService/src/main/java/com/iformall/domain/po/WxMsgModel.java
  6. +3
    -5
      mallinkService/src/main/java/com/iformall/domain/po/WxMsgValidationcodeModel.java
  7. +30
    -0
      mallinkService/src/main/java/com/iformall/domain/po/WxMsgValidationcodeModelTenant.java
  8. +9
    -0
      mallinkService/src/main/java/com/iformall/domain/po/WxRentContract.java
  9. +0
    -3
      mallinkService/src/main/java/com/iformall/mapper/WxMsgModelMapper.java
  10. +15
    -0
      mallinkService/src/main/java/com/iformall/mapper/WxMsgValidationcodeModelTenantMapper.java
  11. +3
    -0
      mallinkService/src/main/java/com/iformall/service/WxRentContractService.java
  12. +16
    -16
      mallinkService/src/main/java/com/iformall/service/impl/WxMsgCallbackServiceImpl.java
  13. +8
    -8
      mallinkService/src/main/java/com/iformall/service/impl/WxMsgModelServiceImpl.java
  14. +135
    -135
      mallinkService/src/main/java/com/iformall/service/impl/WxMsgValidationcodeModelServiceImpl.java
  15. +8
    -0
      mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java
  16. +1
    -6
      mallinkService/src/main/java/com/iformall/service/msg/impl/SendCallBackSmsServiceImpl.java
  17. +1
    -2
      mallinkService/src/main/java/com/iformall/service/msg/impl/SendEmailServiceImpl.java
  18. +40
    -18
      mallinkService/src/main/java/com/iformall/service/msg/impl/SendSmsServiceImpl.java
  19. +1
    -1
      mallinkService/src/main/java/com/iformall/sms/SMSExcutor.java
  20. +2
    -2
      mallinkService/src/main/java/com/iformall/sms/SMSFactory.java
  21. +1
    -1
      mallinkService/src/main/java/com/iformall/sms/aliyun/AliyunSMS.java
  22. +2
    -2
      mallinkService/src/main/java/com/iformall/sms/wiwide/WiwideUtil.java
  23. +1
    -22
      mallinkService/src/main/resources/mapper/WxMsgModelMapper.xml
  24. +1
    -12
      mallinkService/src/main/resources/mapper/WxMsgValidationcodeModelMapper.xml
  25. +46
    -0
      mallinkService/src/main/resources/mapper/WxMsgValidationcodeModelTenantMapper.xml
  26. +7
    -3
      mallinkService/src/main/resources/mapper/WxRentContractMapper.xml
  27. +1
    -1
      mallinkTTAdmin/src/main/java/com/iformall/controller/basic/WxProjectConfigController.java
  28. +38
    -38
      mallinkTTAdmin/src/main/java/com/iformall/controller/msg/WxMsgValidationcodeModelController.java

+ 1
- 1
mallinkAdmin/src/main/java/com/iformall/controller/basic/WxProjectConfigController.java Просмотреть файл

@@ -653,7 +653,7 @@ public class WxProjectConfigController extends BaseController {
List<WxQuestion> wxQuestionList = wxQuestionService.findList(wxQuestion);
map.put("wxQuestionList",wxQuestionList);
WxMsgValidationcodeModel wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.setTenantId(wxMall.getTenantId());
//wxMsgValidationcodeModel.setTenantId(wxMall.getTenantId());

List<WxMsgValidationcodeModel> wxMsgValidationcodeModelList = wxMsgValidationcodeModelService.findList(wxMsgValidationcodeModel);
map.put("wxMsgValidationcodeModelList",wxMsgValidationcodeModelList);


+ 38
- 38
mallinkAdmin/src/main/java/com/iformall/controller/msg/WxMsgValidationcodeModelController.java Просмотреть файл

@@ -24,44 +24,44 @@ public class WxMsgValidationcodeModelController extends BaseController {
@Autowired
private WxMsgValidationcodeModelService wxMsgValidationcodeModelService;

@ApiOperation("消息模板-列表")
@GetMapping("list")
@ApiImplicitParams({
@ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true),
@ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)})
@SystemControllerLog(description = "消息验证模板-列表")
public ResultData list(@ModelAttribute WxMsgValidationcodeModel wxMsgValidationcodeModel, Integer pageNum, Integer pageSize) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::list");
if (null == wxMsgValidationcodeModel) wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
PageInfo<WxMsgValidationcodeModel> page = wxMsgValidationcodeModelService.listAsPage(wxMsgValidationcodeModel, pageNum, pageSize);
page.getList().forEach(m -> {
for (EnumMsgModelReplace e : EnumMsgModelReplace.values()) {
m.setContent(m.getContent().replace(e.getCode(),e.getMessage()));
}
});
return new ResultData(page);
}
@ApiOperation("消息模板-添加")
@PostMapping("add")
@SystemControllerLog(description = "消息验证模板-添加")
public ResultData add(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::add");
//Assert.notNull(wxMsgValidationcodeModel.getName(), "角色名不能为空");
//Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
return wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
}
@ApiOperation("消息模板-更新")
@PostMapping("update")
@SystemControllerLog(description = "消息验证模板-更新")
public ResultData update(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::update");
wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
return new ResultData();
}
// @ApiOperation("消息模板-列表")
// @GetMapping("list")
// @ApiImplicitParams({
// @ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true),
// @ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)})
// @SystemControllerLog(description = "消息验证模板-列表")
// public ResultData list(@ModelAttribute WxMsgValidationcodeModel wxMsgValidationcodeModel, Integer pageNum, Integer pageSize) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::list");
// if (null == wxMsgValidationcodeModel) wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
// wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
// PageInfo<WxMsgValidationcodeModel> page = wxMsgValidationcodeModelService.listAsPage(wxMsgValidationcodeModel, pageNum, pageSize);
// page.getList().forEach(m -> {
// for (EnumMsgModelReplace e : EnumMsgModelReplace.values()) {
// m.setContent(m.getContent().replace(e.getCode(),e.getMessage()));
// }
// });
// return new ResultData(page);
// }
//
// @ApiOperation("消息模板-添加")
// @PostMapping("add")
// @SystemControllerLog(description = "消息验证模板-添加")
// public ResultData add(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::add");
// //Assert.notNull(wxMsgValidationcodeModel.getName(), "角色名不能为空");
// //Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
// wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
// return wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
// }
//
// @ApiOperation("消息模板-更新")
// @PostMapping("update")
// @SystemControllerLog(description = "消息验证模板-更新")
// public ResultData update(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::update");
// wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
// return new ResultData();
// }

@ApiOperation("消息模板-打开/关闭发送")
@PostMapping("updateOpen")


+ 31
- 0
mallinkAdmin/src/main/resources/db/migration/V202301200001__contract.sql Просмотреть файл

@@ -34,6 +34,12 @@ ADD COLUMN `operating_management_fee_ratio_way` int(1) COMMENT '营业管理费
ALTER TABLE `mallink`.`wx_rent_contract`
ADD COLUMN `operating_management_fee_ratio` JSON COMMENT '营业管理费调整比率' ;

ALTER TABLE `mallink`.`wx_rent_contract`
ADD COLUMN `out_date_notify_days` INT(3) NOT NULL DEFAULT 0 COMMENT '到期提醒提前天数' ;

ALTER TABLE `mallink`.`wx_rent_contract`
ADD COLUMN `out_date_notify_phone` varchar(30) COMMENT '到期提醒手机号' ;


ALTER TABLE `mallink`.`wx_bill_rent`
ADD COLUMN `bussiness_manage_fee_need_pay` bigint(12) COMMENT '商业管理费应收' AFTER `need_pay`;
@@ -41,3 +47,28 @@ ADD COLUMN `bussiness_manage_fee_need_pay` bigint(12) COMMENT '商业管理费
ALTER TABLE `mallink`.`wx_bill_rent`
ADD COLUMN `operating_manage_fee_need_pay` bigint(12) COMMENT '营业管理费应收' AFTER `need_pay`;

#CREATE TABLE `wx_msg_validationcode_model_tenant` (
# `id` bigint(20) NOT NULL COMMENT '主键ID',
# `tenant_id` varchar(5) COLLATE utf8mb4_unicode_ci NOT NULL,
# `parent_tenant_id` varchar(5) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
# `model_id` bigint(20) NOT NULL COMMENT '关联的模板编号',
# `signature` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '签名',
# `model_code` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '模版code',
# `content` text COLLATE utf8mb4_unicode_ci COMMENT '如内容有修改,可设置',
# `sms_channel` int(1) NOT NULL COMMENT '发短信通道EnumSMSChannel',
# PRIMARY KEY (`id`),
# UNIQUE KEY `id_UNIQUE` (`id`),
# UNIQUE KEY `UNIQUE_T_T` (`tenant_id`,`model_id`)
#) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='短信模板';
//金茂的短信加入到这个表记录中

delete from wx_msg_validationcode_model where tenant_id != '789';
ALTER TABLE wx_msg_validationcode_model DROP COLUMN tenant_id;
ALTER TABLE wx_msg_validationcode_model DROP COLUMN parent_tenant_id;
ALTER TABLE wx_msg_validationcode_model DROP COLUMN model_id;

ALTER TABLE wx_msg_model DROP COLUMN model_id;





+ 42
- 3
mallinkSchedule/src/main/java/com/iformall/schedule/ContractSchedule.java Просмотреть файл

@@ -4,7 +4,13 @@ import com.iformall.domain.po.WxMall;
import com.iformall.domain.po.WxPropertyContract;
import com.iformall.domain.po.WxRentContract;
import com.iformall.domain.po.base.TenantEntity;
import com.iformall.domain.po.msg.WxMsgRecord;
import com.iformall.enums.EnumMsgMqKey;
import com.iformall.enums.EnumMsgMqTag;
import com.iformall.enums.EnumMsgMqTopic;
import com.iformall.enums.EnumMsgRecordType;
import com.iformall.mapper.WxMallMapper;
import com.iformall.mq.MqBaseProducer;
import com.iformall.service.WxPropertyContractService;
import com.iformall.service.WxRentContractService;
import lombok.extern.slf4j.Slf4j;
@@ -15,7 +21,9 @@ import org.springframework.scheduling.annotation.Async;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
* @author gongbiao
@@ -34,7 +42,8 @@ public class ContractSchedule {
@Autowired
private WxMallMapper wxMallMapper;


@Autowired
private MqBaseProducer mqBaseProducer;
/**
* 凌晨5分
*/
@@ -85,7 +94,7 @@ public class ContractSchedule {
}

/**
* 凌晨5分
* 凌晨5分,定时终止租金合同
*/
@Async
@Scheduled(cron = "0 5 0 * * ?")
@@ -107,7 +116,7 @@ public class ContractSchedule {
}
/**
* 凌晨5分
* 凌晨5分,定时终止物业合同
*/
@Async
@Scheduled(cron = "0 5 0 * * ?")
@@ -127,5 +136,35 @@ public class ContractSchedule {
}
}
}
/**
* 凌晨5分,定时过期提醒租金合同到期
*/
@Async
@Scheduled(cron = "0 5 0 * * ?")
public void notifyRentContractOutDate() {
List<WxMall> wxMalls = wxMallMapper.findList(null);
for (WxMall wxMall : wxMalls) {
//物业合同
List<WxRentContract> contractList = wxRentContractService.findToOutDateContracts(wxMall);
for (WxRentContract rent:contractList) {
try {
WxMsgRecord msgRecord = new WxMsgRecord();
msgRecord.setMsgType(EnumMsgRecordType.SMS.getCode());
msgRecord.updateTenantInfo(wxMall);
msgRecord.setReceiver(rent.getOutDateNotifyPhone());
msgRecord.setModelType(32);
Map<String,String> dynamicContentMap = new HashMap<String,String>();
dynamicContentMap.put("id", String.valueOf(rent.getId()));
dynamicContentMap.put("contractType", "租金");
dynamicContentMap.put("contract", String.valueOf(rent.getId()));
msgRecord.setDynamicContentMap(dynamicContentMap);
mqBaseProducer.sendMessage(msgRecord, EnumMsgMqTopic.DEFAULT.getCode(), EnumMsgMqTag.DEFAULT.getCode(), EnumMsgMqKey.DEFAULT.getCode());
}catch(Exception e) {
log.error("rentcontract outDate error.",e);
}
}
}
}

}

+ 1
- 5
mallinkService/src/main/java/com/iformall/domain/po/WxMsgModel.java Просмотреть файл

@@ -30,13 +30,9 @@ public class WxMsgModel extends TenantEntity {

@io.swagger.annotations.ApiModelProperty(value="reason",name="reason")
private String reason;

@io.swagger.annotations.ApiModelProperty(value="modelid",name="modelId")
private Integer modelId;

@io.swagger.annotations.ApiModelProperty(value="templateType",name="templateType")
private Integer templateType;
@io.swagger.annotations.ApiModelProperty(value="aliyun模板code",name="modelCode")
@io.swagger.annotations.ApiModelProperty(value="通道模板code",name="modelCode")
private String modelCode;

}


+ 3
- 5
mallinkService/src/main/java/com/iformall/domain/po/WxMsgValidationcodeModel.java Просмотреть файл

@@ -1,7 +1,7 @@
package com.iformall.domain.po;

import com.baomidou.mybatisplus.annotation.TableName;
import com.iformall.domain.po.base.TenantEntity;
import com.iformall.domain.po.base.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

@@ -10,7 +10,7 @@ import java.util.Date;
@TableName(value = "wx_msg_validationcode_model")
@Data
@EqualsAndHashCode(callSuper = true)
public class WxMsgValidationcodeModel extends TenantEntity {
public class WxMsgValidationcodeModel extends BaseEntity {

protected Long id;

@@ -26,9 +26,7 @@ public class WxMsgValidationcodeModel extends TenantEntity {
private Integer status;
@io.swagger.annotations.ApiModelProperty(value="有效分钟数",name="minutes")
private Integer minutes;
@io.swagger.annotations.ApiModelProperty(value="",name="modelId")
private Integer modelId;
@io.swagger.annotations.ApiModelProperty(value="阿里云模板code",name="modelCode")
@io.swagger.annotations.ApiModelProperty(value="通道模板code",name="modelCode")
private String modelCode;
@io.swagger.annotations.ApiModelProperty(value="场景",name="type")
private Integer type;


+ 30
- 0
mallinkService/src/main/java/com/iformall/domain/po/WxMsgValidationcodeModelTenant.java Просмотреть файл

@@ -0,0 +1,30 @@
package com.iformall.domain.po;

import com.baomidou.mybatisplus.annotation.TableName;
import com.iformall.domain.po.base.BaseEntity;
import com.iformall.domain.po.base.TenantEntity;

import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

@TableName(value = "wx_msg_validationcode_model_tenant")
@Data
@EqualsAndHashCode(callSuper = true)
public class WxMsgValidationcodeModelTenant extends TenantEntity {

protected Long id;

@io.swagger.annotations.ApiModelProperty(value="模板编号",name="modelId")
private Long modelId;
@io.swagger.annotations.ApiModelProperty(value="签名",name="signature")
private String signature;
@io.swagger.annotations.ApiModelProperty(value="如内容有修改,可设置",name="content")
private String content;
@io.swagger.annotations.ApiModelProperty(value="通道模板code",name="modelCode")
private String modelCode;
@io.swagger.annotations.ApiModelProperty(value="通道EnumSMSChannel",name="smsChannel")
private Integer smsChannel;
}


+ 9
- 0
mallinkService/src/main/java/com/iformall/domain/po/WxRentContract.java Просмотреть файл

@@ -420,6 +420,15 @@ public class WxRentContract extends TenantEntity {
@io.swagger.annotations.ApiModelProperty(value = "营业管理费调整方式1按比例2按金额", name = "operatingManagementFeeRatio")
private String operatingManagementFeeRatio;
@io.swagger.annotations.ApiModelProperty(value = "到期提醒提前天数", name = "outDateNotifyDays")
private Integer outDateNotifyDays;
@io.swagger.annotations.ApiModelProperty(value = "到期提醒手机号", name = "outDateNotifyPhone")
private String outDateNotifyPhone;
//查询过期提醒
@TableField(exist = false)
private Integer outDateNofity;

public void setAdjustPeriodHandle() {
if(EnumPriceUnit.D.getCode().equals(this.getPriceUnit()) && EnumRentContractAdjustPeriod.ADJUST_PERIOD_MONTH.getCode().equals(adjustPeriod)){


+ 0
- 3
mallinkService/src/main/java/com/iformall/mapper/WxMsgModelMapper.java Просмотреть файл

@@ -11,9 +11,6 @@ public interface WxMsgModelMapper extends CommonMapper<WxMsgModel, String> {
List<WxMsgModel> findAliYunList(WxMsgModel msgModel);


WxMsgModel findOneByModelId(WxMsgModel wxMsgModel);


int updateByCode(WxMsgModel wxMsgModel);




+ 15
- 0
mallinkService/src/main/java/com/iformall/mapper/WxMsgValidationcodeModelTenantMapper.java Просмотреть файл

@@ -0,0 +1,15 @@
package com.iformall.mapper;

import java.util.*;
import com.iformall.common.CommonMapper;
import com.iformall.domain.po.WxMsgValidationcodeModel;
import com.iformall.domain.po.WxMsgValidationcodeModelTenant;

import org.apache.ibatis.annotations.Param;

public interface WxMsgValidationcodeModelTenantMapper extends CommonMapper<WxMsgValidationcodeModelTenant, String> {
WxMsgValidationcodeModelTenant findByModelId(WxMsgValidationcodeModelTenant wxMsgValidationcodeModelTenant);
List<WxMsgValidationcodeModelTenant> findList(WxMsgValidationcodeModelTenant wxMsgValidationcodeModelTenant);
}

+ 3
- 0
mallinkService/src/main/java/com/iformall/service/WxRentContractService.java Просмотреть файл

@@ -110,6 +110,9 @@ public interface WxRentContractService {
*/
void outDateContract(WxMall wxMall);
//查询还有多少天到期的合同
List<WxRentContract> findToOutDateContracts(TenantEntity tenantEntity);
/**
* 已签约未计租 变为计租中
* @param wxMall


+ 16
- 16
mallinkService/src/main/java/com/iformall/service/impl/WxMsgCallbackServiceImpl.java Просмотреть файл

@@ -135,7 +135,7 @@ public class WxMsgCallbackServiceImpl implements WxMsgCallbackService {
if (checksign(tenantId, param)) {
logger.info("短信营销模板回调SIGN校验成功");
WxMsgModel wxMsgModel = new WxMsgModel();
wxMsgModel.setModelId(Integer.valueOf(param.get("id")));
//wxMsgModel.setModelId(Integer.valueOf(param.get("id")));
wxMsgModel.setTenantId(tenantId);
wxMsgModel = wxMsgModelMapper.findList(wxMsgModel).get(0);
wxMsgModel.setStatus(param.get("status").equals("1")?Integer.valueOf(param.get("status")):0);
@@ -149,17 +149,17 @@ public class WxMsgCallbackServiceImpl implements WxMsgCallbackService {
@Override
public void receiveverifymodel(String tenantId, Map<String, String> param) {

if(checksign(tenantId,param)) {
logger.info("短信模板回调SIGN校验成功");
WxMsgValidationcodeModel wxMsgModel = new WxMsgValidationcodeModel();
wxMsgModel.setModelId(Integer.valueOf(param.get("id")));
wxMsgModel.setTenantId(tenantId);
wxMsgModel = wxMsgValidationcodeModelMapper.findList(wxMsgModel).get(0);
wxMsgModel.setStatus(param.get("status").equals("1")?Integer.valueOf(param.get("status")):0);
wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
}else{
logger.info("短信模板回调SIGN校验失败");
}
// if(checksign(tenantId,param)) {
// logger.info("短信模板回调SIGN校验成功");
// WxMsgValidationcodeModel wxMsgModel = new WxMsgValidationcodeModel();
// wxMsgModel.setModelId(Integer.valueOf(param.get("id")));
// wxMsgModel.setTenantId(tenantId);
// wxMsgModel = wxMsgValidationcodeModelMapper.findList(wxMsgModel).get(0);
// wxMsgModel.setStatus(param.get("status").equals("1")?Integer.valueOf(param.get("status")):0);
// wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
// }else{
// logger.info("短信模板回调SIGN校验失败");
// }



@@ -190,10 +190,10 @@ public class WxMsgCallbackServiceImpl implements WxMsgCallbackService {
wxMsgModel.setReason(reason);
wxMsgModelMapper.updateByCode(wxMsgModel);

WxMsgValidationcodeModel wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.setModelCode(wxMsgModel.getModelCode());
wxMsgValidationcodeModel.setStatus(wxMsgModel.getStatus());
wxMsgValidationcodeModelMapper.updateByCode(wxMsgValidationcodeModel);
// WxMsgValidationcodeModel wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
// wxMsgValidationcodeModel.setModelCode(wxMsgModel.getModelCode());
// wxMsgValidationcodeModel.setStatus(wxMsgModel.getStatus());
// wxMsgValidationcodeModelMapper.updateByCode(wxMsgValidationcodeModel);

}



+ 8
- 8
mallinkService/src/main/java/com/iformall/service/impl/WxMsgModelServiceImpl.java Просмотреть файл

@@ -82,10 +82,10 @@ public class WxMsgModelServiceImpl implements WxMsgModelService {
if (wxMsgModel.getId() == null) {
final IdWorker idWorker = IdWorker.get();
wxMsgModel.setId(idWorker.nextId());
if(jsonObjectResult.get("data") != null){
String data = jsonObjectResult.get("data").toString();
wxMsgModel.setModelId(Integer.valueOf(data));
}
// if(jsonObjectResult.get("data") != null){
// String data = jsonObjectResult.get("data").toString();
// wxMsgModel.setModelId(Integer.valueOf(data));
// }
if(jsonObjectResult.get("aliyunModelCode") != null){
wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
}
@@ -93,10 +93,10 @@ public class WxMsgModelServiceImpl implements WxMsgModelService {
wxMsgModel.setStatus(EnumMsgModelStatus.AUDITING.getCode());//审核中
wxMsgModelMapper.insert(wxMsgModel);
} else {
if(jsonObjectResult.get("data") != null){
String data = jsonObjectResult.get("data").toString();
wxMsgModel.setModelId(Integer.valueOf(data));
}
// if(jsonObjectResult.get("data") != null){
// String data = jsonObjectResult.get("data").toString();
// wxMsgModel.setModelId(Integer.valueOf(data));
// }
if(jsonObjectResult.get("aliyunModelCode") != null){
wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
}


+ 135
- 135
mallinkService/src/main/java/com/iformall/service/impl/WxMsgValidationcodeModelServiceImpl.java Просмотреть файл

@@ -41,59 +41,59 @@ public class WxMsgValidationcodeModelServiceImpl implements WxMsgValidationcodeM
@Override
@Transactional(rollbackFor = {Exception.class})
public void wxMsgValidationcodeModelInit(String tenantId, String signature, String emailBgImg) {
DateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String nowTimestr = format.format(new Date());
final IdWorker idWorker = IdWorker.get();
String initSql = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `msg_type`, `model_code`) values " +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '2', '代办通知', '富茂', '{userName}提交了一个{bustype}待您审批,电脑登陆管理后台查看您的待办。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900032')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '3', '审批通知', '富茂', '{userName}同意编号{contract}的{bustype}审批,已呈送至{toUserName},登录{page}查看审批进度。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '4', '通过审批通知', '富茂', '编号{contract}的合同已通过审批,请登录{page} 跟进后续工作。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '5', '驳回通知', '富茂', '编号{contract}的合同审批被驳回,请登录{page} 查看审批明细。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '6', '验证码', '富茂', '{s6}(动态验证码),请在5分钟内填写', '" + nowTimestr + "', '1', '5', null, '1', 'SMS_194910023')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '7', '账单待缴模板', '富茂', '您当期的待缴账单为{price}元,截止日期为{date} ,请登录{app}小程序查看账单并交费。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900024')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '8', '账单欠缴模板', '富茂', '截止今日您的账单共计欠缴{price}元,请登录{app}小程序查看账单并交费。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194910026')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '9', '场景投放', '富茂', '亲爱的vip,悄悄地送您一张{title},请到{app}微信小程序中使用吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920015')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '11', '商户分账账户新增通知商户', '富茂', '您于{time}提交了{merchant}商户的收款账户[{account}]绑定,后续销售分成及营销补贴将存入该账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '13', '商户分账账户变更通知商户', '富茂', '您于{time}将{merchant}商户的收款账户变更为[{account}],后续销售分成及营销补贴将存入该账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '14', '商户分账账户不使用回执', '富茂', '商管已同意[{account}]作为{merchant}商户的收款账户。后续的销售分成及营销补贴将存入此账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '15', '商户分账账户使用回执', '富茂', '商管拒绝将[{account}]作为{merchant}商户的收款账户。如有疑问请联系商管', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '16', '商户分账账户删除提醒', '富茂', '{merchant}商户的收款账户[{account}]于{time}取消绑定,营销活动与销售分成将无法正常进行,请尽快绑定新收款账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '17', '限时活动报名成功', '富茂', '亲爱的{person},您已成功报名{party},盼望您于{time}到场参加活动,谢谢。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900027')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '18', '限时活动参加提醒', '富茂', '亲爱的{person},{party}活动将在{time}准时开始,感谢您能够抽出宝贵时间准时到活动现场参与,谢谢。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920016')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '28', '会员生日券开启', '富茂', '亲爱的{userName},在您的生日到来之际,我们精心的为您准备了一份生日礼物,并在生日当天消费领取{creditScale}倍积分,赶快打开{mallName}微信小程序领取您的专属生日礼物吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194915025')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '29', '会员生日券未开启', '富茂', '亲爱的{userName},在您的生日到来之际,我们精心的为您准备了一份生日礼物,赶快打开{mallName}微信小程序领取您的专属生日礼物吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900031')," +
" ( '" + idWorker.nextId() + "', '" + tenantId + "', '30', '系统发卡', '富茂', '亲爱的,您收到一张【{title}】,兑换码:{pw}。请于30天内打开微信小程序:{app}兑换!进店详询。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920021');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql);
String initSql1 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
"values ( '" + idWorker.nextId() + "', '" + tenantId + "', '10', '审批通过通知', '富茂', " +
" '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \\'px\\';</script>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\\\" src=\\\"https://formall.oss-accelerate.aliyuncs.com/cimg/changrong-logo.png\\\"/>\\n </header>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\\\">审批通过通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\\\">编号<span>{contract}</span>的{bustype}已经审批通过,请登录<a href=\\\"{page}\\\">{page}</a>跟进后续工作</div>\\n </div>\\n </div>\\n</body>\\n\\n</html>', " +
" '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql1);
String initSql2 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
"values ( '" + idWorker.nextId() + "', '" + tenantId + "', '11', '待缴账单通知', '富茂', " +
" '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background: #fff;padding-bottom: 40px;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding-top: 56px;padding-left: 55px;\\\">待缴账单通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 0;\\\">您当前的待缴账单为<span style=\\\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\\\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">租金账单</span>\\n <div style=\\\"margin: 0 5%;width:90%;overflow: hidden;\\\">\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单类型</div>\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单金额(元)</div>\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">缴费时间</div>\\n </div>\\n {billList}\\n </div>\\n </div>\\n <div style=\\\"background: #fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系商管负责人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
" '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql2);
String initSql3 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
"values ( '" + idWorker.nextId() + "', '" + tenantId + "', '12', '审批通知', '富茂', " +
"'<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \\'px\\';</script>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\\\">审批通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\\\"><span>{userName}</span>同意编号<span>{contract}</span>的{bustype}审批,已呈送<span>{toUserName},</span>请登录<a href=\\\"{page}\\\">{page}</a>查看审批进度</div>\\n </div>\\n </div>\\n</body>\\n\\n</html>', " +
"'" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql3);
String initSql4 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
"values ( '" + idWorker.nextId() + "', '" + tenantId + "', '13', '欠缴账单通知', '富茂', " +
" '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background: #fff;padding-bottom: 40px;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">欠缴账单通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 0;\\\">您当前的欠缴账单为<span style=\\\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\\\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">租金账单</span>\\n <div style=\\\"margin: 0 5%;width:90%;overflow: hidden;font-size:14px;\\\">\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单类型</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单金额(元)</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">缴费时间</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">逾期天数</div>\\n </div>\\n {billList}\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系商管负责人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
"'" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql4);
String initSql5 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
" values ( '" + idWorker.nextId() + "', '" + tenantId + "', '14', '待办通知', '富茂'," +
" '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">待办通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 40px;\\\"><span>{name}</span><span>提交了一个{bustype}待您审批,电脑登录</span><a href=\\\"{page}\\\" target=\\\"_blank\\\">{page}</a>查看您的待办</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <div style=\\\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">申请时间:</div>\\n <div style=\\\"float: left;font-size:18px;width:cale(80%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{applyTime}</div>\\n </div>\\n <div style=\\\"overflow: hidden;\\\">\\n <div style=\\\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">申请进度:</div>\\n <div style=\\\"float: left;width:cale(80%-55px);margin-left: 55px;\\\">\\n \\n {taskList}\\n </div>\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;padding: 56px 55px 0;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系申请人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
" '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql5);
String initSql6 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
" values ( '" + idWorker.nextId() + "', '" + tenantId + "', '15', '驳回通知', '富茂', " +
" '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">审批通过通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 40px;\\\">编号<span>{contract}</span>的{bustype}审批被驳回,请登录<a href=\\\"{page}\\\">{page}</a>查看审批明细</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">驳回人:</span>\\n <span style=\\\"display: block;float: left; width:calc(100% - 240px);font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{name}</span>\\n </div>\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">驳回原因:</span>\\n <span style=\\\"display: block;float: left;width:calc(100% - 240px); font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{remark}</span>\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;margin-top: 26px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系驳回人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
" '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql6);
// DateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
// String nowTimestr = format.format(new Date());
// final IdWorker idWorker = IdWorker.get();
// String initSql = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `msg_type`, `model_code`) values " +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '2', '代办通知', '富茂', '{userName}提交了一个{bustype}待您审批,电脑登陆管理后台查看您的待办。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900032')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '3', '审批通知', '富茂', '{userName}同意编号{contract}的{bustype}审批,已呈送至{toUserName},登录{page}查看审批进度。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '4', '通过审批通知', '富茂', '编号{contract}的合同已通过审批,请登录{page} 跟进后续工作。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '5', '驳回通知', '富茂', '编号{contract}的合同审批被驳回,请登录{page} 查看审批明细。', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '6', '验证码', '富茂', '{s6}(动态验证码),请在5分钟内填写', '" + nowTimestr + "', '1', '5', null, '1', 'SMS_194910023')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '7', '账单待缴模板', '富茂', '您当期的待缴账单为{price}元,截止日期为{date} ,请登录{app}小程序查看账单并交费。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900024')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '8', '账单欠缴模板', '富茂', '截止今日您的账单共计欠缴{price}元,请登录{app}小程序查看账单并交费。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194910026')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '9', '场景投放', '富茂', '亲爱的vip,悄悄地送您一张{title},请到{app}微信小程序中使用吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920015')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '11', '商户分账账户新增通知商户', '富茂', '您于{time}提交了{merchant}商户的收款账户[{account}]绑定,后续销售分成及营销补贴将存入该账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '13', '商户分账账户变更通知商户', '富茂', '您于{time}将{merchant}商户的收款账户变更为[{account}],后续销售分成及营销补贴将存入该账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '14', '商户分账账户不使用回执', '富茂', '商管已同意[{account}]作为{merchant}商户的收款账户。后续的销售分成及营销补贴将存入此账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '15', '商户分账账户使用回执', '富茂', '商管拒绝将[{account}]作为{merchant}商户的收款账户。如有疑问请联系商管', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '16', '商户分账账户删除提醒', '富茂', '{merchant}商户的收款账户[{account}]于{time}取消绑定,营销活动与销售分成将无法正常进行,请尽快绑定新收款账户', '" + nowTimestr + "', '1', '0', null, '1', null)," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '17', '限时活动报名成功', '富茂', '亲爱的{person},您已成功报名{party},盼望您于{time}到场参加活动,谢谢。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900027')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '18', '限时活动参加提醒', '富茂', '亲爱的{person},{party}活动将在{time}准时开始,感谢您能够抽出宝贵时间准时到活动现场参与,谢谢。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920016')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '28', '会员生日券开启', '富茂', '亲爱的{userName},在您的生日到来之际,我们精心的为您准备了一份生日礼物,并在生日当天消费领取{creditScale}倍积分,赶快打开{mallName}微信小程序领取您的专属生日礼物吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194915025')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '29', '会员生日券未开启', '富茂', '亲爱的{userName},在您的生日到来之际,我们精心的为您准备了一份生日礼物,赶快打开{mallName}微信小程序领取您的专属生日礼物吧!', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194900031')," +
// " ( '" + idWorker.nextId() + "', '" + tenantId + "', '30', '系统发卡', '富茂', '亲爱的,您收到一张【{title}】,兑换码:{pw}。请于30天内打开微信小程序:{app}兑换!进店详询。', '" + nowTimestr + "', '1', '0', null, '1', 'SMS_194920021');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql);
// String initSql1 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// "values ( '" + idWorker.nextId() + "', '" + tenantId + "', '10', '审批通过通知', '富茂', " +
// " '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \\'px\\';</script>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\\\" src=\\\"https://formall.oss-accelerate.aliyuncs.com/cimg/changrong-logo.png\\\"/>\\n </header>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\\\">审批通过通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\\\">编号<span>{contract}</span>的{bustype}已经审批通过,请登录<a href=\\\"{page}\\\">{page}</a>跟进后续工作</div>\\n </div>\\n </div>\\n</body>\\n\\n</html>', " +
// " '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql1);
// String initSql2 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// "values ( '" + idWorker.nextId() + "', '" + tenantId + "', '11', '待缴账单通知', '富茂', " +
// " '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background: #fff;padding-bottom: 40px;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding-top: 56px;padding-left: 55px;\\\">待缴账单通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 0;\\\">您当前的待缴账单为<span style=\\\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\\\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">租金账单</span>\\n <div style=\\\"margin: 0 5%;width:90%;overflow: hidden;\\\">\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单类型</div>\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单金额(元)</div>\\n <div style=\\\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">缴费时间</div>\\n </div>\\n {billList}\\n </div>\\n </div>\\n <div style=\\\"background: #fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系商管负责人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
// " '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql2);
// String initSql3 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// "values ( '" + idWorker.nextId() + "', '" + tenantId + "', '12', '审批通知', '富茂', " +
// "'<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \\'px\\';</script>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\\\">审批通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\\\"><span>{userName}</span>同意编号<span>{contract}</span>的{bustype}审批,已呈送<span>{toUserName},</span>请登录<a href=\\\"{page}\\\">{page}</a>查看审批进度</div>\\n </div>\\n </div>\\n</body>\\n\\n</html>', " +
// "'" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql3);
// String initSql4 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// "values ( '" + idWorker.nextId() + "', '" + tenantId + "', '13', '欠缴账单通知', '富茂', " +
// " '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background: #fff;padding-bottom: 40px;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">欠缴账单通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 0;\\\">您当前的欠缴账单为<span style=\\\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\\\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">租金账单</span>\\n <div style=\\\"margin: 0 5%;width:90%;overflow: hidden;font-size:14px;\\\">\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单类型</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">账单金额(元)</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">缴费时间</div>\\n <div style=\\\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\\\">逾期天数</div>\\n </div>\\n {billList}\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系商管负责人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
// "'" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql4);
// String initSql5 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// " values ( '" + idWorker.nextId() + "', '" + tenantId + "', '14', '待办通知', '富茂'," +
// " '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">待办通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 40px;\\\"><span>{name}</span><span>提交了一个{bustype}待您审批,电脑登录</span><a href=\\\"{page}\\\" target=\\\"_blank\\\">{page}</a>查看您的待办</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <div style=\\\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">申请时间:</div>\\n <div style=\\\"float: left;font-size:18px;width:cale(80%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{applyTime}</div>\\n </div>\\n <div style=\\\"overflow: hidden;\\\">\\n <div style=\\\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">申请进度:</div>\\n <div style=\\\"float: left;width:cale(80%-55px);margin-left: 55px;\\\">\\n \\n {taskList}\\n </div>\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;padding: 56px 55px 0;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系申请人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
// " '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql5);
// String initSql6 = "insert into `mallink`.`wx_msg_validationcode_model` ( `id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`, `msg_type`)" +
// " values ( '" + idWorker.nextId() + "', '" + tenantId + "', '15', '驳回通知', '富茂', " +
// " '<!DOCTYPE html>\\n<html>\\n\\n<head>\\n <meta charset=\\\"utf-8\\\">\\n <meta name=\\\"viewport\\\" content=\\\"width=device-width,initial-scale=1.0\\\">\\n <meta http-equiv=\\\"Content-Type\\\" content=\\\"text/html; charset=utf-8\\\" />\\n <meta name=\\\"viewport\\\" content=\\\"initial-scale=1.0, user-scalable=no\\\" />\\n <meta name=\\\"renderer\\\" content=\\\"webkit\\\">\\n <meta http-equiv=\\\"X-UA-Compatible\\\" content=\\\"IE=edge,chrome=1\\\">\\n <title>富茂审批邮件</title>\\n <title></title>\\n <style>\\n *{\\n margin: 0;\\n padding: 0;\\n }\\n </style>\\n</head>\\n\\n<body>\\n <div id=\\\"box\\\" style=\\\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\\\">\\n <header style=\\\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\\\">\\n <img style=\\\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\\\" src=\\\"{bg}\\\"/>\\n </header>\\n <content>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\\\">审批通过通知</div>\\n <div style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 40px;\\\">编号<span>{contract}</span>的{bustype}审批被驳回,请登录<a href=\\\"{page}\\\">{page}</a>查看审批明细</div>\\n </div>\\n <div style=\\\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\\\">\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">驳回人:</span>\\n <span style=\\\"display: block;float: left; width:calc(100% - 240px);font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{name}</span>\\n </div>\\n <div style=\\\"overflow: hidden;\\\">\\n <span style=\\\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">驳回原因:</span>\\n <span style=\\\"display: block;float: left;width:calc(100% - 240px); font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\\\">{remark}</span>\\n </div>\\n </div>\\n <div style=\\\"background:#fff;\\\">\\n <div style=\\\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;margin-top: 26px;\\\">遇到问题?</div>\\n <div style=\\\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\\\">\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\\\">请联系驳回人:</span>\\n <span style=\\\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\\\"><span>{linkName}</span><span style=\\\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\\\">{linkPhone}</span></span>\\n </div>\\n </div>\\n </content>\\n </div>\\n</body>\\n\\n</html>'," +
// " '" + nowTimestr + "', '1', null, '500', '" + emailBgImg + "', '2');";
// wxMsgValidationcodeModelMapper.wxMsgValidationcodeModelInit(initSql6);
}

@Override
@@ -113,88 +113,88 @@ public class WxMsgValidationcodeModelServiceImpl implements WxMsgValidationcodeM

@Override
public ResultData saveOrUpdate(WxMsgValidationcodeModel wxMsgModel) {
//从短信配置中查询密钥 bid 等信息
WxMsgConfig wxMsgConfig = new WxMsgConfig();
wxMsgConfig.setTenantId(wxMsgModel.getTenantId());
List<WxMsgConfig> wxMsgConfigs = wxMsgConfigMapper.findList(wxMsgConfig);
if(wxMsgConfigs.size()==0)return new ResultData(Result.SUCCESS, "您还未接入短信运营商,请联系平台管理员");
wxMsgConfig = wxMsgConfigs.get(0);
String secret = wxMsgConfig.getSecret();
String bid = wxMsgConfig.getBid();
String signature = wxMsgModel.getSignature();
String content = wxMsgModel.getContent();
//查看用户最新数据是否存在
List<WxMsgValidationcodeModel> wxMsgModels = wxMsgValidationcodeModelMapper.findList(wxMsgModel);
if (wxMsgModel.getId() == null && wxMsgModels.size() == 1) {
return new ResultData(ErrorCode.MSG_TEMPLATE_REPEAT.getCode(), "您添加的短信模板已存在");
}
if (wxMsgModel.getId() != null && wxMsgModels.size() == 1) {
//ID相同 内容相同 不发送短信 不做修改
WxMsgValidationcodeModel wxmsgmodel = wxMsgModels.get(0);
if(wxmsgmodel.getContent().equals(wxMsgModel.getContent()) && wxmsgmodel.getSignature().equals(wxMsgModel.getSignature())) {
return new ResultData(Result.SUCCESS, "修改成功");
}
}
String result = SMSFactory.addTemplate(wxMsgConfig, signature, content,EnumVerifyCode.YES.getCode().toString(),
wxMsgModel.getName(),1,wxMsgModel.getName());
JSONObject jsonObjectResult = JSONObject.parseObject(result);
String ret = jsonObjectResult.get("ret").toString();
if (ret.equals(EnumMsgModelStatus.SUCCESS.getCode().toString())) {
if (wxMsgModel.getId() == null) {
final IdWorker idWorker = IdWorker.get();
wxMsgModel.setId(idWorker.nextId());
if(jsonObjectResult.get("data") != null){
String data = jsonObjectResult.get("data").toString();
wxMsgModel.setModelId(Integer.valueOf(data));
}
if(jsonObjectResult.get("aliyunModelCode") != null){
wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
}
wxMsgModel.setCreatetime(new Date());
wxMsgModel.setStatus(2);//审核中
wxMsgValidationcodeModelMapper.insert(wxMsgModel);
} else {
if(jsonObjectResult.get("data") != null){
String data = jsonObjectResult.get("data").toString();
wxMsgModel.setModelId(Integer.valueOf(data));
}
if(jsonObjectResult.get("aliyunModelCode") != null){
wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
}
wxMsgModel.setStatus(2);//审核中
wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
}
return new ResultData(Result.SUCCESS, "创建模板成功");
} else if (ret.equals(EnumMsgModelStatus.REPEAT.getCode().toString())) {
if (wxMsgModel.getId() == null) {
final IdWorker idWorker = IdWorker.get();
wxMsgModel.setId(idWorker.nextId());
wxMsgModel.setCreatetime(new Date());
wxMsgModel.setStatus(1);
wxMsgValidationcodeModelMapper.insert(wxMsgModel);
} else {
wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
}
} else if (ret.equals(EnumMsgModelStatus.SINATURE_CONTENT_ERROR.getCode().toString())) {
return new ResultData(ErrorCode.MSG_SIGNATURE_CONTENT_ERROR.getCode(), "短信签名或内容错误");
} else if (ret.equals(EnumMsgModelStatus.NOT_FOUND.getCode().toString())) {
return new ResultData(ErrorCode.MSG_TEMPLATE_NOT_FOUND.getCode(), "短信模板不存在");
} else if (ret.equals(EnumMsgModelStatus.PARAMETERS_ERROR.getCode().toString())) {
return new ResultData(ErrorCode.MSG_REQUEST_PARAMS_ERROR.getCode(), "参数错误");
} else if (ret.equals(EnumMsgModelStatus.MSG_SEND_FAIL.getCode().toString())) {
return new ResultData(ErrorCode.MSG_SEND_ERROR.getCode(), "发送短信失败");
} else if (ret.equals(EnumMsgModelStatus.INTERFACE_ERROR.getCode().toString())) {
return new ResultData(ErrorCode.MSG_METHOD_REQUEST_ERROR.getCode(), "接口请求错误");
}
return new ResultData(ErrorCode.MSG_TEMPLATE_CREATE_ERROR.getCode(), "创建模板失败");
//
//
// //从短信配置中查询密钥 bid 等信息
// WxMsgConfig wxMsgConfig = new WxMsgConfig();
// wxMsgConfig.setTenantId(wxMsgModel.getTenantId());
// List<WxMsgConfig> wxMsgConfigs = wxMsgConfigMapper.findList(wxMsgConfig);
// if(wxMsgConfigs.size()==0)return new ResultData(Result.SUCCESS, "您还未接入短信运营商,请联系平台管理员");
// wxMsgConfig = wxMsgConfigs.get(0);
//
// String secret = wxMsgConfig.getSecret();
// String bid = wxMsgConfig.getBid();
//
// String signature = wxMsgModel.getSignature();
// String content = wxMsgModel.getContent();
// //查看用户最新数据是否存在
// List<WxMsgValidationcodeModel> wxMsgModels = wxMsgValidationcodeModelMapper.findList(wxMsgModel);
// if (wxMsgModel.getId() == null && wxMsgModels.size() == 1) {
// return new ResultData(ErrorCode.MSG_TEMPLATE_REPEAT.getCode(), "您添加的短信模板已存在");
// }
//
// if (wxMsgModel.getId() != null && wxMsgModels.size() == 1) {
// //ID相同 内容相同 不发送短信 不做修改
// WxMsgValidationcodeModel wxmsgmodel = wxMsgModels.get(0);
// if(wxmsgmodel.getContent().equals(wxMsgModel.getContent()) && wxmsgmodel.getSignature().equals(wxMsgModel.getSignature())) {
// return new ResultData(Result.SUCCESS, "修改成功");
// }
// }
//
// String result = SMSFactory.addTemplate(wxMsgConfig, signature, content,EnumVerifyCode.YES.getCode().toString(),
// wxMsgModel.getName(),1,wxMsgModel.getName());
//
// JSONObject jsonObjectResult = JSONObject.parseObject(result);
// String ret = jsonObjectResult.get("ret").toString();
// if (ret.equals(EnumMsgModelStatus.SUCCESS.getCode().toString())) {
// if (wxMsgModel.getId() == null) {
// final IdWorker idWorker = IdWorker.get();
// wxMsgModel.setId(idWorker.nextId());
// if(jsonObjectResult.get("data") != null){
// String data = jsonObjectResult.get("data").toString();
// wxMsgModel.setModelId(Integer.valueOf(data));
// }
// if(jsonObjectResult.get("aliyunModelCode") != null){
// wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
// }
// wxMsgModel.setCreatetime(new Date());
// wxMsgModel.setStatus(2);//审核中
// wxMsgValidationcodeModelMapper.insert(wxMsgModel);
// } else {
// if(jsonObjectResult.get("data") != null){
// String data = jsonObjectResult.get("data").toString();
// wxMsgModel.setModelId(Integer.valueOf(data));
// }
// if(jsonObjectResult.get("aliyunModelCode") != null){
// wxMsgModel.setModelCode(jsonObjectResult.get("aliyunModelCode").toString());
// }
// wxMsgModel.setStatus(2);//审核中
// wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
// }
// return new ResultData(Result.SUCCESS, "创建模板成功");
// } else if (ret.equals(EnumMsgModelStatus.REPEAT.getCode().toString())) {
// if (wxMsgModel.getId() == null) {
// final IdWorker idWorker = IdWorker.get();
// wxMsgModel.setId(idWorker.nextId());
// wxMsgModel.setCreatetime(new Date());
// wxMsgModel.setStatus(1);
// wxMsgValidationcodeModelMapper.insert(wxMsgModel);
// } else {
// wxMsgValidationcodeModelMapper.updateById(wxMsgModel);
// }
// } else if (ret.equals(EnumMsgModelStatus.SINATURE_CONTENT_ERROR.getCode().toString())) {
// return new ResultData(ErrorCode.MSG_SIGNATURE_CONTENT_ERROR.getCode(), "短信签名或内容错误");
// } else if (ret.equals(EnumMsgModelStatus.NOT_FOUND.getCode().toString())) {
// return new ResultData(ErrorCode.MSG_TEMPLATE_NOT_FOUND.getCode(), "短信模板不存在");
// } else if (ret.equals(EnumMsgModelStatus.PARAMETERS_ERROR.getCode().toString())) {
// return new ResultData(ErrorCode.MSG_REQUEST_PARAMS_ERROR.getCode(), "参数错误");
// } else if (ret.equals(EnumMsgModelStatus.MSG_SEND_FAIL.getCode().toString())) {
// return new ResultData(ErrorCode.MSG_SEND_ERROR.getCode(), "发送短信失败");
// } else if (ret.equals(EnumMsgModelStatus.INTERFACE_ERROR.getCode().toString())) {
// return new ResultData(ErrorCode.MSG_METHOD_REQUEST_ERROR.getCode(), "接口请求错误");
// }
// return new ResultData(ErrorCode.MSG_TEMPLATE_CREATE_ERROR.getCode(), "创建模板失败");
return null;
}

@Override


+ 8
- 0
mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java Просмотреть файл

@@ -3046,4 +3046,12 @@ public class WxRentContractServiceImpl implements WxRentContractService {
return wxRentContractMapper.findToEndContractList(record);
}

@Override
public List<WxRentContract> findToOutDateContracts(TenantEntity tenantEntity) {
WxRentContract wrc = new WxRentContract();
wrc.setStatus(EnumRentContractStatus.PAING.getCode());
wrc.setOutDateNofity(1);
return wxRentContractMapper.findList(wrc);
}

}

+ 1
- 6
mallinkService/src/main/java/com/iformall/service/msg/impl/SendCallBackSmsServiceImpl.java Просмотреть файл

@@ -80,10 +80,6 @@ public class SendCallBackSmsServiceImpl implements MsgSendService {
String signature = record.getSignature();
String msg = record.getMsg();
WxMsgModel wxMsgModel = wxMsgModelMapper.selectById(record.getModelId());
Integer modelId = null;
if (wxMsgModel != null) {
modelId = wxMsgModel.getModelId();
}
/*
// 检查是否超限
WxMsgLimit msgLimit = new WxMsgLimit();
@@ -101,8 +97,7 @@ public class SendCallBackSmsServiceImpl implements MsgSendService {
}catch(Exception e){}

String result = SMSFactory.sendSms(wxMsgConfig, phone, signature, msg,
EnumVerifyCode.NO.getCode().toString(), modelId,
null,wxMsgModel.getModelCode(),outId);
EnumVerifyCode.NO.getCode().toString(),null,wxMsgModel.getModelCode(),outId);

JSONObject jsonObjectResult = JSONObject.parseObject(result);
String ret = jsonObjectResult.get("ret").toString();


+ 1
- 2
mallinkService/src/main/java/com/iformall/service/msg/impl/SendEmailServiceImpl.java Просмотреть файл

@@ -50,9 +50,8 @@ public class SendEmailServiceImpl implements MsgSendService {
//根据模板替换动态内容
if(mailMsg.getModelId() != null){
WxMsgValidationcodeModel msgModel = new WxMsgValidationcodeModel();
msgModel.updateTenantInfo(tenantEntity);
msgModel.setType(mailMsg.getModelType());
msgModel.setModelId(mailMsg.getModelId());
msgModel.setModelCode(String.valueOf(mailMsg.getModelId()));
msgModel.setOpen(EnumMsgOpen.OPEN.getCode());
List<WxMsgValidationcodeModel> modelList = wxMsgValidationcodeModelMapper.findList(msgModel);
if(CollectionUtils.isEmpty(modelList)){


+ 40
- 18
mallinkService/src/main/java/com/iformall/service/msg/impl/SendSmsServiceImpl.java Просмотреть файл

@@ -3,6 +3,7 @@ package com.iformall.service.msg.impl;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils;
import com.iformall.common.ErrorCode;
import com.iformall.common.IdWorker;
import com.iformall.domain.po.*;
@@ -15,6 +16,7 @@ import com.iformall.exception.MallinkException;
import com.iformall.mapper.WxMsgConfigMapper;
import com.iformall.mapper.WxMsgValidationcodeMapper;
import com.iformall.mapper.WxMsgValidationcodeModelMapper;
import com.iformall.mapper.WxMsgValidationcodeModelTenantMapper;
import com.iformall.service.msg.MsgSendService;
import com.iformall.service.WxMsgValidationcodeService;
import com.iformall.sms.SMSFactory;
@@ -43,6 +45,8 @@ public class SendSmsServiceImpl implements MsgSendService {
private WxMsgValidationcodeMapper wxMsgValidationcodeMapper;
@Autowired
private WxMsgValidationcodeService wxMsgValidationcodeService;
@Autowired
private WxMsgValidationcodeModelTenantMapper wxMsgValidationcodeModelTenantMapper;

@Override
public void send(BaseMsg baseMsg) throws Exception{
@@ -56,7 +60,6 @@ public class SendSmsServiceImpl implements MsgSendService {
wxMsgValidationcode.setType(record.getModelType());

WxMsgValidationcodeModel wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.updateTenantInfo(wxMsgValidationcode);
wxMsgValidationcodeModel.setType(record.getModelType());
wxMsgValidationcodeModel.setOpen(EnumMsgOpen.OPEN.getCode());
List<WxMsgValidationcodeModel> modelList = wxMsgValidationcodeModelMapper.findList(wxMsgValidationcodeModel);
@@ -66,18 +69,6 @@ public class SendSmsServiceImpl implements MsgSendService {

wxMsgValidationcodeModel = wxMsgValidationcodeModelMapper.findList(wxMsgValidationcodeModel).get(0);

wxMsgValidationcode.setSignature(wxMsgValidationcodeModel.getSignature());
//替换短信内容
String msg = wxMsgValidationcodeModel.getContent();
for (Map.Entry<String, String> entry : record.getDynamicContentMap().entrySet()) {
msg = msg.replace("{"+entry.getKey()+"}", entry.getValue());
}

wxMsgValidationcode.setMsg(msg);
if(record.getDynamicContentMap() !=null) {
wxMsgValidationcode.setCode(record.getDynamicContentMap().get("s6"));
}

//3、从短信配置中查询密钥 bid 等信息
WxMsgConfig wxMsgConfig = new WxMsgConfig();
wxMsgConfig.updateTenantInfo(wxMsgValidationcode);
@@ -89,19 +80,50 @@ public class SendSmsServiceImpl implements MsgSendService {
if (wxMsgConfig.getRemains() <= 0L) {
throw new MallinkException(ErrorCode.MSG_CONFIG_ACCOUNT);
}
//查询是否有自己的配置
WxMsgValidationcodeModelTenant wxMsgValidationcodeModelTenant = new WxMsgValidationcodeModelTenant();
wxMsgValidationcodeModelTenant.updateTenantInfo(wxMsgValidationcode);
wxMsgValidationcodeModelTenant.setModelId(wxMsgValidationcodeModel.getId());
wxMsgValidationcodeModelTenant.setSmsChannel(wxMsgConfig.getSmsChannel());
WxMsgValidationcodeModelTenant _vmt = wxMsgValidationcodeModelTenantMapper.findByModelId(wxMsgValidationcodeModelTenant);
if (null != _vmt) {
if (!StringUtils.isBlank(_vmt.getSignature())) {
wxMsgValidationcodeModel.setSignature(_vmt.getSignature());
}
if (!StringUtils.isBlank(_vmt.getModelCode())) {
wxMsgValidationcodeModel.setModelCode(_vmt.getModelCode());
}
if (!StringUtils.isBlank(_vmt.getContent())) {
wxMsgValidationcodeModel.setContent(_vmt.getContent());
}
}
wxMsgValidationcode.setSignature(wxMsgValidationcodeModel.getSignature());
//替换短信内容
String msg = wxMsgValidationcodeModel.getContent();
for (Map.Entry<String, String> entry : record.getDynamicContentMap().entrySet()) {
msg = msg.replace("{"+entry.getKey()+"}", entry.getValue());
}

wxMsgValidationcode.setMsg(msg);
if(record.getDynamicContentMap() !=null) {
wxMsgValidationcode.setCode(record.getDynamicContentMap().get("s6"));
}

String secret = wxMsgConfig.getSecret();
String bid = wxMsgConfig.getBid();
String publickey = wxMsgConfig.getPublickey();
String phone = record.getReceiver();
int phoneLength = phone.split(",").length;
String signature = wxMsgValidationcodeModel.getSignature();

//如果有自己配置的model
String notifyUrl = wxMsgConfig.getNotifyurl();
Integer modelId = wxMsgValidationcodeModel.getModelId();
String id = record.getDynamicContentMap().get("id");
String result = SMSFactory.sendSms(wxMsgConfig, phone, signature, msg,
EnumVerifyCode.YES.getCode().toString(), modelId,JSON.toJSONString(record.getDynamicContentMap()),
String result = SMSFactory.sendSms(wxMsgConfig, phone, wxMsgValidationcodeModel.getSignature(), msg,
EnumVerifyCode.YES.getCode().toString(),JSON.toJSONString(record.getDynamicContentMap()),
wxMsgValidationcodeModel.getModelCode(),id);
JSONObject jsonObjectResult = JSONObject.parseObject(result);
String ret = jsonObjectResult.get("ret").toString();


+ 1
- 1
mallinkService/src/main/java/com/iformall/sms/SMSExcutor.java Просмотреть файл

@@ -5,7 +5,7 @@ import java.util.Date;
public interface SMSExcutor {

String sendMsg(String secret, String bid, String publickey,String phone, String signature,
String msg, String notifyUrl, String verifysms, Integer modelId,String templateParam,
String msg, String notifyUrl, String verifysms, String templateParam,
String templateCode, String outId);

String addTemplate(String secret, String bid, String publickey, String signature, String content,


+ 2
- 2
mallinkService/src/main/java/com/iformall/sms/SMSFactory.java Просмотреть файл

@@ -50,11 +50,11 @@ public class SMSFactory {
}

public static String sendSms(WxMsgConfig wxMsgConfig,String phone, String signature, String msg,
String verifysms, Integer modelId, String templateParam,
String verifysms, String templateParam,
String templateCode, String outId) {
return getSendExcutor(wxMsgConfig).sendMsg(wxMsgConfig.getSecret(), wxMsgConfig.getBid(), wxMsgConfig.getPublickey(),
phone, signature, msg, wxMsgConfig.getNotifyurl(),
verifysms, modelId,templateParam,templateCode,outId);
verifysms, templateParam,templateCode,outId);
}

public static String addTemplate(WxMsgConfig wxMsgConfig, String signature, String content,


+ 1
- 1
mallinkService/src/main/java/com/iformall/sms/aliyun/AliyunSMS.java Просмотреть файл

@@ -34,7 +34,7 @@ public class AliyunSMS implements SMSExcutor {
}

@Override
public String sendMsg(String secret, String bid, String publickey, String phone, String signature, String msg, String notifyUrl, String verifysms, Integer modelId, String templateParam, String templateCode, String outId) {
public String sendMsg(String secret, String bid, String publickey, String phone, String signature, String msg, String notifyUrl, String verifysms, String templateParam, String templateCode, String outId) {
SMSResult SMSResult = new SMSResult();
SMS sms = new SMS();
sms.setPhoneNumbers(phone);


+ 2
- 2
mallinkService/src/main/java/com/iformall/sms/wiwide/WiwideUtil.java Просмотреть файл

@@ -23,9 +23,9 @@ public class WiwideUtil implements SMSExcutor {


@Override
public String sendMsg(String secret, String bid, String publickey, String phone, String signature, String msg, String notifyUrl, String verifysms, Integer modelId, String templateParam, String templateCode, String outId) {
public String sendMsg(String secret, String bid, String publickey, String phone, String signature, String msg, String notifyUrl, String verifysms, String templateParam, String templateCode, String outId) {
return sendMsg(secret, bid, publickey, phone, signature, msg, notifyUrl,
verifysms, modelId);
verifysms, Integer.parseInt(templateCode));
}

@Override


+ 1
- 22
mallinkService/src/main/resources/mapper/WxMsgModelMapper.xml Просмотреть файл

@@ -11,14 +11,13 @@
<result column="createtime" jdbcType="TIMESTAMP" property="createtime"/>
<result column="status" jdbcType="INTEGER" property="status"/>
<result column="reason" jdbcType="INTEGER" property="reason"/>
<result column="model_id" jdbcType="INTEGER" property="modelId"/>
<result column="template_type" jdbcType="INTEGER" property="templateType"/>
<result column="model_code" jdbcType="VARCHAR" property="modelCode"/>

</resultMap>

<sql id="allColumns">
`id`,`tenant_id`,`parent_tenant_id`,`name`,`signature`,`content`,`createtime`,`status`,`reason`,`model_id`,`template_type`,`model_code`
`id`,`tenant_id`,`parent_tenant_id`,`name`,`signature`,`content`,`createtime`,`status`,`reason`,`template_type`,`model_code`
</sql>

<sql id="dynamicWhereConditions">
@@ -54,9 +53,6 @@
<if test=" null != status ">
and `status` = #{status}
</if>
<if test=" null != modelId">
and `model_id` = #{modelId}
</if>
<if test=" null != templateType">
and `template_type` = #{templateType}
</if>
@@ -88,23 +84,6 @@
and `status` = #{status}
</select>

<select id="findOneByModelId" parameterType="com.iformall.domain.po.WxMsgModel" resultMap="BaseResultMap">
select
<include refid="allColumns"/>
from wx_msg_model
where 1=1
<if test=" null != modelId">
and `model_id` = #{modelId}
</if>
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
limit 1
</select>

<update id="updateByCode" parameterType="com.iformall.domain.po.WxMsgModel">
update wx_msg_model set status=#{status},reason=#{reason} where `model_code` = #{modelCode}
</update>


+ 1
- 12
mallinkService/src/main/resources/mapper/WxMsgValidationcodeModelMapper.xml Просмотреть файл

@@ -9,20 +9,16 @@
<result column="createtime" jdbcType="TIMESTAMP" property="createtime" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="minutes" jdbcType="INTEGER" property="minutes" />
<result column="model_id" jdbcType="INTEGER" property="modelId" />
<result column="model_code" jdbcType="VARCHAR" property="modelCode" />
<result column="type" jdbcType="INTEGER" property="type" />
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId" />
<result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" />
<result column="email_bg_img" property="emailBgImg" />
<result column="open" property="open" />

<result column="msg_type" property="msgType" />
<result column="role_type" property="roleType" />
</resultMap>

<sql id="allColumns">
`id`,`name`,`signature`,`content`,`createtime`,`status`,`minutes`,`model_id`,`model_code`,`type`,`tenant_id`,`parent_tenant_id`,email_bg_img,`open`,msg_type,role_type
`id`,`name`,`signature`,`content`,`createtime`,`status`,`minutes`,`model_code`,`type`,email_bg_img,`open`,msg_type,role_type
</sql>

<sql id="dynamicWhereConditions">
@@ -34,15 +30,8 @@
<if test=" null != createtime "> and `createtime` = #{createtime} </if>
<if test=" null != status "> and `status` = #{status} </if>
<if test=" null != minutes "> and `minutes` = #{minutes} </if>
<if test=" null != modelId "> and `model_id` = #{modelId} </if>
<if test=" null != modelCode "> and `model_code` = #{modelCode} </if>
<if test=" null != type "> and `type` = #{type} </if>
<if test=" null != tenantId and '' != tenantId">
and `tenant_id` = #{tenantId}
</if>
<if test=" null != parentTenantId and '' != parentTenantId">
and `parent_tenant_id` = #{parentTenantId}
</if>
<if test=" null != open "> and `open` = #{open} </if>
<if test=" null != msgType "> and `msg_type` = #{msgType} </if>
<if test=" null != roleType "> and `role_type` = #{roleType} </if>


+ 46
- 0
mallinkService/src/main/resources/mapper/WxMsgValidationcodeModelTenantMapper.xml Просмотреть файл

@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.iformall.mapper.WxMsgValidationcodeModelTenantMapper">
<resultMap id="BaseResultMap" type="com.iformall.domain.po.WxMsgValidationcodeModelTenant">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId" />
<result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" />
<result column="model_id" jdbcType="BIGINT" property="modelId" />
<result column="signature" jdbcType="VARCHAR" property="signature" />
<result column="content" jdbcType="VARCHAR" property="content" />
<result column="model_code" jdbcType="VARCHAR" property="modelCode" />
<result column="sms_channel" jdbcType="INTEGER" property="smsChannel" />
</resultMap>

<sql id="allColumns">
`id`,`tenant_id`,`parent_tenant_id`,`model_id`,`signature`,`content`,`model_code`,`sms_channel`
</sql>

<sql id="dynamicWhereConditions">
where 1 = 1
<if test=" null != id "> and `id` = #{id} </if>
<if test=" null != tenantId "> and `tenant_id` = #{tenantId} </if>
<if test=" null != modelId "> and `model_id` = #{modelId} </if>
<if test=" null != signature "> and `signature` = #{signature} </if>
<if test=" null != content "> and `content` = #{content} </if>
<if test=" null != modelCode "> and `model_code` = #{modelCode} </if>
<if test=" null != smsChannel "> and `sms_channel` = #{smsChannel} </if>
<if test=" null != ids ">
and id in
<foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
#{idItem}
</foreach>
</if>
<if test=" null != sortColumns"> order by ${sortColumns} </if>
</sql>

<select id="findList" parameterType="com.iformall.domain.po.WxMsgValidationcodeModelTenant" resultMap="BaseResultMap">
select <include refid="allColumns" /> from wx_msg_validationcode_model_tenant
<include refid="dynamicWhereConditions" />
</select>
<select id="findByModelId" parameterType="com.iformall.domain.po.WxMsgValidationcodeModelTenant" resultMap="BaseResultMap">
select <include refid="allColumns" /> from wx_msg_validationcode_model_tenant
where `tenant_id` = #{tenantId} and `model_id` = #{modelId} and sms_channel = #{smsChannel}
</select>
</mapper>

+ 7
- 3
mallinkService/src/main/resources/mapper/WxRentContractMapper.xml Просмотреть файл

@@ -124,6 +124,9 @@
<result column="operating_management_fee" jdbcType="INTEGER" property="operatingManagementFee"/>
<result column="operating_management_fee_ratio_way" jdbcType="INTEGER" property="operatingManagementFeeRatioWay"/>
<result column="operating_management_fee_ratio" jdbcType="VARCHAR" property="operatingManagementFeeRatio"/>
<result column="out_date_notify_days" jdbcType="INTEGER" property="outDateNotifyDays"/>
<result column="out_date_notify_phone" jdbcType="VARCHAR" property="outDateNotifyPhone"/>
</resultMap>

<sql id="allColumns">
@@ -141,7 +144,7 @@
`business_type`,`rent_info`, `file_names`,price_unit,rent_price,other_rent_price_info,`subject_name`,rent_start_type,
`rent_input_way`,`adjust_ratio_way`,`operation_type`,late_pay_ratio,late_pay_day,bus_discount_ratio,bus_discount_time,
bussiness_management_fee,bussiness_management_fee_ratio_way,bussiness_management_fee_ratio,
operating_management_fee,operating_management_fee_ratio_way,operating_management_fee_ratio
operating_management_fee,operating_management_fee_ratio_way,operating_management_fee_ratio,out_date_notify_days,out_date_notify_phone
</sql>


@@ -153,6 +156,7 @@
<if test=" null != price and '' != price">and `price` = #{price}</if>
<if test=" null != rentalStartDate and '' != rentalStartDate">and `rental_start_date` = #{rentalStartDate}</if>
<if test=" null != rentalEndDate and '' != rentalEndDate">and `rental_end_date` = #{rentalEndDate}</if>
<if test=" null != outDateNofity ">and (out_date_notify_phone is not null and out_date_notify_phone != '' and DATE_SUB(rental_end_date, INTERVAL out_date_notify_days DAY) &lt;= NOW())</if>
<if test=" null != signDate and '' != signDate">and `sign_date` = #{signDate}</if>
<if test=" null != receivePeriod and '' != receivePeriod">and `receive_period` = #{receivePeriod}</if>
<if test=" null != tenantId and '' != tenantId">
@@ -510,7 +514,7 @@
rc.`business_type`,rc.`rent_info`, rc.`file_names`,rc.price_unit,rent_price,rc.other_rent_price_info,rc.`subject_name`,rc.rent_start_type,
rc.`rent_input_way`,rc.`adjust_ratio_way`,rc.`operation_type`,rc.late_pay_ratio,rc.late_pay_day,rc.bus_discount_ratio,rc.bus_discount_time,
rc.bussiness_management_fee,rc.bussiness_management_fee_ratio_way,rc.bussiness_management_fee_ratio,
rc.operating_management_fee,rc.operating_management_fee_ratio_way,rc.operating_management_fee_ratio
rc.operating_management_fee,rc.operating_management_fee_ratio_way,rc.operating_management_fee_ratio,rc.out_date_notify_days,rc.out_date_notify_phone
from wx_shop s
left join wx_merchant_shop ms on ms.shop_id=s.id and ms.is_del=0
left join wx_merchant m on ms.merchant_id=m.id
@@ -537,7 +541,7 @@
rc.`business_type`,rc.`rent_info`, rc.`file_names`,rc.price_unit,rent_price,rc.other_rent_price_info,rc.`subject_name`,rc.rent_start_type,
rc.`rent_input_way`,rc.`adjust_ratio_way`,rc.`operation_type`,rc.late_pay_ratio,rc.late_pay_day,rc.bus_discount_ratio,rc.bus_discount_time,
rc.bussiness_management_fee,rc.bussiness_management_fee_ratio_way,rc.bussiness_management_fee_ratio,
rc.operating_management_fee,rc.operating_management_fee_ratio_way,rc.operating_management_fee_ratio
rc.operating_management_fee,rc.operating_management_fee_ratio_way,rc.operating_management_fee_ratio,rc.out_date_notify_days,rc.out_date_notify_phone
from wx_rent_contract rc
where rc.is_del = 0
<if test=" null != tenantId and '' != tenantId">


+ 1
- 1
mallinkTTAdmin/src/main/java/com/iformall/controller/basic/WxProjectConfigController.java Просмотреть файл

@@ -578,7 +578,7 @@ public class WxProjectConfigController extends BaseController {
List<WxQuestion> wxQuestionList = wxQuestionService.findList(wxQuestion);
map.put("wxQuestionList",wxQuestionList);
WxMsgValidationcodeModel wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.setTenantId(wxMall.getTenantId());
//wxMsgValidationcodeModel.setTenantId(wxMall.getTenantId());

List<WxMsgValidationcodeModel> wxMsgValidationcodeModelList = wxMsgValidationcodeModelService.findList(wxMsgValidationcodeModel);
map.put("wxMsgValidationcodeModelList",wxMsgValidationcodeModelList);


+ 38
- 38
mallinkTTAdmin/src/main/java/com/iformall/controller/msg/WxMsgValidationcodeModelController.java Просмотреть файл

@@ -24,44 +24,44 @@ public class WxMsgValidationcodeModelController extends BaseController {
@Autowired
private WxMsgValidationcodeModelService wxMsgValidationcodeModelService;

@ApiOperation("消息模板-列表")
@GetMapping("list")
@ApiImplicitParams({
@ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true),
@ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)})
@SystemControllerLog(description = "消息验证模板-列表")
public ResultData list(@ModelAttribute WxMsgValidationcodeModel wxMsgValidationcodeModel, Integer pageNum, Integer pageSize) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::list");
if (null == wxMsgValidationcodeModel) wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
PageInfo<WxMsgValidationcodeModel> page = wxMsgValidationcodeModelService.listAsPage(wxMsgValidationcodeModel, pageNum, pageSize);
page.getList().forEach(m -> {
for (EnumMsgModelReplace e : EnumMsgModelReplace.values()) {
m.setContent(m.getContent().replace(e.getCode(),e.getMessage()));
}
});
return new ResultData(page);
}
@ApiOperation("消息模板-添加")
@PostMapping("add")
@SystemControllerLog(description = "消息验证模板-添加")
public ResultData add(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::add");
//Assert.notNull(wxMsgValidationcodeModel.getName(), "角色名不能为空");
//Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
return wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
}
@ApiOperation("消息模板-更新")
@PostMapping("update")
@SystemControllerLog(description = "消息验证模板-更新")
public ResultData update(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::update");
wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
return new ResultData();
}
// @ApiOperation("消息模板-列表")
// @GetMapping("list")
// @ApiImplicitParams({
// @ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true),
// @ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)})
// @SystemControllerLog(description = "消息验证模板-列表")
// public ResultData list(@ModelAttribute WxMsgValidationcodeModel wxMsgValidationcodeModel, Integer pageNum, Integer pageSize) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::list");
// if (null == wxMsgValidationcodeModel) wxMsgValidationcodeModel = new WxMsgValidationcodeModel();
// wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
// PageInfo<WxMsgValidationcodeModel> page = wxMsgValidationcodeModelService.listAsPage(wxMsgValidationcodeModel, pageNum, pageSize);
// page.getList().forEach(m -> {
// for (EnumMsgModelReplace e : EnumMsgModelReplace.values()) {
// m.setContent(m.getContent().replace(e.getCode(),e.getMessage()));
// }
// });
// return new ResultData(page);
// }
//
// @ApiOperation("消息模板-添加")
// @PostMapping("add")
// @SystemControllerLog(description = "消息验证模板-添加")
// public ResultData add(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::add");
// //Assert.notNull(wxMsgValidationcodeModel.getName(), "角色名不能为空");
// //Assert.isTrue(!checkUnique(sysRole.getName(), null), "重复的角色名");
// wxMsgValidationcodeModel.updateTenantInfo(getTenantInfo());
// return wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
// }
//
// @ApiOperation("消息模板-更新")
// @PostMapping("update")
// @SystemControllerLog(description = "消息验证模板-更新")
// public ResultData update(@RequestBody WxMsgValidationcodeModel wxMsgValidationcodeModel) {
// logger.debug("[" + getIpAddr() + "] WxMsgValidationcodeModelController::update");
// wxMsgValidationcodeModelService.saveOrUpdate(wxMsgValidationcodeModel);
// return new ResultData();
// }

@ApiOperation("消息模板-打开/关闭发送")
@PostMapping("updateOpen")


Загрузка…
Отмена
Сохранить