Commit 57769c3c by songyinghui

feat: 查询商品服务

parent 56cb0c06
......@@ -11,6 +11,7 @@ import com.gic.haoban.manage.api.enums.content.TriggerCustomerChannelType;
import com.gic.haoban.manage.api.service.content.task.QywxGroupMsgTaskApiService;
import com.gic.haoban.manage.service.pojo.bo.content.GroupMessageInfoBo;
import com.gic.haoban.manage.service.service.StaffService;
import com.gic.haoban.manage.service.service.WxEnterpriseService;
import com.gic.haoban.manage.service.service.content.GroupMessageService;
import com.gic.haoban.manage.service.service.content.MaterialReportService;
import com.gic.haoban.manage.service.task.RouterConstant;
......@@ -39,6 +40,8 @@ public class QywxGroupMsgTaskApiServiceImpl implements QywxGroupMsgTaskApiServic
private MaterialReportService materialReportService;
@Autowired
private StaffService staffService;
@Autowired
private WxEnterpriseService wxEnterpriseService;
@Override
public ServiceResponse<Void> groupMsgTaskJob(String params) {
......@@ -120,7 +123,12 @@ public class QywxGroupMsgTaskApiServiceImpl implements QywxGroupMsgTaskApiServic
return ServiceResponse.success();
}
for (String enterpriseId : enterpriseIds) {
List<String> wxEnterpriseIds = wxEnterpriseService.queryWxEnterpriseWithEnterpriseId(enterpriseId);
if (CollectionUtils.isEmpty(wxEnterpriseIds)) {
}
List<String> staffIds = staffService.queryStaffIdsWithEnterpriseId(enterpriseId);
if (CollectionUtils.isEmpty(staffIds)) {
log.info("企业 {} 不存在成员", enterpriseId);
......
......@@ -508,7 +508,7 @@
<select id="queryWxEnterpriseByEnterpriseId" resultType="java.lang.String">
select
a.enterprise_id enterpriseId
a.wx_enterprise_id wxEnterpriseId
from tab_haoban_wx_enterprise_related a
inner join tab_haoban_wx_enterprise b on a.wx_enterprise_id = b.wx_enterprise_id
where a.status_flag = 1 and b.status_flag = 1
......
import com.gic.haoban.manage.api.enums.content.MaterialReportType;
import com.gic.haoban.manage.api.service.content.task.QywxGroupMsgTaskApiService;
import com.gic.haoban.manage.service.service.content.MaterialReportService;
import org.junit.Test;
import org.junit.runner.RunWith;
......@@ -22,6 +23,8 @@ public class MaterialReportServiceTest {
}
@Autowired
private MaterialReportService materialReportService;
@Autowired
private QywxGroupMsgTaskApiService qywxGroupMsgTaskApiService;
String eid = "ff8080815dacd3a2015dacd3ef5c0000";
String wxEid = "ca66a01b79474c40b3e7c7f93daf1a3b";
......@@ -33,4 +36,9 @@ public class MaterialReportServiceTest {
materialReportService.handlerMaterialReport(eid, staffId, MaterialReportType.WEEK.getCode());
materialReportService.handlerMaterialReport(eid, staffId, MaterialReportType.MONTH.getCode());
}
@Test
public void weekReport(){
qywxGroupMsgTaskApiService.handlerMaterialWeekReport("");
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment