|
|
@@ -112,9 +112,9 @@ public class WechatCustomerServiceImpl implements WechatCustomerService {
|
|
|
} catch (WxErrorException e) {
|
|
|
throw new RuntimeException(e);
|
|
|
}
|
|
|
- restTimeSendMsg(wxCpKfMsgItem.getExternalUserId(), wxCpKfMsgItem.getOpenKfid());
|
|
|
+ restTimeSendMsg(workingHours, wxCpKfMsgItem.getExternalUserId(), wxCpKfMsgItem.getOpenKfid());
|
|
|
} else if (state1 == 1) {
|
|
|
- restTimeSendMsg(wxCpKfMsgItem.getExternalUserId(), wxCpKfMsgItem.getOpenKfid());
|
|
|
+ restTimeSendMsg(workingHours, wxCpKfMsgItem.getExternalUserId(), wxCpKfMsgItem.getOpenKfid());
|
|
|
} else if (state1 == 3) {
|
|
|
state1 = 4;
|
|
|
try {
|
|
|
@@ -169,8 +169,13 @@ public class WechatCustomerServiceImpl implements WechatCustomerService {
|
|
|
}, 2, 2);
|
|
|
}
|
|
|
|
|
|
- private void restTimeSendMsg(String externalUserId, String openKfId) {
|
|
|
- String message = "您咨询的客服目前暂时不在服务时间,请您前往“晋掌柜App”点击“微信客服”,将为您安排新的客服为您提供服务~(客服服务时间:周一至周五 8:30-18:30,周六至周日 8:30-18:30,午间 12:00-14:00 休息)";
|
|
|
+ private void restTimeSendMsg(boolean workingHours, String externalUserId, String openKfId) {
|
|
|
+ String message;
|
|
|
+ if(!workingHours){
|
|
|
+ message = "您好~当前客服暂时不在服务时间,服务时间为:周一至周五:8:30-12:00,14:00-18:30,周六至周日:9:00-12:00,14:00-18:30,当前未到服务时间,请您在服务时段内咨询~";
|
|
|
+ }else {
|
|
|
+ message = "您咨询的客服目前暂时不在服务时间,请您前往“晋掌柜App”点击“微信客服”,将为您安排新的客服为您提供服务~(客服服务时间:周一至周五 8:30-18:30,周六至周日 9:00-18:30,午间 12:00-14:00 休息)";
|
|
|
+ }
|
|
|
WxCpKfMsgSendRequest wxCpKfMsgSendRequest = new WxCpKfMsgSendRequest();
|
|
|
wxCpKfMsgSendRequest.setToUser(externalUserId);
|
|
|
wxCpKfMsgSendRequest.setOpenKfid(openKfId);
|