| | |
| | | |
| | | /** |
| | | * 根据筛选条件 |
| | | * |
| | | * @param pageNum |
| | | * @param pageSize |
| | | * @param projectManage |
| | |
| | | |
| | | /** |
| | | * 项目过程管理/己确认、未确认阶段 |
| | | * |
| | | * @param projectManage |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 项目进度确认 |
| | | *未归档可以修改更新,归档后不能修改 |
| | | * 未归档可以修改更新,归档后不能修改 |
| | | * |
| | | * @param pm |
| | | * @return |
| | | */ |
| | |
| | | try { |
| | | bl = projectManageMapper.updateManageState(pm) > 0; |
| | | ArrayList<String> fileList = pm.getFileList(); |
| | | if (bl&&null != fileList) { |
| | | if (bl && null != fileList) { |
| | | for (int i = 0; i < fileList.size(); i++) { |
| | | String filePath = fileList.get(i); |
| | | Boolean fileExist = projectArchiveManageMapper.checkFileExist(filePath)>0; |
| | | Boolean fileExist = projectArchiveManageMapper.checkFileExist(filePath) > 0; |
| | | if (!fileExist) { |
| | | ProjectArchiveManage pam = new ProjectArchiveManage(); |
| | | pam.setProNum(pm.getProNum()); |
| | |
| | | pam.setProNameCode(pm.getProNameCode());//唯一 |
| | | pam.setProSort(pm.getProSort()); |
| | | pam.setProFilePath(filePath); |
| | | pam.setProUploadDate(new Date()); |
| | | String[] split = filePath.split("_"); |
| | | int rexIdex = split[1].lastIndexOf("."); |
| | | pam.setProDocumentName(split[1].substring(0, rexIdex)); |
| | |
| | | /** |
| | | * 项目进度管理 |
| | | * 项目进度(1-6 立项、审批、研究、结题、验收、归档) |
| | | * |
| | | * @param progress |
| | | * @return |
| | | */ |
| | | public Response updateProjectProgress(ProjectManage progress) { |
| | | Response<Object> response = new Response<>(); |
| | | TransactionStatus transactionStatus = dataSourceTransactionManager.getTransaction(transactionDefinition); |
| | | progress.setProArchiveDate(new Date()); |
| | | boolean bl = projectManageMapper.updateProjectProgress(progress) > 0; |
| | | if (bl) { |
| | | bl = projectArchiveManageMapper.updateProjectProgress(progress) > 0; |
| | | } |
| | | if (bl) { |
| | | dataSourceTransactionManager.commit(transactionStatus); |
| | | projectArchiveManageMapper.updateProjectProgress(progress);//有文档材料就增加归档时间 |
| | | response.setMsg(1, "更新成功"); |
| | | } else { |
| | | dataSourceTransactionManager.rollback(transactionStatus); |
| | | response.setMsg(0, "更新失败"); |
| | | } |
| | | return response; |