|
|
@@ -21,9 +21,7 @@ import org.jeecg.common.system.query.QueryGenerator;
|
|
|
import org.jeecg.common.system.vo.LoginUser;
|
|
|
import org.jeecg.config.shiro.ShiroRealm;
|
|
|
import org.jeecg.modules.smscheck.configs.CheckStateCode;
|
|
|
-import org.jeecg.modules.smscheck.entity.SmsCheckCustomerInfo;
|
|
|
-import org.jeecg.modules.smscheck.entity.SmsCheckCustomerInfoLog;
|
|
|
-import org.jeecg.modules.smscheck.entity.SmsCheckWorkLog;
|
|
|
+import org.jeecg.modules.smscheck.entity.*;
|
|
|
import org.jeecg.modules.smscheck.service.ISmsCheckCustomerInfoLogService;
|
|
|
import org.jeecg.modules.smscheck.service.ISmsCheckCustomerInfoService;
|
|
|
import org.jeecg.modules.smscheck.service.ISmsCheckWorkLogService;
|
|
|
@@ -31,6 +29,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
import org.springframework.web.servlet.ModelAndView;
|
|
|
|
|
|
+import javax.annotation.Resource;
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
import java.util.Arrays;
|
|
|
@@ -56,6 +55,8 @@ public class SmsCheckCustomerInfoController extends JeecgController<SmsCheckCust
|
|
|
private ISmsCheckCustomerInfoLogService infoLogService;
|
|
|
@Autowired
|
|
|
private ISysBaseAPI sysBaseAPI;
|
|
|
+ @Autowired
|
|
|
+ private ISmsCheckCustomerInfoService smsCheckCustomerInfoService;
|
|
|
|
|
|
/**
|
|
|
* 分页列表查询
|
|
|
@@ -377,5 +378,44 @@ public class SmsCheckCustomerInfoController extends JeecgController<SmsCheckCust
|
|
|
return Result.OK("添加成功!");
|
|
|
}
|
|
|
|
|
|
+ @PostMapping(value = "/checkInfo/warning/count")
|
|
|
+ public Result<String> checkInfoWarningCount(@RequestBody SmsCheckCustomerInfo smsCheckCustomerInfo) {
|
|
|
+ LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
|
|
+ String workNo = sysUser.getWorkNo();
|
|
|
+ if (StringUtils.isEmpty(workNo)){
|
|
|
+ return Result.error("该用户不存在");
|
|
|
+ }
|
|
|
+ smsCheckCustomerInfo.setStaffNo(workNo);
|
|
|
+ Integer count = smsCheckCustomerInfoService.checkInfoWarningCount(smsCheckCustomerInfo);
|
|
|
+ if (count == null){
|
|
|
+ return Result.error("该用户没有相关信息");
|
|
|
+ }
|
|
|
+ return Result.OK(count.toString());
|
|
|
+ }
|
|
|
+
|
|
|
+ @PostMapping(value = "/checkInfo/warning/all/count")
|
|
|
+ public Result<String> checkInfoWarningCountAll(@RequestBody SmsCheckCustomerInfo smsCheckCustomerInfo) {
|
|
|
+ smsCheckCustomerInfo.setCheckState(CheckStateCode.CHECK_STSTE_0);
|
|
|
+ Integer count0 = smsCheckCustomerInfoService.checkInfoWarningCount(smsCheckCustomerInfo);
|
|
|
+ smsCheckCustomerInfo.setCheckState(CheckStateCode.CHECK_STSTE_1);
|
|
|
+ Integer count1 = smsCheckCustomerInfoService.checkInfoWarningCount(smsCheckCustomerInfo);
|
|
|
+ smsCheckCustomerInfo.setCheckState(CheckStateCode.CHECK_STSTE_4);
|
|
|
+ Integer count4 = smsCheckCustomerInfoService.checkInfoWarningCount(smsCheckCustomerInfo);
|
|
|
+ SmsCheckCustomerInfoVo smsCheckCustomerInfoVo = new SmsCheckCustomerInfoVo();
|
|
|
+ smsCheckCustomerInfoVo.setCheckState0(count0);
|
|
|
+ smsCheckCustomerInfoVo.setCheckState1(count1);
|
|
|
+ smsCheckCustomerInfoVo.setCheckState4(count4);
|
|
|
+ return Result.object(smsCheckCustomerInfoVo);
|
|
|
+ }
|
|
|
|
|
|
+ @PostMapping(value = "/checkInfo/warning/count/time")
|
|
|
+ public Result<String> checkInfoWarningCountTime(@RequestBody SmsCheckCustomerInfo smsCheckCustomerInfo) {
|
|
|
+ List<SmsCheckTaskVo> smsCheckTaskVos = smsCheckCustomerInfoService.checkInfoWarningCountTime(smsCheckCustomerInfo);
|
|
|
+ return Result.ok(smsCheckTaskVos);
|
|
|
+ }
|
|
|
+ @PostMapping(value = "/checkInfo/warning/count/staff")
|
|
|
+ public Result<String> checkInfoWarningCountStaff(@RequestBody SmsCheckCustomerInfo smsCheckCustomerInfo) {
|
|
|
+ List<SmsCheckTaskVo> smsCheckTaskVos = smsCheckCustomerInfoService.checkInfoWarningCountStaff(smsCheckCustomerInfo);
|
|
|
+ return Result.ok(smsCheckTaskVos);
|
|
|
+ }
|
|
|
}
|