...
|
...
|
@@ -11,6 +11,7 @@ import com.yoho.yhmessage.wechat.service.IMiniAppAccessTokenService; |
|
|
import com.yoho.yhmessage.wechat.service.IMiniAppService;
|
|
|
import com.yoho.yhmessage.wechat.service.model.AccessToken;
|
|
|
import com.yoho.yhmessage.wechat.util.SendWechatRequest;
|
|
|
import com.yoho.yhmessage.wechat.util.WeChatUtils;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
...
|
...
|
@@ -97,11 +98,11 @@ public class MiniServiceAppImpl implements IMiniAppService { |
|
|
}else {
|
|
|
logger.warn("send msg orderCode is {}, result is {}",reqBO.getOrderCode(), JSONObject.toJSONString(result));
|
|
|
|
|
|
// 经常48001的错误
|
|
|
if(result.getInteger("errcode")== 48001){
|
|
|
logger.info("sendMsgUpdateDB retry ,orderCode is {}", reqBO.getOrderCode());
|
|
|
sendMsgUpdateDB(reqBO, miniappMsgForm);
|
|
|
}
|
|
|
// // 经常48001的错误
|
|
|
// if(result.getInteger("errcode")== 48001){
|
|
|
// logger.info("sendMsgUpdateDB retry ,orderCode is {}", reqBO.getOrderCode());
|
|
|
// sendMsgUpdateDB(reqBO, miniappMsgForm);
|
|
|
// }
|
|
|
}
|
|
|
|
|
|
return result;
|
...
|
...
|
@@ -127,7 +128,7 @@ public class MiniServiceAppImpl implements IMiniAppService { |
|
|
bodyParam.put("data", reqBO.getData());
|
|
|
|
|
|
logger.info("sendTemplateMsg url is {}, body is {}", urlBuilder.toString(), JSONObject.toJSONString(bodyParam));
|
|
|
JSONObject result = sendWechatRequest.sendWechatRequest(urlBuilder.toString(), METHOD_POST, JSONObject.toJSONString(bodyParam));
|
|
|
JSONObject result = WeChatUtils.httpRequest(urlBuilder.toString(), METHOD_POST, JSONObject.toJSONString(bodyParam));
|
|
|
logger.info("sendMiniappMsg, msg send, order is {}, result is {}",reqBO.getOrderCode(), JSONObject.toJSONString(result));
|
|
|
return result;
|
|
|
}
|
...
|
...
|
|