| | |
| | | package com.matrix.core.tools; |
| | | |
| | | import cn.hutool.json.JSONUtil; |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.aliyuncs.CommonRequest; |
| | |
| | | import com.aliyuncs.IAcsClient; |
| | | import com.aliyuncs.exceptions.ClientException; |
| | | import com.aliyuncs.http.MethodType; |
| | | import com.google.gson.JsonObject; |
| | | import com.matrix.config.properties.AliSmsProperties; |
| | | import com.matrix.core.exception.GlobleException; |
| | | import com.matrix.system.hive.bean.SysSmsTemplate; |
| | |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | |
| | | CommonRequest request = commonRequest(SysSmsTemplate.SMS_ACTION_SEND); |
| | | request.putQueryParameter("PhoneNumbers", phoneNum); |
| | | request.putQueryParameter("TemplateCode", templateCode); |
| | | String jsonStr = JSONObject.toJSONString(values); |
| | | request.putQueryParameter("TemplateParam", jsonStr); |
| | | request.putQueryParameter("TemplateParam", JSONUtil.parse(values).toString()); |
| | | |
| | | CommonResponse response = null; |
| | | try { |