Преглед изворни кода

[短信发送][修改][回调地址]

release_toaliyun_real
gongbiao пре 6 година
родитељ
комит
75ce0b2142
2 измењених фајлова са 6 додато и 5 уклоњено
  1. +4
    -3
      mallinkService/src/main/java/com/iformall/service/impl/WxCouponInjectServiceImpl.java
  2. +2
    -2
      mallinkService/src/main/java/com/iformall/service/msg/impl/SendSmsServiceImpl.java

+ 4
- 3
mallinkService/src/main/java/com/iformall/service/impl/WxCouponInjectServiceImpl.java Прегледај датотеку

@@ -21,7 +21,6 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;


import java.util.*; import java.util.*;
import java.util.stream.Collectors;


@Service @Service
public class WxCouponInjectServiceImpl implements WxCouponInjectService { public class WxCouponInjectServiceImpl implements WxCouponInjectService {
@@ -119,10 +118,12 @@ public class WxCouponInjectServiceImpl implements WxCouponInjectService {
//2、通过标签 //2、通过标签
String phones = record.getPhones(); String phones = record.getPhones();
List<WxCUserBasicInfoFilterListDto> filter = record.getFilterList(); List<WxCUserBasicInfoFilterListDto> filter = record.getFilterList();
if (!phones.isEmpty() && !filter.isEmpty()) {//两种方式只能选其一
if (!phones.isEmpty() && !filter.isEmpty()) {
//两种方式只能选其一
return new ResultData(ErrorCode.MSG_SEND_WAY_CHOOSE_ERROR); return new ResultData(ErrorCode.MSG_SEND_WAY_CHOOSE_ERROR);
} }
if (phones.isEmpty() && filter.isEmpty()) {//两种方式必须选其一
if (phones.isEmpty() && filter.isEmpty()) {
//两种方式必须选其一
return new ResultData(ErrorCode.MSG_SEND_WAY_CHOOSE_ERROR); return new ResultData(ErrorCode.MSG_SEND_WAY_CHOOSE_ERROR);
} }




+ 2
- 2
mallinkService/src/main/java/com/iformall/service/msg/impl/SendSmsServiceImpl.java Прегледај датотеку

@@ -87,7 +87,7 @@ public class SendSmsServiceImpl implements MsgSendService {
wxMsgValidationcode.setCode(record.getDynamicContentMap().get("s6")); wxMsgValidationcode.setCode(record.getDynamicContentMap().get("s6"));
} }


String notifyUrl = wxMsgConfig.getNotifyurl();
String notifyUrl = wxMsgConfig.getVerifynotifyurl();
Integer modelId = wxMsgValidationcodeModel.getModelId(); Integer modelId = wxMsgValidationcodeModel.getModelId();
String result = WiwideUtil.sendMsg(secret, bid, publickey, phone, signature, msg, notifyUrl, EnumVerifyCode.YES.getCode().toString(), modelId); String result = WiwideUtil.sendMsg(secret, bid, publickey, phone, signature, msg, notifyUrl, EnumVerifyCode.YES.getCode().toString(), modelId);
JSONObject jsonObjectResult = JSONObject.parseObject(result); JSONObject jsonObjectResult = JSONObject.parseObject(result);
@@ -108,7 +108,7 @@ public class SendSmsServiceImpl implements MsgSendService {
wxMsgValidationcodeMapper.insertSelective(wxMsgValidationcode); wxMsgValidationcodeMapper.insertSelective(wxMsgValidationcode);
wxMsgValidationcodeService.addMsgCallback(wxMsgValidationcode,batchNo); wxMsgValidationcodeService.addMsgCallback(wxMsgValidationcode,batchNo);
//扣减剩余条数 //扣减剩余条数
wxMsgConfig.setRemains(1l);
wxMsgConfig.setRemains(1L);
wxMsgConfigMapper.updateRemains(wxMsgConfig); wxMsgConfigMapper.updateRemains(wxMsgConfig);
}else{ }else{
throw new MallinkException(1001,"运营商返回失败:"+result); throw new MallinkException(1001,"运营商返回失败:"+result);


Loading…
Откажи
Сачувај