Commit db3a5de0 by 翁国栋

审批添加人员bug

parent d3b83848
...@@ -80,11 +80,14 @@ public class DiskFilesController { ...@@ -80,11 +80,14 @@ public class DiskFilesController {
@ApiOperation(value = "上传普通文件", httpMethod = "POST", notes = "接口发布说明") @ApiOperation(value = "上传普通文件", httpMethod = "POST", notes = "接口发布说明")
public Result<Object> upload(@CurrentUser UserBean userBean, @RequestParam(required = true) MultipartFile[] file, public Result<Object> upload(@CurrentUser UserBean userBean, @RequestParam(required = true) MultipartFile[] file,
@ApiParam("文件文件夹或共享空间ID") @RequestParam(required = false) Integer catalogueId,HttpServletRequest request) { @ApiParam("文件文件夹或共享空间ID") @RequestParam(required = false) Integer catalogueId,HttpServletRequest request) {
//如果不指定文件夹将选择该用户最近创建的第一级目录,ios端上传并没有指定文件夹
if(catalogueId<=0){ if(catalogueId<=0){
DiskCatalogue diskCatalogue = DiskCatalogue.builder().build().selectOne(new QueryWrapper<DiskCatalogue>().select("id") DiskCatalogue diskCatalogue = DiskCatalogue.builder().build().selectOne(new QueryWrapper<DiskCatalogue>().select("id")
.eq("org_id", userBean.getOrgCode()) .eq("org_id", userBean.getOrgCode())
.eq("parent_id",0)
.eq("delete_flag",0) .eq("delete_flag",0)
.eq("create_user_id",userBean.getEmpNum()).orderByAsc("create_time") .eq("type",JxglEnumInterface.DiskCatalogueType.DISK_FILE.getType())
.eq("create_user_id",userBean.getEmpNum()).orderByDesc("create_time")
); );
if(StringUtils.isEmpty(diskCatalogue)){ if(StringUtils.isEmpty(diskCatalogue)){
diskCatalogue = new DiskCatalogue(); diskCatalogue = new DiskCatalogue();
......
...@@ -5,7 +5,11 @@ import java.io.Serializable; ...@@ -5,7 +5,11 @@ import java.io.Serializable;
import java.util.*; import java.util.*;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import cn.hutool.core.convert.Convert;
import cn.hutool.db.sql.SqlBuilder;
import cn.timer.api.bean.crm.CrmBusinessGroupMember;
import cn.timer.api.bean.crm.CrmClientContacts; import cn.timer.api.bean.crm.CrmClientContacts;
import cn.timer.api.bean.kqmk.KqglAssoLeaveEmployeeBalance;
import cn.timer.api.bean.sche.ScheduleTask; import cn.timer.api.bean.sche.ScheduleTask;
import cn.timer.api.bean.spmk.*; import cn.timer.api.bean.spmk.*;
import cn.timer.api.bean.zzgl.ZzglAuth; import cn.timer.api.bean.zzgl.ZzglAuth;
...@@ -1213,9 +1217,14 @@ public class SpmkController { ...@@ -1213,9 +1217,14 @@ public class SpmkController {
if (!listFlowChildren.get(currentIndex).getExecute().equals("1") && !listFlowChildren.get(currentIndex).getExecute().equals("0")) { if (!listFlowChildren.get(currentIndex).getExecute().equals("1") && !listFlowChildren.get(currentIndex).getExecute().equals("0")) {
//如果当前索引下的都要变更为0未执行 //如果当前索引下的都要变更为0未执行
FlowChildren flowChildren = listFlowChildren.get(spmkApproveDetailDto.getIndex()); FlowChildren flowChildren = listFlowChildren.get(spmkApproveDetailDto.getIndex());
SpmkApproveExecuteRecord spmkApproveExecuteRecord=null;
//如果有执行记录
if(spmkApproveDetailDto.getApproveExecuteRecordId()>0){
spmkApproveExecuteRecord=spmkApproveExecuteRecordMapper.selectById(spmkApproveDetailDto.getApproveExecuteRecordId());
}else{
User user = flowChildren.getRelation().get(0).getUsers().get(spmkApproveDetailDto.getUserIndex()); User user = flowChildren.getRelation().get(0).getUsers().get(spmkApproveDetailDto.getUserIndex());
SpmkApproveExecuteRecord spmkApproveExecuteRecord = spmkApproveExecuteRecordMapper.selectExecuteRecordById(Integer.parseInt(user.getId()), spmkApproveDetailSummary.getApproveSummaryId()); spmkApproveExecuteRecord = spmkApproveExecuteRecordMapper.selectExecuteRecordById(Integer.parseInt(user.getId()), spmkApproveDetailSummary.getApproveSummaryId());
//删除审批过的人记录 }//删除审批过的人记录
if (spmkApproveExecuteRecord != null) { if (spmkApproveExecuteRecord != null) {
spmkApproveExecuteRecordMapper.delExecuteRecord(spmkApproveExecuteRecord.getId(), spmkApproveDetailSummary.getApproveSummaryId()); spmkApproveExecuteRecordMapper.delExecuteRecord(spmkApproveExecuteRecord.getId(), spmkApproveDetailSummary.getApproveSummaryId());
} }
......
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