From 5a0d041f9cc8bedf8531cddd075c84f7941798e6 Mon Sep 17 00:00:00 2001 From: kira <164851225@qq.com> Date: Thu, 2 Aug 2018 10:12:06 +0800 Subject: [PATCH] fixbug --- .../com/royalpay/payment/manage/task/PostponeClientTask.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/au/com/royalpay/payment/manage/task/PostponeClientTask.java b/src/main/java/au/com/royalpay/payment/manage/task/PostponeClientTask.java index 34f765665..36365eb9e 100644 --- a/src/main/java/au/com/royalpay/payment/manage/task/PostponeClientTask.java +++ b/src/main/java/au/com/royalpay/payment/manage/task/PostponeClientTask.java @@ -22,6 +22,7 @@ import org.springframework.scheduling.annotation.Scheduled; import org.springframework.stereotype.Component; import org.springframework.transaction.annotation.Transactional; import org.springframework.util.CollectionUtils; +import org.springframework.util.StringUtils; import java.util.Date; import java.util.HashMap; @@ -111,6 +112,9 @@ public class PostponeClientTask { JSONObject client = clientManager.getClientInfo(account.getIntValue("client_id")); try { + if(StringUtils.isEmpty(account.getString("wechat_openid"))){ + return; + } MpWechatApi api = mpWechatApiProvider.getApiFromOpenId(account.getString("wechat_openid")); if (api != null) { String templateId = api.getTemplateId("client-postpone");