| | |
| | | new ImmutableMap.Builder<String, Long>(). |
| | | put("id", flwTask.getId()) |
| | | .build(); |
| | | QuartzManager.addJob(StateProcessJob.class, (StateProcessJob.name+flwTask.getId()).toUpperCase(), TimeJobType.AUTO_AUDIT,new Date(new Date().getTime()+10*1000L), maps); |
| | | QuartzManager.addJob(StateProcessJob.class, (StateProcessJob.name+flwTask.getId()).toUpperCase(), TimeJobType.AUTO_AUDIT,new Date(new Date().getTime()+48*60*60*1000L), maps); |
| | | } |
| | | } |
| | | } |
| | |
| | | tContractRentType.setCycleTime(dto.getCycleTime()); |
| | | contractRentTypeService.save(tContractRentType); |
| | | } |
| | | if (dto.getStatus().equals("2")){ |
| | | //发起合同新增审批 |
| | | ProcessStartBO processStartBO = new ProcessStartBO(); |
| | | processStartBO.setCategory(ProcessCategoryEnum.CATEGORY1.getValue().toString()); |
| | | processStartBO.setModuleName("合同新增审批"); |
| | | processStartBO.setName(dto.getContractName()); |
| | | //需要显示发起申请人所在单位 |
| | | // String cedName = SecurityUtils.getLoginUser().getUser().getDept().getDeptName(); |
| | | // String remark = String.format("【镇/街】:%s,【征收实施单位】:%s,【申请金额】:%s万元", stateProject.getStreet(), cedName, stateApplyRecord.getAmount()); |
| | | processStartBO.setRemark(""); |
| | | Map<String, Object> variable = new HashMap<>(); |
| | | variable.put("projectId", dto.getId()); |
| | | processStartBO.setVariable(variable); |
| | | //开启工作流程 |
| | | Boolean start = stateProcessTemplateService.start(processStartBO); |
| | | if(start){ |
| | | FlwTask flwTask = flwTaskMapper.selectOne(Wrappers.lambdaQuery(FlwTask.class) |
| | | .like(FlwTask::getVariable, dto.getId()) |
| | | .orderByDesc(FlwTask::getCreateTime) |
| | | .last("LIMIT 1")); |
| | | if(Objects.nonNull(flwTask)){ |
| | | // 添加定时任务 |
| | | Map<String, ? extends Object> maps = |
| | | new ImmutableMap.Builder<String, Long>(). |
| | | put("id", flwTask.getId()) |
| | | .build(); |
| | | QuartzManager.addJob(StateProcessJob.class, (StateProcessJob.name+flwTask.getId()).toUpperCase(), TimeJobType.AUTO_AUDIT,new Date(new Date().getTime()+48*60*60*1000L), maps); |
| | | } |
| | | } |
| | | } |
| | | return R.ok(); |
| | | } |
| | | @Log(title = "合同管理-批量删除合同", businessType = BusinessType.DELETE) |
| | |
| | | TContractVO res = new TContractVO(); |
| | | TContract contract = contractService.getById(id); |
| | | BeanUtils.copyProperties(contract,res); |
| | | res.setPayType(DictUtils.getDictLabel(DictConstants.DICT_TYPE_CONTRACT_PAY_TYPE,res.getPayType())); |
| | | res.setStatus(DictUtils.getDictLabel(DictConstants.DICT_TYPE_CONTRACT_STATUS,res.getStatus())); |
| | | TContractRentType contractRentType = contractRentTypeService.lambdaQuery().eq(TContractRentType::getContractId, id).one(); |
| | | if (contractRentType!=null){ |
| | | BeanUtils.copyProperties(contractRentType,res); |