| | |
| | | import com.fzzy.igds.constant.RespCodeEnum; |
| | | import com.fzzy.igds.data.*; |
| | | import com.fzzy.igds.domain.*; |
| | | import com.fzzy.igds.service.DicAreaService; |
| | | import com.fzzy.igds.service.InoutConfService; |
| | | import com.fzzy.igds.service.InoutNoticeService; |
| | | import com.fzzy.igds.service.InoutRecordService; |
| | | import com.fzzy.igds.service.*; |
| | | import com.fzzy.igds.utils.ContextUtil; |
| | | import com.fzzy.igds.utils.SystemUtil; |
| | | import com.ruoyi.common.core.domain.entity.SysUser; |
| | |
| | | private RedisCache redisCache; |
| | | @Resource |
| | | private InoutConfService inoutConfService; |
| | | @Resource |
| | | private FileService fileService; |
| | | @Resource |
| | | private InoutRecordService inoutRecordService; |
| | | @Resource |
| | |
| | | } |
| | | |
| | | //附件处理 |
| | | saveInoutFiles(data.getFiles(), data.getId(), curProgress); |
| | | fileService.saveInoutFiles(data.getFiles(), data.getId(), curProgress, "INOUT"); |
| | | |
| | | return new PageResponse<>(RespCodeEnum.CODE_0000.getCode(), "登记成功!", data); |
| | | } |
| | |
| | | String nextProgress = getNextProgress(curProgress, data.getType(), inoutSysConf); |
| | | data.setProgress(nextProgress); |
| | | |
| | | if(Constant.PROGRESS_RECORD.equals(nextProgress)){ |
| | | //流程结束时,设置完成时间和完成人 |
| | | data.setCompleteTime(new Date()); |
| | | data.setCompleteUser(ContextUtil.getLoginUserName()); |
| | | } |
| | | //称重数据更新 |
| | | int num = inoutRecordService.updateInoutRecord(data); |
| | | |
| | |
| | | } |
| | | |
| | | //附件处理 |
| | | saveInoutFiles(data.getFiles(), data.getId(), curProgress); |
| | | fileService.saveInoutFiles(data.getFiles(), data.getId(), curProgress, "INOUT"); |
| | | |
| | | return new PageResponse<>(RespCodeEnum.CODE_0000.getCode(), "执行成功", data); |
| | | } |
| | |
| | | } |
| | | |
| | | //附件处理 |
| | | saveInoutFiles(data.getFiles(), data.getId(), curProgress); |
| | | fileService.saveInoutFiles(data.getFiles(), data.getId(), curProgress, "INOUT"); |
| | | |
| | | return new PageResponse<>(RespCodeEnum.CODE_0000.getCode(), "提交成功", data); |
| | | } |
| | | |
| | | /** |
| | | * 异步执行附件保存 |
| | | * @param files 附件信息 |
| | | * @param bizId 业务id |
| | | * @param progress 流程节点 |
| | | */ |
| | | @Async |
| | | public void saveInoutFiles(List<FileInfo> files, String bizId, String progress) { |
| | | |
| | | if (null == files || files.isEmpty()) { |
| | | return; |
| | | } |
| | | |
| | | //TODO 附件逻辑待处理 |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | param.setCompanyId(user.getCompanyId()); |
| | | } |
| | | param.setDeptId(ContextUtil.subDeptId(user)); |
| | | |
| | | List<InoutNoticeIn> list = inoutNoticeService.getNoticeIn(param.getCompanyId(), param.getDeptId(), Constant.COMPLETE_STATUS_NONE); |
| | | param.setCompleteStatus(Constant.COMPLETE_STATUS_NONE); |
| | | List<InoutNoticeIn> list = inoutNoticeService.getNoticeIn(param); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | return new PageResponse<>(RespCodeEnum.CODE_1111.getCode(), "查询结果为空!"); |
| | |
| | | param.setCompanyId(user.getCompanyId()); |
| | | } |
| | | param.setDeptId(ContextUtil.subDeptId(user)); |
| | | |
| | | List<InoutNoticeOut> list = inoutNoticeService.getNoticeOut(param.getCompanyId(), param.getDeptId(), Constant.COMPLETE_STATUS_NONE); |
| | | param.setCompleteStatus(Constant.COMPLETE_STATUS_NONE); |
| | | List<InoutNoticeOut> list = inoutNoticeService.getNoticeOut(param); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | return new PageResponse<>(RespCodeEnum.CODE_1111.getCode(), "查询结果为空!"); |