Commit f4061a47 authored by danzhongqin's avatar danzhongqin

新增结构

parent 528ba3c0
package com.jz.sms.repository;
import org.springframework.stereotype.Repository;
/**
* Mybatis 接口文件
*/
@Repository
public interface MessageMapper {
// int createTemplate(XXXX....)
}
package com.jz.sms.service;
import com.jz.sms.config.SMSConfig;
import com.jz.sms.dto.XfaceDmHubTemplateRequestDTO;
import com.jz.sms.dto.XfaceDmHubTemplateResponseDTO;
import com.jz.sms.repository.MessageMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@Service
public class MessageService {
/** 基础配置 */
@Autowired
private SMSConfig smsComfig;
/** 数据层 */
@Autowired
private MessageMapper messageMapper;
/**
* 短信模板创建
* @param requestDTO
* @return
*/
public XfaceDmHubTemplateResponseDTO createTemplate(XfaceDmHubTemplateRequestDTO requestDTO) {
XfaceDmHubTemplateResponseDTO responseDTO = new XfaceDmHubTemplateResponseDTO();
try {
// XfaceClTemplateRequestDTO clTemplateRequestDTO = new XfaceClTemplateRequestDTO();
// XfaceClTemplateResponseDTO clTemplateResponseDTO = new XfaceClTemplateResponseDTO();
// logger.info("短信通道请求URL:"+url);
// logger.info("短信通道返回内容:"+responseStr);
} catch (Exception exception) {
// 记录异常日志
throw exception;
}
return responseDTO;
}
}
package com.jz.sms.wrapper.maintenance;
import com.jz.sms.dto.XfaceDmHubTemplateRequestDTO;
import com.jz.sms.dto.XfaceDmHubTemplateResponseDTO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;
import javax.validation.Valid;
@RestController
//@Api(tags = "SMS0001 短信模板创建")
public class XfaceCreateTempLateWrapper {
@Autowired
XfaceCreateTempLateWrapperImpl xfaceCreateTempLateWrapperImpl;
// @ApiOperation(value = "SMS0001 短信模板创建", httpMethod = "POST")
@PostMapping(value = "/sms/template/create")
@ResponseBody
public XfaceDmHubTemplateResponseDTO processRequest(@Valid @RequestBody XfaceDmHubTemplateRequestDTO requestDTO) {
return xfaceCreateTempLateWrapperImpl.doProcessRequest(requestDTO);
}
}
package com.jz.sms.wrapper.maintenance;
import com.jz.sms.dto.XfaceDmHubTemplateRequestDTO;
import com.jz.sms.dto.XfaceDmHubTemplateResponseDTO;
import com.jz.sms.service.MessageService;
import org.springframework.beans.factory.annotation.Autowired;
public class XfaceCreateTempLateWrapperImpl {
@Autowired
private MessageService messageService;
public XfaceDmHubTemplateResponseDTO doProcessRequest(XfaceDmHubTemplateRequestDTO requestDTO) {
return messageService.createTemplate(requestDTO);
}
}
<!--<?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.qianlian.cloud.tms.repository.BaApplicationConfigMapper">-->
<!--</mapper>-->
\ No newline at end of file
##########TMS错误码开始##########
120001 = 编号不存在。
##########TMS错误码结束##########
\ No newline at end of file
### TMS error code start
10001 = 验证码发送失败
10002 = 验证码已过期
10003 = 登陆失败
10004 = 账号不存在
10005 = 验证码错误
### TMS error code end
\ No newline at end of file
### TMS error code start
10001 = 验证码发送失败
10002 = 验证码已过期
10003 = 登陆失败
10004 = 账号不存在
10005 = 验证码错误
### TMS error code end
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment