|
|
@ -3,6 +3,7 @@ package cn.jyjz.xiaoyao.ocr.controller;
|
|
|
|
import java.io.BufferedReader;
|
|
|
|
import java.io.BufferedReader;
|
|
|
|
import java.io.IOException;
|
|
|
|
import java.io.IOException;
|
|
|
|
import java.io.InputStreamReader;
|
|
|
|
import java.io.InputStreamReader;
|
|
|
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
import java.util.HashMap;
|
|
|
|
import java.util.HashMap;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.Map;
|
|
|
|
import java.util.Map;
|
|
|
@ -20,6 +21,7 @@ import cn.jyjz.xiaoyao.ocr.util.DataUtil;
|
|
|
|
import cn.jyjz.xiaoyao.ocr.util.SearchConfigEnum;
|
|
|
|
import cn.jyjz.xiaoyao.ocr.util.SearchConfigEnum;
|
|
|
|
import cn.jyjz.xiaoyao.ocr.util.SearchParaFormatting;
|
|
|
|
import cn.jyjz.xiaoyao.ocr.util.SearchParaFormatting;
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
import io.swagger.annotations.ApiImplicitParam;
|
|
|
|
import io.swagger.annotations.ApiImplicitParam;
|
|
|
@ -265,7 +267,6 @@ public class OcrPictureController extends BaseController {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
QueryWrapper<OcrPicture> queryWrapper = new QueryWrapper<>();
|
|
|
|
QueryWrapper<OcrPicture> queryWrapper = new QueryWrapper<>();
|
|
|
|
|
|
|
|
|
|
|
|
String search_month = req.getParameter("search_month");
|
|
|
|
String search_month = req.getParameter("search_month");
|
|
|
@ -295,8 +296,8 @@ public class OcrPictureController extends BaseController {
|
|
|
|
|
|
|
|
|
|
|
|
//提报人模糊搜索
|
|
|
|
//提报人模糊搜索
|
|
|
|
String upUserName = req.getParameter("upUserName");
|
|
|
|
String upUserName = req.getParameter("upUserName");
|
|
|
|
if(StringUtils.isNotBlank(upUserName)){
|
|
|
|
if (StringUtils.isNotBlank(upUserName)) {
|
|
|
|
queryWrapper.like("upName",upUserName);
|
|
|
|
queryWrapper.like("upName", upUserName);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//根据参数枚举,获取检索参数,并映射为数据库的字段的key-v map
|
|
|
|
//根据参数枚举,获取检索参数,并映射为数据库的字段的key-v map
|
|
|
@ -313,6 +314,34 @@ public class OcrPictureController extends BaseController {
|
|
|
|
queryWrapper.eq("tenant_id", tenantId);
|
|
|
|
queryWrapper.eq("tenant_id", tenantId);
|
|
|
|
Page<OcrPicture> page = new Page<OcrPicture>(pageNo, pageSize);
|
|
|
|
Page<OcrPicture> page = new Page<OcrPicture>(pageNo, pageSize);
|
|
|
|
IPage<OcrPicture> pageList = ocrPictureService.page(page, queryWrapper);
|
|
|
|
IPage<OcrPicture> pageList = ocrPictureService.page(page, queryWrapper);
|
|
|
|
|
|
|
|
List<OcrPicture> ocrPictures = pageList.getRecords();
|
|
|
|
|
|
|
|
List<OcrPicture> ocrPicturesNew = new ArrayList<>();
|
|
|
|
|
|
|
|
for (OcrPicture ocrPictureOne : ocrPictures) {
|
|
|
|
|
|
|
|
LambdaQueryWrapper<OcrTaskchildPicture> ocrTaskchildPictureLambdaQueryWrapper = new LambdaQueryWrapper<>();
|
|
|
|
|
|
|
|
ocrTaskchildPictureLambdaQueryWrapper.eq(OcrTaskchildPicture::getId, ocrPictureOne.getTaskchildpictureid());
|
|
|
|
|
|
|
|
OcrTaskchildPicture ocrTaskchildPicture = ocrTaskchildPictureService.getOne(ocrTaskchildPictureLambdaQueryWrapper);
|
|
|
|
|
|
|
|
if(ocrTaskchildPicture != null && ocrTaskchildPicture.getStates() != null){
|
|
|
|
|
|
|
|
switch (ocrTaskchildPicture.getStates()) {
|
|
|
|
|
|
|
|
case 1:
|
|
|
|
|
|
|
|
ocrPictureOne.setField16("未提交");
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 2:
|
|
|
|
|
|
|
|
ocrPictureOne.setField16("审批中");
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 3:
|
|
|
|
|
|
|
|
ocrPictureOne.setField16("审批通过");
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 5:
|
|
|
|
|
|
|
|
ocrPictureOne.setField16("审批不通过");
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
|
|
|
ocrPictureOne.setField16("未知状态");
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
ocrPicturesNew.add(ocrPictureOne);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
pageList.setRecords(ocrPicturesNew);
|
|
|
|
|
|
|
|
|
|
|
|
return ResultVoUtil.success(pageList);
|
|
|
|
return ResultVoUtil.success(pageList);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -403,7 +432,7 @@ public class OcrPictureController extends BaseController {
|
|
|
|
@RequestParam(name = "pictureId", required = false) String pictureId,
|
|
|
|
@RequestParam(name = "pictureId", required = false) String pictureId,
|
|
|
|
HttpServletRequest req) {
|
|
|
|
HttpServletRequest req) {
|
|
|
|
UserToken userToken = this.userTokenService.getUserToken(RequestBaseUtil.getToken(req));
|
|
|
|
UserToken userToken = this.userTokenService.getUserToken(RequestBaseUtil.getToken(req));
|
|
|
|
OcrPicture result = ocrPictureService.getPackagePictureInfo(checkDuplicateId, pictureId,userToken);
|
|
|
|
OcrPicture result = ocrPictureService.getPackagePictureInfo(checkDuplicateId, pictureId, userToken);
|
|
|
|
return ResultVoUtil.success(result);
|
|
|
|
return ResultVoUtil.success(result);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|