@At @Ok("jsp") public void list() { MvcUtil.setAttribute(caches.flowByID().values()); MvcUtil.setAttribute("version", caches.flowVersionByFlowID()); MvcUtil.setAttribute("deployed", flowService.deployedFlows()); }
@At("/apply/?/?") @Ok("jsp:flow.apply") public String apply(String key, String tenantId) { com.freestyle.nutz.bean.pojo.Flow flow = caches.flowByKey().get(key); FlowVersion fv = caches.flowVersionByID().get(Integer.valueOf(tenantId)); if (flow == null || fv == null) throw new IllegalArgumentException("没有这个流程"); MvcUtil.setAttribute("title", flow.getTitle()); MvcUtil.setAttribute("tenantId", tenantId); MvcUtil.setAttribute("diagramResource", fv.getDiagramResourceName()); MvcUtil.setAttribute("deploymentId", fv.getDeploymentId()); return key; }
@At @Ok("jsp") public void history(@Param("processInstanceId") String processInstanceId) { MvcUtil.setAttribute(flowService.history(processInstanceId)); }
@At @Ok("jsp") public void definition(@Param("deploymentId") String deploymentId) { MvcUtil.setAttribute(flowService.definition(deploymentId)); }