@@ -1377,7 +1377,7 @@ public class WxMpServiceImpl implements WxMpService { | |||||
return this.kefuService; | return this.kefuService; | ||||
} | } | ||||
public void setCustomerService(WxMpKefuService kefuService) { | |||||
public void setKefuService(WxMpKefuService kefuService) { | |||||
this.kefuService = kefuService; | this.kefuService = kefuService; | ||||
this.kefuService.setWxMpService(this); | this.kefuService.setWxMpService(this); | ||||
} | } | ||||
@@ -20,6 +20,14 @@ import me.chanjar.weixin.mp.bean.customerservice.result.WxMpKfOnlineList; | |||||
public class WxMpKefuServiceImpl implements WxMpKefuService { | public class WxMpKefuServiceImpl implements WxMpKefuService { | ||||
private WxMpService wxMpService; | private WxMpService wxMpService; | ||||
public WxMpKefuServiceImpl(){ | |||||
} | |||||
public WxMpKefuServiceImpl(WxMpService wxMpService) { | |||||
this.wxMpService = wxMpService; | |||||
} | |||||
@Override | @Override | ||||
public void setWxMpService(WxMpService wxMpService) { | public void setWxMpService(WxMpService wxMpService) { | ||||
this.wxMpService = wxMpService; | this.wxMpService = wxMpService; | ||||
@@ -23,8 +23,9 @@ public class ApiTestModule implements Module { | |||||
WxXmlMpInMemoryConfigStorage.class, is1); | WxXmlMpInMemoryConfigStorage.class, is1); | ||||
WxMpServiceImpl wxService = new WxMpServiceImpl(); | WxMpServiceImpl wxService = new WxMpServiceImpl(); | ||||
wxService.setWxMpConfigStorage(config); | wxService.setWxMpConfigStorage(config); | ||||
WxMpKefuService customerService = new WxMpKefuServiceImpl(); | |||||
wxService.setCustomerService(customerService); | |||||
WxMpKefuService kefuService = new WxMpKefuServiceImpl(); | |||||
wxService.setKefuService(kefuService); | |||||
binder.bind(WxMpServiceImpl.class).toInstance(wxService); | binder.bind(WxMpServiceImpl.class).toInstance(wxService); | ||||
binder.bind(WxMpConfigStorage.class).toInstance(config); | binder.bind(WxMpConfigStorage.class).toInstance(config); | ||||