Merge remote-tracking branch 'origin/master'

pull/1/head
DELL 2 years ago
commit 7e630c73b3

@ -169,6 +169,10 @@ public class FlowTaskController extends BaseController {
return ResultVoUtil.error("存在已经审批的任务。");
}
if(!this.ocrTaskchildPictureService.validateBoole(formid)){
return ResultVoUtil.error("存在未判真假数据。");
}
//TODO 判断taskid是否为非法空置、taskid是否存在
//判断当前任务是否存在历史任务--暂时不做,生成任务时直接保存历史任务的审批工具中
@ -248,11 +252,32 @@ public class FlowTaskController extends BaseController {
//租户主键,由前端页面传送
String tenantId = request.getHeader("X-Tenant-Id");
String taskid = request.getParameter("taskid");
String states = request.getParameter("states");
String fromprojectid = request.getParameter("fromprojectid");
String fromuserid = request.getParameter("fromuserid");
String fromplanid = request.getParameter("fromplanid");
if(org.apache.commons.lang3.StringUtils.isBlank(tenantId)){
return ResultVoUtil.error("租户主键不能为空");
}
if(StringUtils.isNotBlank(taskid)){
searchQuery.addEqual("taskid",taskid);
}
if(StringUtils.isNotBlank(states)){
searchQuery.addEqual("states",states);
}
if(StringUtils.isNotBlank(fromprojectid)){
searchQuery.addEqual("fromprojectid",fromprojectid);
}
if(StringUtils.isNotBlank(fromuserid)){
searchQuery.addEqual("fromuserid",fromuserid);
}
if(StringUtils.isNotBlank(fromplanid)){
searchQuery.addEqual("fromplanid",fromplanid);
}
//查询判过真假的
searchQuery.addNotEqual("iztrueorfalse",null);
User user = this.userService.getSessionUser(request);
if(user.isUserIsSys(xiaoyaoConfig.getWebconfig().getSysLoginUser().split(","))){
@ -262,7 +287,7 @@ public class FlowTaskController extends BaseController {
//如果assigneeId 为空查询发起流程,否则查询待办流程
if(StringUtils.isNotBlank(assigneeId) && assigneeId.equals(user.getId().toString())){
searchQuery.addEqual("assignee",user.getLoginname());
searchQuery.addEqual("states",SystemConstantsOa.OA_STATUS_TYPE_ING.toString());
// searchQuery.addEqual("states",SystemConstantsOa.OA_STATUS_TYPE_ING.toString());
}else{
searchQuery.addEqual("createuser",user.getLoginname());
}
@ -450,4 +475,23 @@ public class FlowTaskController extends BaseController {
//return ResultVoUtil.success();
}
/**
*
* @return
*/
@ApiOperation(value="重置流程流程", notes="重置流程流程")
@ApiImplicitParams({
@ApiImplicitParam(paramType = "header", name = "X-Tenant-Id", value = "租户主键,用户登录时的信息“tenantList”中获得。", dataType = "String", required = true),
@ApiImplicitParam(paramType = "path",name = "buessinessno", value = "业务编码", required = true)
})
@GetMapping("/historyTask")
@ResponseBody
public ResultVo historyTask(HttpServletRequest request){
String fromid = request.getParameter("fromid");
String taskid = request.getParameter("buessinessno");
return flowTaskService.removeTask(fromid,taskid);
//return ResultVoUtil.success();
}
}

@ -90,23 +90,23 @@ public class OcrPackagetaskController extends BaseController{
public ResultVo<IPage<OcrPackagetask>> queryPageList(OcrPackagetask ocrPackagetask,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
@RequestParam(name="packagename", required = false) String packagename,
HttpServletRequest request) {
if(StringUtils.isBlank(packagename)){
return ResultVoUtil.error("请输入您需要搜索的内容");
}
//租户主键,由前端页面传送
String tenantId = request.getHeader("X-Tenant-Id");
if(StringUtils.isBlank(tenantId)){
return ResultVoUtil.error("租户主键不能为空");
}
String packageName = request.getParameter("packagename");
//获取当前登录人
UserToken userToken = this.userTokenService.getUserToken(RequestBaseUtil.getToken(request));
QueryWrapper<OcrPackagetask> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("tenant_id",tenantId);
queryWrapper.like("packagename",packagename);
if(StringUtils.isNotBlank(packageName)){
queryWrapper.like("packagename",packageName);
}
Page<OcrPackagetask> page = new Page<OcrPackagetask>(pageNo, pageSize);
IPage<OcrPackagetask> pageList = ocrPackagetaskService.page(page, queryWrapper);
return ResultVoUtil.success(pageList);

@ -41,6 +41,8 @@ public interface OcrTaskchildPictureService extends BaseService<OcrTaskchildPict
*/
public boolean validateApprove(String[] formid);
public boolean validateBoole(String[] formid);
/**
*
* @param formid

@ -12,6 +12,7 @@ import cn.jyjz.xiaoyao.ocr.dataobject.OcrPicture;
import cn.jyjz.xiaoyao.ocr.dataobject.OcrTaskchildPicture;
import cn.jyjz.xiaoyao.ocr.service.OcrPictureService;
import cn.jyjz.xiaoyao.ocr.service.OcrTaskchildPictureService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
@ -25,10 +26,11 @@ import lombok.extern.slf4j.Slf4j;
import javax.annotation.Resource;
import java.util.*;
import java.util.stream.Collectors;
/**
*
*/
*
*/
@Service("ocrTaskchildPictureService")
@Slf4j
public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchildPictureMybatisDao, OcrTaskchildPicture> implements OcrTaskchildPictureService {
@ -40,35 +42,37 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
@Resource
IFlowTaskService iFlowTaskService;
/**
*
*
* @param childpictureids
* @return
*/
public ResultVo trueorfalse(String childpictureids, String packageid, String iztrueorfalse, String judgeid, String judgedesc){
public ResultVo trueorfalse(String childpictureids, String packageid, String iztrueorfalse, String judgeid, String judgedesc) {
String[] cps = childpictureids.split(",");
List<OcrPicture> saveList =new ArrayList<>();
List<OcrPicture> saveList = new ArrayList<>();
StringBuffer historyPname = new StringBuffer();
StringBuffer taskType = new StringBuffer();
for(String childpictureid:cps){
OcrTaskchildPicture old = this.listPicturePackageId(childpictureid,Long.parseLong(packageid));
for (String childpictureid : cps) {
OcrTaskchildPicture old = this.listPicturePackageId(childpictureid, Long.parseLong(packageid));
//如果是历史图片,不允许进行设置
if(old.isIzHistory()){
if(historyPname.length() > 0){
if (old.isIzHistory()) {
if (historyPname.length() > 0) {
historyPname.append("," + old.getOcrPicture().getImgname());
}else{
} else {
historyPname.append(old.getOcrPicture().getImgname());
}
}
if(old.getStates().intValue() == 3 || old.getStates().intValue() == 5) {
if(taskType.length() > 0){
if (old.getStates().intValue() == 3 || old.getStates().intValue() == 5) {
if (taskType.length() > 0) {
taskType.append("," + old.getOcrPicture().getImgname());
}else{
} else {
taskType.append(old.getOcrPicture().getImgname());
}
}
@ -82,39 +86,38 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
saveList.add(ocrPicture);
}
if(StringUtils.isNotBlank(historyPname.toString())){
if (StringUtils.isNotBlank(historyPname.toString())) {
return ResultVoUtil.error(historyPname.toString() + "为历史数据,不能标记。");
}
else if(StringUtils.isNotBlank(taskType.toString())){
return ResultVoUtil.error( taskType.toString() + "已经审批,不能标记。");
} else if (StringUtils.isNotBlank(taskType.toString())) {
return ResultVoUtil.error(taskType.toString() + "已经审批,不能标记。");
}
return this.ocrPictureService.updateBatchById(saveList)?ResultVoUtil.success():ResultVoUtil.error();
return this.ocrPictureService.updateBatchById(saveList) ? ResultVoUtil.success() : ResultVoUtil.error();
}
public ResultVo clearmark(String childpictureids, String packageid){
public ResultVo clearmark(String childpictureids, String packageid) {
String[] cps = childpictureids.split(",");
List<OcrPicture> saveList =new ArrayList<>();
List<OcrPicture> saveList = new ArrayList<>();
StringBuffer historyPname = new StringBuffer();
StringBuffer taskType = new StringBuffer();
for(String childpictureid:cps){
OcrTaskchildPicture old = this.listPicturePackageId(childpictureid,Long.parseLong(packageid));
for (String childpictureid : cps) {
OcrTaskchildPicture old = this.listPicturePackageId(childpictureid, Long.parseLong(packageid));
//如果是历史图片,不允许进行设置
if(old.isIzHistory()){
if(historyPname.length() > 0){
if (old.isIzHistory()) {
if (historyPname.length() > 0) {
historyPname.append("," + old.getOcrPicture().getImgname());
}else{
} else {
historyPname.append(old.getOcrPicture().getImgname());
}
}
if(old.getStates().intValue() == 3 || old.getStates().intValue() == 5) {
if(taskType.length() > 0){
if (old.getStates().intValue() == 3 || old.getStates().intValue() == 5) {
if (taskType.length() > 0) {
taskType.append("," + old.getOcrPicture().getImgname());
}else{
} else {
taskType.append(old.getOcrPicture().getImgname());
}
}
@ -128,26 +131,26 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
saveList.add(ocrPicture);
}
if(StringUtils.isNotBlank(historyPname.toString())){
if (StringUtils.isNotBlank(historyPname.toString())) {
return ResultVoUtil.error(historyPname.toString() + "为历史数据,不能清除标记。");
}
else if(StringUtils.isNotBlank(taskType.toString())){
return ResultVoUtil.error( taskType.toString() + "已经审批,不能清除标记。");
} else if (StringUtils.isNotBlank(taskType.toString())) {
return ResultVoUtil.error(taskType.toString() + "已经审批,不能清除标记。");
}
return this.ocrPictureService.updateBatchById(saveList)?ResultVoUtil.success():ResultVoUtil.error();
return this.ocrPictureService.updateBatchById(saveList) ? ResultVoUtil.success() : ResultVoUtil.error();
}
/**
*
*
* @param childpictureid
* @return
*/
public boolean pass(String childpictureid,OcrTaskchildPicture ocrTaskchildPicture){
public boolean pass(String childpictureid, OcrTaskchildPicture ocrTaskchildPicture) {
OcrTaskchildPicture old = this.getById(childpictureid);
//判断当前图片是否在任务包中,如果不在任务保重,不允许设置图片真假
if(!old.getPackageid().equals(ocrTaskchildPicture.getPackageid())){
if (!old.getPackageid().equals(ocrTaskchildPicture.getPackageid())) {
return false;
}
//
@ -169,21 +172,22 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param formid
* @param userToken
* @return
*/
public boolean validateAssignee(String[] formid,UserToken userToken){
public boolean validateAssignee(String[] formid, UserToken userToken) {
QueryWrapper queryWrapper = new QueryWrapper();
queryWrapper.in("ID",formid);
queryWrapper.in("ID", formid);
List<OcrTaskchildPicture> list = this.ocrtaskchildpicturemybatisdao.selectList(queryWrapper);
//目前没有做其他信息返回,如果需要再做修改
for(OcrTaskchildPicture ocrTaskchildPicture:list){
for (OcrTaskchildPicture ocrTaskchildPicture : list) {
//判断审批人是否为当前登录用户
if(userToken.getLoginname().equals(ocrTaskchildPicture.getAssignee())){
if (userToken.getLoginname().equals(ocrTaskchildPicture.getAssignee())) {
}else{
} else {
return false;
}
}
@ -192,29 +196,47 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param formid
* @return
*/
public boolean validateApprove(String[] formid){
public boolean validateApprove(String[] formid) {
QueryWrapper queryWrapper = new QueryWrapper();
queryWrapper.in("ID",formid);
queryWrapper.in("ID", formid);
List<OcrTaskchildPicture> list = this.ocrtaskchildpicturemybatisdao.selectList(queryWrapper);
//目前没有做其他信息返回,如果需要再做修改
for(OcrTaskchildPicture ocrTaskchildPicture:list){
for (OcrTaskchildPicture ocrTaskchildPicture : list) {
//判断当前审批状态为拒绝或者通过的,不允许再做审批
if(ocrTaskchildPicture.getStates().intValue() == SystemConstantsOa.OA_STATUS_TYPE_END
|| ocrTaskchildPicture.getStates().intValue() == SystemConstantsOa.OA_STATUS_TYPE_REFUSE ){
if (ocrTaskchildPicture.getStates().intValue() == SystemConstantsOa.OA_STATUS_TYPE_END
|| ocrTaskchildPicture.getStates().intValue() == SystemConstantsOa.OA_STATUS_TYPE_REFUSE) {
return false;
}else{
} else {
}
}
return true;
}
/**
*
*
* @param formid
* @return
*/
public boolean validateBoole(String[] formid) {
QueryWrapper queryWrapper = new QueryWrapper();
queryWrapper.in("ID", formid);
List<OcrTaskchildPicture> list = this.ocrtaskchildpicturemybatisdao.selectList(queryWrapper);
List<OcrPicture> pictures = ocrPictureService.list(new LambdaQueryWrapper<OcrPicture>().eq(OcrPicture::getId, list.stream().map(OcrTaskchildPicture::getPictureid).collect(Collectors.toList())).isNull(OcrPicture::getIztrueorfalse));
if (pictures.size() > 1) {
return false;
}
return true;
}
@Override
public List<OcrTaskchildPicture> listAll(String tenantId, String createUser, QueryWrapper queryWrapper){
public List<OcrTaskchildPicture> listAll(String tenantId, String createUser, QueryWrapper queryWrapper) {
long count = this.count(queryWrapper);
@ -222,46 +244,49 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
Page<OcrTaskchildPicture> page = new Page<>(1, count);
page.setMaxLimit(count);
IPage<OcrTaskchildPicture> iPage = this.page(page,queryWrapper);
IPage<OcrTaskchildPicture> iPage = this.page(page, queryWrapper);
return iPage.getRecords();
}
/**
*
*
* @param taskids
* @return
*/
public boolean markPoint(List<Long> taskids){
public boolean markPoint(List<Long> taskids) {
UpdateWrapper updateWrapper = new UpdateWrapper();
updateWrapper.set("HAVEPOINTS",1);
updateWrapper.in("ID",taskids);
updateWrapper.set("HAVEPOINTS", 1);
updateWrapper.in("ID", taskids);
return this.update(updateWrapper);
}
/**
*
*
* @param packageid
* @return
*/
public List<OcrTaskchildPicture> markpoint(String packageid){
public List<OcrTaskchildPicture> markpoint(String packageid) {
QueryWrapper<OcrTaskchildPicture> queryWrapperNew = new QueryWrapper<>();
queryWrapperNew.eq("HAVEPOINTS","1");
queryWrapperNew.eq("PACKAGEID",packageid);
queryWrapperNew.eq("HAVEPOINTS", "1");
queryWrapperNew.eq("PACKAGEID", packageid);
List<OcrTaskchildPicture> list = this.ocrtaskchildpicturemybatisdao.selectList(queryWrapperNew);
this.formatTask(list,packageid);
this.formatTask(list, packageid);
return list;
}
/**
*
*
* @param fromid
* @return
*/
public OcrTaskchildPicture listPicturePackageId(String fromid,Long packageid){
public OcrTaskchildPicture listPicturePackageId(String fromid, Long packageid) {
OcrTaskchildPicture ocrTaskchildPicture = this.getById(fromid);
//查询图片对象
OcrPicture ocrPicture = this.ocrPictureService.selectDtoById(ocrTaskchildPicture.getPictureid());
@ -273,15 +298,15 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
// ocrTaskchildPicture.setIzHistory(listPictureids.contains(ocrPicture.getPictureid())?false:true);
//如果当前任务的任务包主键一致,说明不是历史数据,如果不一致,说明是历史数据
if(packageid.toString().equals(ocrTaskchildPicture.getPackageid().toString())){
if (packageid.toString().equals(ocrTaskchildPicture.getPackageid().toString())) {
ocrTaskchildPicture.setIzHistory(false);
}else{
} else {
ocrTaskchildPicture.setIzHistory(true);
}
//查询审批流节点信息
List<Task> taskList = iFlowTaskService.nowRunTask(ocrTaskchildPicture.getProcessinstanceid(),ocrTaskchildPicture.getProcessdefinitionid());
if(null != taskList && !taskList.isEmpty()) {
List<Task> taskList = iFlowTaskService.nowRunTask(ocrTaskchildPicture.getProcessinstanceid(), ocrTaskchildPicture.getProcessdefinitionid());
if (null != taskList && !taskList.isEmpty()) {
ocrTaskchildPicture.setTaskId(taskList.get(0).getId());
}
@ -295,62 +320,63 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
return ocrTaskchildPicture;
}
/**
*
*
* @param taskchildpictureid
* @param queryWrapper
* @return
*/
public IPage<OcrTaskchildPicture> listByPackageId(String taskchildpictureid, ParamterPage paramterPage,QueryWrapper queryWrapper,String orderbyname,String orderbyvalue,String packageid,String tenantId ){
public IPage<OcrTaskchildPicture> listByPackageId(String taskchildpictureid, ParamterPage paramterPage, QueryWrapper queryWrapper, String orderbyname, String orderbyvalue, String packageid, String tenantId) {
Page<OcrTaskchildPicture> page = new Page<>(paramterPage.getStart(), paramterPage.getPagesize());
//当前显示的任务对象
OcrTaskchildPicture mainOcrTaskchildPicture = this.getById(taskchildpictureid);
//判断当前图片是否为历史图片
if(!packageid.equals(mainOcrTaskchildPicture.getPackageid().toString())){
if (!packageid.equals(mainOcrTaskchildPicture.getPackageid().toString())) {
QueryWrapper<OcrTaskchildPicture> queryWrapperNew = new QueryWrapper<>();
queryWrapperNew.eq("TENANTID",tenantId);
queryWrapperNew.eq("PACKAGEID",packageid);
queryWrapperNew.eq("TENANTID", tenantId);
queryWrapperNew.eq("PACKAGEID", packageid);
//查询非历史图片存在的集合
IPage<OcrTaskchildPicture> pageNew = this.selectSearchListPage(paramterPage,queryWrapperNew);
IPage<OcrTaskchildPicture> pageNew = this.selectSearchListPage(paramterPage, queryWrapperNew);
//如果是历史图片,从非历史图片存在的集合中随机选取一个
if(!pageNew.getRecords().isEmpty()){
if (!pageNew.getRecords().isEmpty()) {
mainOcrTaskchildPicture = pageNew.getRecords().get(0);
}
}
//不包含当前选中的图片
queryWrapper.ne("ID",taskchildpictureid);
queryWrapper.ne("ID", taskchildpictureid);
queryWrapper.eq("TENANTID",tenantId);
if(StringUtils.isNotBlank(orderbyname) && orderbyname.equals("asc")){
if(StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("pictureResult")){
queryWrapper.orderByAsc("FIELD(PICTUREID,"+ mainOcrTaskchildPicture.getOcpictureid() +")");
}else if(StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("fromuptime")){
queryWrapper.eq("TENANTID", tenantId);
if (StringUtils.isNotBlank(orderbyname) && orderbyname.equals("asc")) {
if (StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("pictureResult")) {
queryWrapper.orderByAsc("FIELD(PICTUREID," + mainOcrTaskchildPicture.getOcpictureid() + ")");
} else if (StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("fromuptime")) {
queryWrapper.orderByAsc("FROMUPTIME");
}
}else if(StringUtils.isNotBlank(orderbyname) && orderbyname.equals("desc")){
} else if (StringUtils.isNotBlank(orderbyname) && orderbyname.equals("desc")) {
if(StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("pictureResult")){
queryWrapper.orderByDesc("FIELD(PICTUREID,"+ mainOcrTaskchildPicture.getOcpictureid() +")");
}else if(StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("fromuptime")){
if (StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("pictureResult")) {
queryWrapper.orderByDesc("FIELD(PICTUREID," + mainOcrTaskchildPicture.getOcpictureid() + ")");
} else if (StringUtils.isNotBlank(orderbyvalue) && orderbyvalue.equals("fromuptime")) {
queryWrapper.orderByDesc("FROMUPTIME");
}
}
queryWrapper.in("PICTUREID",mainOcrTaskchildPicture.getOcpictureid().split(","));
queryWrapper.in("PICTUREID", mainOcrTaskchildPicture.getOcpictureid().split(","));
IPage<OcrTaskchildPicture> iPage = this.page(page,queryWrapper);
IPage<OcrTaskchildPicture> iPage = this.page(page, queryWrapper);
this.formatTask(iPage.getRecords(),packageid);
this.formatTask(iPage.getRecords(), packageid);
return iPage;
@ -358,15 +384,16 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param list
* @param packageid
*/
private void formatTask(List<OcrTaskchildPicture> list,String packageid){
for(OcrTaskchildPicture ocrTaskchildPicture:list){
private void formatTask(List<OcrTaskchildPicture> list, String packageid) {
for (OcrTaskchildPicture ocrTaskchildPicture : list) {
//查询审批流节点信息
List<Task> taskList = iFlowTaskService.nowRunTask(ocrTaskchildPicture.getProcessinstanceid(),ocrTaskchildPicture.getProcessdefinitionid());
if(null != taskList && !taskList.isEmpty()) {
List<Task> taskList = iFlowTaskService.nowRunTask(ocrTaskchildPicture.getProcessinstanceid(), ocrTaskchildPicture.getProcessdefinitionid());
if (null != taskList && !taskList.isEmpty()) {
ocrTaskchildPicture.setTaskId(taskList.get(0).getId());
}
// //非历史图片主键集合
@ -377,9 +404,9 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
// ocrTaskchildPicture.setIzHistory(listPictureids.contains(ocrTaskchildPicture.getPictureid())?false:true);
//如果当前任务的任务包主键一致,说明不是历史数据,如果不一致,说明是历史数据
if(packageid.equals(ocrTaskchildPicture.getPackageid().toString())){
if (packageid.equals(ocrTaskchildPicture.getPackageid().toString())) {
ocrTaskchildPicture.setIzHistory(false);
}else{
} else {
ocrTaskchildPicture.setIzHistory(true);
}
@ -396,12 +423,13 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param id
* @return
*/
public boolean closeOrder(String id){
public boolean closeOrder(String id) {
OcrTaskchildPicture ocrTaskchildPicture = this.getById(id);
if(null != ocrTaskchildPicture){
if (null != ocrTaskchildPicture) {
// ocrTaskchildPicture.setIzclose("0");
return this.updateById(ocrTaskchildPicture);
}
@ -410,11 +438,12 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param ocrPicture
* @param tenantId
* @param sysUser
*/
public OcrTaskchildPicture create(OcrPicture ocrPicture, String tenantId , UserToken sysUser, Long packageid,String buessinessno){
public OcrTaskchildPicture create(OcrPicture ocrPicture, String tenantId, UserToken sysUser, Long packageid, String buessinessno) {
OcrTaskchildPicture ocrTaskchildPicture = new OcrTaskchildPicture();
ocrTaskchildPicture.setBuessinessno(buessinessno);
@ -436,11 +465,11 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
StringBuffer pcid = new StringBuffer();
StringBuffer result = new StringBuffer();
for(OcrPicture comp:ocrPicture.getListCom()){
if(null == pcid || pcid.toString().length() < 1){
for (OcrPicture comp : ocrPicture.getListCom()) {
if (null == pcid || pcid.toString().length() < 1) {
pcid.append(comp.getId());
result.append(comp.getResult());
}else{
} else {
pcid.append("," + comp.getId());
result.append("," + comp.getResult());
}
@ -448,17 +477,18 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
ocrTaskchildPicture.setOcpictureid(pcid.toString());
ocrTaskchildPicture.setPictureresult(result.toString());
ocrTaskchildPicture.setPicturecompare(String.join(",",ocrPicture.getPicturecompareList()));
ocrTaskchildPicture.setPicturecompare(String.join(",", ocrPicture.getPicturecompareList()));
return this.save(ocrTaskchildPicture)?ocrTaskchildPicture:null;
return this.save(ocrTaskchildPicture) ? ocrTaskchildPicture : null;
}
/**
*
*
* @param query
* @return
*/
public List<OcrTaskchildPicture> listFinal(Map<String, Object> query){
public List<OcrTaskchildPicture> listFinal(Map<String, Object> query) {
return this.ocrtaskchildpicturemybatisdao.listFinal(query);
}
@ -466,13 +496,14 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
* \
*
* @param taskchildid
* @return
*/
public OcrPicture findOcrPictureByTaskchildid(String taskchildid){
public OcrPicture findOcrPictureByTaskchildid(String taskchildid) {
OcrTaskchildPicture ocrTaskchildPicture = this.ocrtaskchildpicturemybatisdao.selectById(taskchildid);
if(null == ocrTaskchildPicture){
if (null == ocrTaskchildPicture) {
return null;
}
@ -483,10 +514,11 @@ public class OcrTaskchildPictureServiceImpl extends BaseServiceImpl<OcrTaskchild
/**
*
*
* @param query
* @return
*/
public Long listFinalCount(Map<String, Object> query){
public Long listFinalCount(Map<String, Object> query) {
return this.ocrtaskchildpicturemybatisdao.listFinalCount(query);
}
}

@ -111,6 +111,11 @@
<if test="tenantid != null"> and TENANTID ${tenantid.dataOp} ${tenantid.likestar}#{tenantid.value}${tenantid.likeend}</if>
<if test="packageid != null"> and PACKAGEID ${packageid.dataOp} ${packageid.likestar}#{packageid.value}${packageid.likeend}</if>
<if test="processdefinitionid != null"> and PROCESSDEFINITIONID ${processdefinitionid.dataOp} ${processdefinitionid.likestar}#{processdefinitionid.value}${processdefinitionid.likeend}</if>
<if test="taskid != null"> and TASKID ${taskid.dataOp} ${taskid.likestar}#{taskid.value}${taskid.likeend}</if>
<if test="fromprojectid != null"> and FROMPROJECTID ${fromprojectid.dataOp} ${fromprojectid.likestar}#{fromprojectid.value}${fromprojectid.likeend}</if>
<if test="fromuserid != null"> and FROMUSERID ${fromuserid.dataOp} ${fromuserid.likestar}#{fromuserid.value}${fromuserid.likeend}</if>
<if test="fromplanid != null"> and FROMPLANID ${fromplanid.dataOp} ${fromplanid.likestar}#{fromplanid.value}${fromplanid.likeend}</if>
<if test="iztrueorfalse != null"> and IZTRUEORFALSE ${iztrueorfalse.dataOp} ${iztrueorfalse.likestar}#{iztrueorfalse.value}${iztrueorfalse.likeend}</if>
<if test="listFlowCcUserid != null">
and ID in
<foreach collection="listFlowCcUserid" item="item" index="index" open="(" separator="," close=")" >

Loading…
Cancel
Save