Commit ade4db6b authored by 耿迪迪's avatar 耿迪迪

群发语音修改 gengdidi

parent 3d370aa6
......@@ -35,7 +35,7 @@ public class SmsController {
* @param sendSms 短信实体
* @return Result
*/
@RequestMapping(value="/sendSms",method = RequestMethod.GET)
@RequestMapping(value="/sendSms",method = RequestMethod.POST)
public Result sendSms(@Valid @RequestBody SendSms sendSms, BindingResult result){
try {
if(result.hasErrors()){
......
......@@ -32,7 +32,7 @@ public class VoiceNotifyController {
* @param sendVoiceNotify 发送语音实体
* @return String
*/
@RequestMapping(value = "/sendVoiceNotify",method = RequestMethod.GET)
@RequestMapping(value = "/sendVoiceNotify",method = RequestMethod.POST)
public Result sendVoiceNotify(@Valid @RequestBody SendVoiceNotify sendVoiceNotify, BindingResult result){
try {
if(result.hasErrors()){
......@@ -50,7 +50,7 @@ public class VoiceNotifyController {
* @param sendBatchVoiceNotify 批量发送语音实体
* @return String
*/
@RequestMapping(value = "/sendBatchVoiceNotify",method = RequestMethod.GET)
@RequestMapping(value = "/sendBatchVoiceNotify",method = RequestMethod.POST)
public Result sendBatchVoiceNotify(@Valid @RequestBody SendBatchVoiceNotify sendBatchVoiceNotify, BindingResult result){
try {
if(result.hasErrors()){
......
......@@ -8,7 +8,7 @@ public class SendBatchVoiceNotify extends BaseRequestModel {
/**
* 语音群发号码
* "[133333333,133333333]"
* 被叫号码,模版无变量多个则以英文半角分号“;”分割;模板带变量,多个号码以英文分号“;”分割,号码和变量以英文逗号“,”隔开, 多个变量以竖线“|”隔开,如 130XXXXXXXX,123|456;186XXXXXXXX,321|654(注意:文件语音模板类型 号码之间分隔用“,”隔开)
*/
@NotBlank(message = "语音群发号码不能为空")
private String phoneNumberJson;
......@@ -19,10 +19,5 @@ public class SendBatchVoiceNotify extends BaseRequestModel {
@NotBlank(message = "语音模板不能为空")
private String templateId;
/**
*模板变量字符串
* [{\"变量1\":\"值1\",\"变量2\":\"值2\",\"变量3\":\"值3\"},{\"变量1\":\"值1\",\"变量2\":\"值2\",\"变量3\":\"值3\"}]
*/
private String paramJson;
}
......@@ -45,10 +45,6 @@ public class VoiceNotifyServiceImpl implements VoiceNotifyService {
Map<String,Object> params = getParams();
params.put("mobile",sendBatchVoiceNotify.getPhoneNumberJson());
params.put("templateId", sendBatchVoiceNotify.getTemplateId());
if(StringUtils.isNotBlank(sendBatchVoiceNotify.getParamJson())){
params.put("param", sendBatchVoiceNotify.getParamJson());
}
return HttpUtil.doPost(batchVoiceNotifyURL,params);
}
......
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