<userTask id="writeReportTask" name="Write monthly financial report" >
<documentation>
Write monthly financial report for publication to shareholders.
</documentation>

<potentialOwner>
<resourceAssignmentExpression>
<formalExpression>accountancy</formalExpression>什么意思?用户组?
</resourceAssignmentExpression>
</potentialOwner>

</userTask>

Task lists

问:??这里用用户kermit去查找他所有的任务,但在xml文件中只定义了一个会计(accountancy),但最后却用会计组也能得到和kermit相同的任务,为什么?这里也没有定义kermit在accountancy组中,如果要定义又在何处定义,具体怎么写呢?
We can now retrieve this task through the TaskService by adding the following logic:
List<Task> tasks = taskService.createTaskQuery().taskCandidateUser("kermit").list();
Note that the user we pass to this operation needs to be a member of the accountancy group, since that was declared in the process definition:
<potentialOwner>
<resourceAssignmentExpression>
<formalExpression>accountancy</formalExpression>
</resourceAssignmentExpression>
</potentialOwner>
We could also use the task query API to get the same results using the name of the group. We can now add the following logic to our code:
TaskService taskService = processEngine.getTaskService();
List<Task> tasks = taskService.createTaskQuery().taskCandidateGroup("accountancy").list();
Since we've configured our ProcessEngine to use the same database as the demo setup is using, we can now log intoActiviti Explorer. By default, no user is in the accountancy group. Login with kermit/kermit, click Groups and then "Create group". Then click Users and add the group to fozzie. Now login with fozzie/fozzie, and we will find that we can start our business process after selecting the Processes page and and clicking on the 'Start Process' link in the 'Actions' column corresponding to the 'Monthly financial report' process.(这里的创建组,怎么在XML中体现……)

Activiti初学问题,求解的更多相关文章

  1. activiti初学

    公司现有的工作流是比较老的JBPM,用起来不太方便,经常性的流程跑一半就停止不前了.闲暇之余学习下activiti的使用,基本配置如下: 1.创建pom.xml文件所依赖的jar包 <proje ...

  2. activiti数据库表结构全貌解析

    http://www.jianshu.com/p/e6971e8a8dad 下面本人介绍一些activiti这款开源流程设计引擎的数据库表结构,首先阐述:我们刚开始接触或者使用一个新的东西(技术)时我 ...

  3. Activiti初学者教程

    http://wenku.baidu.com/view/bb7364ad4693daef5ff73d32.html 1. 初识Activiti 1.1. 工作流与工作流引擎 工作流(workflow) ...

  4. Activiti初学者教程 (zhuan)

    http://blog.csdn.NET/bluejoe2000/article/details/39521405 ****************************************** ...

  5. 工作流Activiti新手入门学习路线整理

    写在前面: 最近项目中使用到了工作流,虽然此部分不是自己需要完成的,但是也涉及到了要调用写的接口.正好有时间,就了解下,以便之后能在其他项目中用到时,不至于什么都不知道什么都不了解. 这里就主要整理下 ...

  6. python二维列表求解所有元素之和

    2020-01-14 相信很多初学小伙伴都会遇到二维列表求解所有元素之和问题,下面给出两种两种常见的求和方法. 方法1: 思想:遍历整个二维列表元素,然后将所有元素加起来 def Sum_matrix ...

  7. 0-1背包问题蛮力法求解(c++版本)

    // 0.1背包求解.cpp : 定义控制台应用程序的入口点. // #include "stdafx.h" #include <iostream>   #define ...

  8. DDD初学指南

    去年就打算总结一下,结果新换的工作特别忙,就迟迟没有认真动手.主要内容是很多初学DDD甚至于学习很长时间的同学没有弄明白DDD是什么,适合什么情况.这世界上没有银弹,抛开了适合的场景孤立的去研究DDD ...

  9. 流程开发Activiti 与SpringMVC整合实例

    流程(Activiti) 流程是完成一系列有序动作的概述.每一个节点动作的结果将对后面的具体操作步骤产生影响.信息化系统中流程的功能完全等同于纸上办公的层级审批,尤其在oa系统中各类电子流提现较为明显 ...

随机推荐

  1. (NO.00004)iOS实现打砖块游戏(十一):"一闪一闪亮晶晶,我们都是小星星"

    大熊猫猪·侯佩原创或翻译作品.欢迎转载,转载请注明出处. 如果觉得写的不好请告诉我,如果觉得不错请多多支持点赞.谢谢! hopy ;) 现在一个基本的游戏逻辑已经搭建好了,但是感觉还是缺点什么呢? 蠢 ...

  2. android:getSlotFromBufferLocked: unknown buffer: 0xf3d544c0

    欢迎关注公众号,每天推送Android技术文章,二维码如下:(可扫描) 今天运行一个小程序,退出的时候竟然打出一条错误log日志.一时慌乱,在国内网站也没找到合适的答复.通过查看国外的网站终于查到了原 ...

  3. Opencv2.4.9、VS2010配置及grabcut代码实例

    最近opencv库更新到了2.4.9,作为小码农的我紧跟时代的步伐,装了2.4.9这个库.以下是我的配置步骤: 1.从http://opencv.org/上下载opencv2.4.9文件,由于我用的是 ...

  4. linux下重启weblogic(关闭和启动)

     ssh远程连接Linux服务器! 开启weblogic: 1.找到/Oracle/Middleware/user_projects/domains/用户_domain目录, 2.执行nohup ...

  5. STL:list用法详解

    list容器介绍 相对于vector容器的连续线性空间,list是一个双向链表,它有一个重要性质:插入操作和删除操作都不会造成原有的list迭代器失效,每次插入或删除一个元素就配置或释放一个元素空间. ...

  6. Leetcode_102_Binary Tree Level Order Traversal

    本文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/41929059 Given a binary tree, r ...

  7. Java实现简易的文件的迁移器

    Java作为世界上最受欢迎的一门编程语言,自然是有原因的.比如说我们可以直接的方便的调用其中的函数来实现我们想要的功能. 一个偶然的机会,我浏览API文档时发现了一个名为FileDialog的类,然后 ...

  8. ISLR系列:(4.3)模型选择 PCR & PLS

    Linear Model Selection and Regularization 此博文是 An Introduction to Statistical Learning with Applicat ...

  9. UVa - 116 - Unidirectional TSP

    Background Problems that require minimum paths through some domain appear in many different areas of ...

  10. 数据结构基础(3) --Permutation & 插入排序

    Permutation(排列组合) 排列问题: 设R = {r1, r2, ... , rn}是要进行排列的n个元素, Ri = R-{ri}; 集合X中元素的全排列记为Permutation(X), ...