短信 code review 2020-02-25

This commit is contained in:
YunaiV
2021-02-25 01:24:06 +08:00
parent 2a4d9f43eb
commit cd2a01819b
10 changed files with 13 additions and 24 deletions

View File

@@ -37,12 +37,10 @@ public class SmsChannelController {
return success(service.getSmsChannelEnums());
}
@ApiOperation("添加消息渠道")
@PostMapping("/create")
public CommonResult<Long> add(@Validated @RequestBody SmsChannelCreateReqVO reqVO) {
return success(service.createSmsChannel(reqVO));
}
}

View File

@@ -24,7 +24,7 @@ public class SmsSendConsumer extends AbstractChannelMessageListener<SmsSendMessa
@Override
public void onMessage(SmsSendMessage message) {
log.info("[onMessage][收到 发送短信 消息]");
log.info("[onMessage][收到 发送短信 消息]"); // TODO FROM 芋艿 to zzflog 如果要打,这里要内容打上。其他 Consumer 没打的原因,是没内容。。。
SmsResult send = sysSmsService.send(message.getSmsBody(), message.getTargetPhones());
}

View File

@@ -18,9 +18,6 @@ import java.util.List;
*/
public interface SysSmsChannelService {
// TODO FROM 芋艿 to ZZFSmsChannelService=》SysSmsChannelService增加 Sys 前缀,算在系统模块里
// TODO FROM 芋艿 to ZZF方法名保持不去掉 Sms 前缀。虽然长点,嘿嘿
/**
* 初始化短信渠道
*/

View File

@@ -42,6 +42,7 @@ public class SysSmsChannelServiceImpl implements SysSmsChannelService {
@Autowired
private SmsClientFactory clientFactory;
// TODO FROM 芋艿 to zzf方法要放在成员变量下面
/**
* 初始化短信客户端
*/
@@ -65,7 +66,6 @@ public class SysSmsChannelServiceImpl implements SysSmsChannelService {
});
}
// TODO FROM 芋艿 to ZZFchannelMapper 嘿,保持命名统一。 DONE
@Resource
private SysSmsChannelMapper channelMapper;