|
@@ -1,5 +1,7 @@
|
|
|
package org.jeecg.modules.smscheck.controller;
|
|
package org.jeecg.modules.smscheck.controller;
|
|
|
|
|
|
|
|
|
|
+import cn.hutool.core.lang.Dict;
|
|
|
|
|
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
@@ -8,6 +10,7 @@ import io.swagger.annotations.ApiOperation;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.jeecg.common.api.vo.Result;
|
|
import org.jeecg.common.api.vo.Result;
|
|
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
|
|
|
|
+import org.jeecg.common.constant.CommonConstant;
|
|
|
import org.jeecg.common.system.base.controller.JeecgController;
|
|
import org.jeecg.common.system.base.controller.JeecgController;
|
|
|
import org.jeecg.common.system.query.QueryGenerator;
|
|
import org.jeecg.common.system.query.QueryGenerator;
|
|
|
import org.jeecg.modules.smscheck.entity.SmsCheckCustomerInfo;
|
|
import org.jeecg.modules.smscheck.entity.SmsCheckCustomerInfo;
|
|
@@ -153,4 +156,50 @@ public class SmsCheckCustomerInfoController extends JeecgController<SmsCheckCust
|
|
|
return super.importExcel(request, response, SmsCheckCustomerInfo.class);
|
|
return super.importExcel(request, response, SmsCheckCustomerInfo.class);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 通过id查询 稽核统计数
|
|
|
|
|
+ *
|
|
|
|
|
+ * @param id 主键
|
|
|
|
|
+ * @return 数据
|
|
|
|
|
+ */
|
|
|
|
|
+ //@AutoLog(value = "客户信息-通过id查询")
|
|
|
|
|
+ @ApiOperation(value="客户信息-通过id查询 稽核统计数", notes="客户信息-通过id查询 稽核统计数")
|
|
|
|
|
+ @GetMapping(value = "/count")
|
|
|
|
|
+ public Result<Dict> count(@RequestParam(name="id") String id) {
|
|
|
|
|
+ Dict dict = Dict.create();
|
|
|
|
|
+ // 客户总数
|
|
|
|
|
+ long count = smsCheckCustomerInfoService.count(new LambdaQueryWrapper<SmsCheckCustomerInfo>()
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getTaskId, id)
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getDelFlag, CommonConstant.DEL_FLAG_0));
|
|
|
|
|
+ // 未处理数
|
|
|
|
|
+ long undoCount = smsCheckCustomerInfoService.count(new LambdaQueryWrapper<SmsCheckCustomerInfo>()
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getTaskId, id)
|
|
|
|
|
+ .in(SmsCheckCustomerInfo::getCheckState, Arrays.asList(0,1))
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getDelFlag, CommonConstant.DEL_FLAG_0));
|
|
|
|
|
+
|
|
|
|
|
+ // 待稽核数
|
|
|
|
|
+ long uncheckCount = smsCheckCustomerInfoService.count(new LambdaQueryWrapper<SmsCheckCustomerInfo>()
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getTaskId, id)
|
|
|
|
|
+ .in(SmsCheckCustomerInfo::getCheckState, Arrays.asList(2,4))
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getDelFlag, CommonConstant.DEL_FLAG_0));
|
|
|
|
|
+ // 待整改数
|
|
|
|
|
+ long checkedCount = smsCheckCustomerInfoService.count(new LambdaQueryWrapper<SmsCheckCustomerInfo>()
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getTaskId, id)
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getCheckState, 3)
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getDelFlag, CommonConstant.DEL_FLAG_0));
|
|
|
|
|
+ // 稽核完成数
|
|
|
|
|
+ long passedCount = smsCheckCustomerInfoService.count(new LambdaQueryWrapper<SmsCheckCustomerInfo>()
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getTaskId, id)
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getCheckState, 5)
|
|
|
|
|
+ .eq(SmsCheckCustomerInfo::getDelFlag, CommonConstant.DEL_FLAG_0));
|
|
|
|
|
+
|
|
|
|
|
+ dict.put("count", count);
|
|
|
|
|
+ dict.put("undoCount", undoCount);
|
|
|
|
|
+ dict.put("uncheckCount", uncheckCount);
|
|
|
|
|
+ dict.put("checkedCount", checkedCount);
|
|
|
|
|
+ dict.put("passedCount", passedCount);
|
|
|
|
|
+
|
|
|
|
|
+ return Result.OK(dict);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|