예제 #1
0
 /** 根据ID查询 */
 @RemoteMethod
 public BpmConfigDto findById(String id) {
   BpmConfig bpmConfig = bpmConfigDaoImpl.findById(id);
   BpmConfigDto templateConfigDto = dozerAssembly.bean2Dto(bpmConfig, BpmConfigDto.class);
   templateConfigDto.setBpmTemplateDto(esbService.getBpmTemplateDto(bpmConfig.getFlow_code()));
   // templateConfigDto.setFlow_code(DictionaryUtils.getItemNameByGroupCode("flow",
   // templateConfigDto.getFlow_code()));
   if (bpmConfig.getFormEntity() != null && bpmConfig.getFormEntity().getFormTree() != null) {
     FormTree formTree = bpmConfig.getFormEntity().getFormTree();
     TreeDto treeDto = new TreeDto();
     treeDto.setId(formTree.getId());
     treeDto.setText(formTreeService.getParentText(formTree.getId()) + "/" + formTree.getText());
     treeDto.setPath(
         formTreeService.getParentPath(formTree.getId()) + "/" + formTree.getId() + "/");
     templateConfigDto.setTreeDto(treeDto);
   }
   return templateConfigDto;
 }
예제 #2
0
  /** 设置为生效 */
  @RemoteMethod
  public void updateById(String id) {
    BpmConfig bpmConfig = bpmConfigDaoImpl.findById(id);
    bpmConfigDaoImpl.updateByEntityId(bpmConfig.getFormEntity().getId());

    bpmConfig.setEnabled("已启用");
    bpmConfig.setModify_date(new Date());
    bpmConfig.setModify_user_id(getUser().getId());
    bpmConfigDaoImpl.update(bpmConfig);
  }