当前位置: 首页 > news >正文

做水果的网站有哪些如何为企业网站设计完整的推广方案

做水果的网站有哪些,如何为企业网站设计完整的推广方案,wordpress点击文字弹窗,建立一个网站的流程更多ruoyi-nbcio功能请看演示系统 gitee源代码地址 前后端代码: https://gitee.com/nbacheng/ruoyi-nbcio 演示地址:RuoYi-Nbcio后台管理系统 相应的后端也要做一些调整 1、启动流程修改如下: /*** 启动流程实例*/private R startProce…

更多ruoyi-nbcio功能请看演示系统

gitee源代码地址

前后端代码: https://gitee.com/nbacheng/ruoyi-nbcio

演示地址:RuoYi-Nbcio后台管理系统

相应的后端也要做一些调整

1、启动流程修改如下:

/*** 启动流程实例*/private R startProcess(ProcessDefinition procDef, Map<String, Object> variables) {if (ObjectUtil.isNotNull(procDef) && procDef.isSuspended()) {throw new ServiceException("流程已被挂起,请先激活流程");}   // 设置流程发起人Id到流程中,包括变量String userStr = TaskUtils.getUserName();SysUser sysUsr = sysUserService.selectUserByUserName(userStr);setFlowVariables(sysUsr,variables);	Map<String, Object> variablesnew = variables;Map<String, Object> usermap = new HashMap<String, Object>();List<String> userlist = new ArrayList<String>();boolean bparallelGateway = false;boolean bapprovedEG = false;//业务数据idString dataId = variables.get("dataId").toString();if(StringUtils.isNotEmpty(dataId)) {//自定义业务表单//设置自定义表单dataid的数据 WfMyBusiness flowmybusiness = wfMyBusinessServiceImpl.getByDataId(variables.get("dataId").toString());String serviceImplName = flowmybusiness.getServiceImplName();WfCallBackServiceI flowCallBackService = (WfCallBackServiceI) SpringContextUtils.getBean(serviceImplName);if (flowCallBackService!=null){Object businessDataById = flowCallBackService.getBusinessDataById(variables.get("dataId").toString());variables.put("formData",businessDataById);}}//获取下个节点信息getNextFlowInfo(procDef, variablesnew, usermap, variables, userlist);//取出两个特殊的变量if(variablesnew.containsKey("bparallelGateway")) {//并行网关bparallelGateway = (boolean) variablesnew.get("bparallelGateway");variablesnew.remove("bparallelGateway");}if(variablesnew.containsKey("bapprovedEG")) {//通用拒绝同意排它网关bapprovedEG = (boolean) variablesnew.get("bapprovedEG");variablesnew.remove("bapprovedEG");}// 发起流程实例ProcessInstance processInstance = runtimeService.startProcessInstanceById(procDef.getId(), variables);// 第一个用户任务为发起人,则自动完成任务//wfTaskService.startFirstTask(processInstance, variables);R<Void> result = setNextAssignee(processInstance, usermap, userlist, sysUsr, variables, bparallelGateway, bapprovedEG);	if(StringUtils.isNotEmpty(dataId)) {//自定义业务表单// 流程发起后的自定义业务更新-需要考虑两种情况,第一个发起人审批或跳过List<Task> tasks = taskService.createTaskQuery().processInstanceId(processInstance.getProcessInstanceId()).active().list();/*======================todo 启动之后  回调以及关键数据保存======================*///如果保存数据前未调用必调的FlowCommonService.initActBusiness方法,就会有问题LoginUser sysUser = commonService.getLoginUser();if(tasks!=null) {SysUser sysTaskUser = new SysUser();List <String> listUser = new ArrayList<String>();List <String> listId = new ArrayList<String>();List <String> listName = new ArrayList<String>();String taskUser = "";String taskid = "";String taskName = "";int taskPriority = 0;for(Task task : tasks) {if(task.getAssignee() != null) {sysTaskUser = commonService.getSysUserByUserName(task.getAssignee());listUser.add(sysTaskUser.getNickName());}listId.add(task.getId());listName.add(task.getName());taskPriority = task.getPriority();}taskUser = listUser.stream().map(String::valueOf).collect(Collectors.joining(","));taskid = listId.stream().map(String::valueOf).collect(Collectors.joining(","));taskName = listName.stream().map(String::valueOf).collect(Collectors.joining(","));WfMyBusiness business = wfMyBusinessServiceImpl.getByDataId(dataId);business.setProcessDefinitionId(procDef.getId());business.setProcessInstanceId(processInstance.getProcessInstanceId());business.setActStatus(ActStatus.doing);business.setProposer(sysUser.getUsername());business.setTaskId(taskid);business.setTaskName(taskName);business.setTaskNameId(taskid);business.setPriority(String.valueOf(taskPriority));business.setDoneUsers("");business.setTodoUsers(taskUser);wfMyBusinessService.updateById(business);//spring容器类名String serviceImplNameafter = business.getServiceImplName();WfCallBackServiceI flowCallBackServiceafter = (WfCallBackServiceI) SpringContextUtils.getBean(serviceImplNameafter);// 流程处理完后,进行回调业务层business.setValues(variables);if (flowCallBackServiceafter!=null)flowCallBackServiceafter.afterFlowHandle(business);}else {WfMyBusiness business = wfMyBusinessServiceImpl.getByDataId(dataId);business.setProcessDefinitionId(procDef.getId());business.setProcessInstanceId(processInstance.getProcessInstanceId());business.setActStatus(ActStatus.pass);business.setProposer(sysUser.getUsername());business.setTaskId("");business.setTaskName("");business.setTaskNameId("");business.setDoneUsers("");business.setTodoUsers("");wfMyBusinessService.updateById(business);//spring容器类名String serviceImplNameafter = business.getServiceImplName();WfCallBackServiceI flowCallBackServiceafter = (WfCallBackServiceI) SpringContextUtils.getBean(serviceImplNameafter);// 流程处理完后,进行回调业务层business.setValues(variables);if (flowCallBackServiceafter!=null)flowCallBackServiceafter.afterFlowHandle(business);}}return result;	}

2、获取表单列表修改如下:

/*** 获取历史流程表单信息*/private List<FormConf> processFormList(BpmnModel bpmnModel, HistoricProcessInstance historicProcIns, String dataId) {List<FormConf> procFormList = new ArrayList<>();List<HistoricActivityInstance> activityInstanceList = historyService.createHistoricActivityInstanceQuery().processInstanceId(historicProcIns.getId()).finished().activityTypes(CollUtil.newHashSet(BpmnXMLConstants.ELEMENT_EVENT_START, BpmnXMLConstants.ELEMENT_TASK_USER)).orderByHistoricActivityInstanceStartTime().asc().list();List<String> processFormKeys = new ArrayList<>();for (HistoricActivityInstance activityInstance : activityInstanceList) {// 获取当前节点流程元素信息FlowElement flowElement = ModelUtils.getFlowElementById(bpmnModel, activityInstance.getActivityId());// 获取当前节点表单KeyString formKey = ModelUtils.getFormKey(flowElement);if (formKey == null) {continue;}boolean localScope = Convert.toBool(ModelUtils.getElementAttributeValue(flowElement, ProcessConstants.PROCESS_FORM_LOCAL_SCOPE), false);Map<String, Object> variables;if (localScope) {// 查询任务节点参数,并转换成Mapvariables = historyService.createHistoricVariableInstanceQuery().processInstanceId(historicProcIns.getId()).taskId(activityInstance.getTaskId()).list().stream().collect(Collectors.toMap(HistoricVariableInstance::getVariableName, HistoricVariableInstance::getValue));} else {if (processFormKeys.contains(formKey)) {continue;}variables = historicProcIns.getProcessVariables();processFormKeys.add(formKey);}  Map<String, Object> formvariables = new HashedMap<String, Object>();//遍历Mapif(variables.containsKey("variables")) {formvariables = (Map<String, Object>)((Map<String, Object>) variables.get("variables")).get("formValue");}// 非节点表单此处查询结果可能有多条,只获取第一条信息List<WfDeployFormVo> formInfoList = deployFormMapper.selectVoList(new LambdaQueryWrapper<WfDeployForm>().eq(WfDeployForm::getDeployId, historicProcIns.getDeploymentId()).eq(WfDeployForm::getFormKey, formKey).eq(localScope, WfDeployForm::getNodeKey, flowElement.getId()));//@update by Brath:避免空集合导致的NULL空指针WfDeployFormVo formInfo = formInfoList.stream().findFirst().orElse(null);if (ObjectUtil.isNotNull(formInfo)) {// 旧数据 formInfo.getFormName() 为 nullString formName = Optional.ofNullable(formInfo.getFormName()).orElse(StringUtils.EMPTY);String title = localScope ? formName.concat("(" + flowElement.getName() + ")") : formName;FormConf formConf = JsonUtils.parseObject(formInfo.getContent(), FormConf.class);if (null != formConf) {//ProcessFormUtils.fillFormData(formConf, variables);formConf.setTitle(title);formConf.setFormValues(formvariables);procFormList.add(formConf);}}}if(StringUtils.isNoneEmpty(dataId)) {WfMyBusiness business = wfMyBusinessServiceImpl.getByDataId(dataId);String serviceImplName = business.getServiceImplName();WfCallBackServiceI flowCallBackService = (WfCallBackServiceI) SpringContextUtils.getBean(serviceImplName);// 流程处理完后,进行回调业务层if (flowCallBackService!=null){Map<String, Object> customMap = new HashMap<String, Object>();FormConf formConf = new FormConf();Object businessDataById = flowCallBackService.getBusinessDataById(dataId);customMap.put("formData",businessDataById);customMap.put("routeName", business.getRouteName());formConf.setFormValues(customMap);procFormList.add(formConf);}}return procFormList;}

3、效果图如下:

http://www.15wanjia.com/news/191398.html

相关文章:

  • wordpress建站后发布电子商务网站建设实验报告
  • 营销型网站设计iis管理器添加网站
  • 会员管理网站ASP建设wordpress 筛选文章
  • wordpress建站教程 cms免费制作公司网站
  • 贵阳市建设厅网站免费的个人简历模板下载
  • 树莓派 做网站环球资源的服务种类
  • 网站建设论文二稿中国做网站
  • 网站内容的丰富性微信群网站有哪些
  • 做网站的为什么一直拖宝安区网站建设
  • 档案网站建设与档案信息化网易那个自己做游戏的网站是什么原因
  • 去哪个网站找题目给孩子做前端网站开发流程入门
  • 学做川菜最好的网站胶州企业网站建设
  • 用php开发wap网站一起做网店官网app
  • 沈阳工伤保险做实在哪个网站天津平台网站建设报价
  • 网站合同 下载东莞做网站(信科网络)
  • 给甜品网站做seo中信建设有限责任公司官网
  • 可信的网站建设wordpress 推送
  • 做本地网站要服务器吗广州网站建设泸州
  • 网站设计开发收费标准西安网站建设公司找哪家
  • 江门营销型网站建设公司如何建立公司网页
  • delphi做网站页面设计原型图是什么
  • 哪个网站做外贸假发好如何做全网影视网站
  • 什么是网站推广?烟台做外贸网站建设
  • 辽宁网站建站wordpress怎么盈利
  • 做网站空间商需要办什么手续室内设计软件免费下载
  • 网站开发的设计思路北京100强公司排行榜
  • 做网站公司怎么做天津定制网站建设公司
  • 怎么做卖花的网站游戏建设网站
  • 北京诚信建设网站商品推广与营销的方式
  • 做招聘网站需要什么人员沈阳做微信和网站的公司