- 优化:sms client 重命名
This commit is contained in:
parent
e4048f8716
commit
6e5254e737
@ -1,6 +1,5 @@
|
|||||||
package cn.iocoder.mall.system.biz.service.sms.client;
|
package cn.iocoder.mall.system.biz.service.sms;
|
||||||
|
|
||||||
import cn.iocoder.mall.system.biz.service.sms.SmsClient;
|
|
||||||
import com.alibaba.fastjson.JSON;
|
import com.alibaba.fastjson.JSON;
|
||||||
import com.aliyuncs.CommonRequest;
|
import com.aliyuncs.CommonRequest;
|
||||||
import com.aliyuncs.CommonResponse;
|
import com.aliyuncs.CommonResponse;
|
||||||
@ -28,9 +27,9 @@ import java.util.Map;
|
|||||||
* @time 2019/5/25 12:28 PM
|
* @time 2019/5/25 12:28 PM
|
||||||
*/
|
*/
|
||||||
@Component
|
@Component
|
||||||
public class SmsAliYunClient implements SmsClient {
|
public class SmsClientOfAliYun implements SmsClient {
|
||||||
|
|
||||||
private static final Logger LOGGER = LoggerFactory.getLogger(SmsAliYunClient.class);
|
private static final Logger LOGGER = LoggerFactory.getLogger(SmsClientOfAliYun.class);
|
||||||
|
|
||||||
private static final String DOMAIN = "dysmsapi.aliyuncs.com";
|
private static final String DOMAIN = "dysmsapi.aliyuncs.com";
|
||||||
private static final String SUCCESS_CODE = "OK";
|
private static final String SUCCESS_CODE = "OK";
|
@ -1,8 +1,7 @@
|
|||||||
package cn.iocoder.mall.system.biz.service.sms.client;
|
package cn.iocoder.mall.system.biz.service.sms;
|
||||||
|
|
||||||
import cn.iocoder.common.framework.exception.ServiceException;
|
import cn.iocoder.common.framework.exception.ServiceException;
|
||||||
import cn.iocoder.mall.system.biz.enums.AdminErrorCodeEnum;
|
import cn.iocoder.mall.system.biz.enums.AdminErrorCodeEnum;
|
||||||
import cn.iocoder.mall.system.biz.service.sms.SmsClient;
|
|
||||||
import com.alibaba.fastjson.JSON;
|
import com.alibaba.fastjson.JSON;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import org.apache.http.HttpEntity;
|
import org.apache.http.HttpEntity;
|
||||||
@ -32,9 +31,9 @@ import java.util.Map;
|
|||||||
* @time 2019/5/16 6:34 PM
|
* @time 2019/5/16 6:34 PM
|
||||||
*/
|
*/
|
||||||
@Component
|
@Component
|
||||||
public class SmsYunPianClient implements SmsClient {
|
public class SmsClientOfYunPian implements SmsClient {
|
||||||
|
|
||||||
protected static final Logger LOGGER = LoggerFactory.getLogger(SmsYunPianClient.class);
|
protected static final Logger LOGGER = LoggerFactory.getLogger(SmsClientOfYunPian.class);
|
||||||
|
|
||||||
private static final int SUCCESS_CODE = 0;
|
private static final int SUCCESS_CODE = 0;
|
||||||
private static final String SUCCESS_MESSAGE = "SUCCESS";
|
private static final String SUCCESS_MESSAGE = "SUCCESS";
|
@ -55,10 +55,10 @@ public class SmsServiceImpl implements SmsService {
|
|||||||
private SmsSendMapper smsSendMapper;
|
private SmsSendMapper smsSendMapper;
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
@Qualifier("smsYunPianClient")
|
@Qualifier("smsClientOfYunPian")
|
||||||
private SmsClient smsYunPianClient;
|
private SmsClient smsYunPianClient;
|
||||||
@Autowired
|
@Autowired
|
||||||
@Qualifier("smsAliYunClient")
|
@Qualifier("smsClientOfAliYun")
|
||||||
private SmsClient smsAliYunClient;
|
private SmsClient smsAliYunClient;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user