本文整理汇总了C#中Slickflow.Engine.Service.WorkflowService.GetReadyTasks方法的典型用法代码示例。如果您正苦于以下问题:C# WorkflowService.GetReadyTasks方法的具体用法?C# WorkflowService.GetReadyTasks怎么用?C# WorkflowService.GetReadyTasks使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Slickflow.Engine.Service.WorkflowService
的用法示例。
在下文中一共展示了WorkflowService.GetReadyTasks方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: FlowList
/// <summary>
/// 当前用户代办任务列表(一次加载所有数据)
/// </summary>
/// <returns></returns>
public ActionResult FlowList()
{
IWorkflowService service = new WorkflowService();
TaskQueryEntity en = new TaskQueryEntity
{
UserID = User.Identity.GetUserId()
};
IList<TaskViewEntity> taskViewList = service.GetReadyTasks(en);
return View(taskViewList);
}
示例2: GetReadyTasks
/// <summary>
/// 获取当前用户待办任务列表
/// </summary>
private void GetReadyTasks()
{
IWorkflowService wfService = new WorkflowService();
TaskQueryEntity en = new TaskQueryEntity
{
UserID = LoginUserID.ToString()
};
IList<TaskViewEntity> taskViewList = wfService.GetReadyTasks(en);
if (taskViewList != null)
{
Repeater2.DataSource = taskViewList;
Repeater2.DataBind();
}
}
示例3: btnRun_Click
/// <summary>
/// 运行流程
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btnRun_Click(object sender, EventArgs e)
{
WfAppRunner appRunner = new WfAppRunner();
appRunner.ProcessGUID = process_guid;
appRunner.AppInstanceID = application_instance_id;
//第一步任务承担者,登录后要找到自己的任务
appRunner.AppName = "officeIn";
appRunner.UserID = "1";
appRunner.UserName = "user1";
IWorkflowService wfService = new WorkflowService();
TaskQueryEntity en = new TaskQueryEntity
{
UserID = "1"
};
IList<TaskViewEntity> taskViewList = wfService.GetReadyTasks(en);
if (taskViewList != null)
{
dataGridView1.DataSource = taskViewList;
}
////下一步执行人
//PerformerList list = new PerformerList();
//Performer p = new Performer("3", "user3");
//下一步人ID,Name 注意有角色区分
//list.Add(p);
//Dictionary<string, string> dictCondition = new Dictionary<string, string>();
//dictCondition.Add("IsHavingWeight", "true");
//dictCondition.Add("CanUseStock", "false");
//appRunner.Conditions = dictCondition;
//NodeView nv = wfService.GetNextActivity(appRunner);//, dictCondition
//Dictionary<String, PerformerList> dictPerformer = new Dictionary<String, PerformerList>();
//dictPerformer.Add(nv.ActivityGUID, list);
//appRunner.NextActivityPerformers = dictPerformer;
var result = wfService.RunProcessApp(appRunner);
var msg = string.Format("流程运行结果:{0}\r\n", result.Status);
textBox1.Text += msg;
}
示例4: GetReadyTasks
public IEnumerable<QueryResult> GetReadyTasks([FromODataUri]QueryEntity query)
{
IWorkflowService service = new WorkflowService();
Mapper.CreateMap<TaskViewEntity, QueryResult>();
Mapper.CreateMap<QueryEntity, TaskQueryEntity>();
var que = Mapper.Map<TaskQueryEntity>(query);
try
{
var result = service.GetReadyTasks(que);
if (result == null)
{
return new List<QueryResult>().AsEnumerable();
}
else
{
var aa = Mapper.Map<IList<QueryResult>>(result);
return aa.AsEnumerable();
}
}
catch
{
return new List<QueryResult>().AsEnumerable();
}
}
开发者ID:uname-yang,项目名称:WorkFlow-Engine-OData-WebApi-with-OdataClient,代码行数:24,代码来源:QueryEntitiesController.cs
示例5: GetReadyTasks
public ResponseResult GetReadyTasks(TaskQueryEntity query)
{
IWorkflowService service = new WorkflowService();
var result = service.GetReadyTasks(query);
return ResponseResult.Success();
}
示例6: QueryReadyTasks
public ResponseResult<List<TaskViewEntity>> QueryReadyTasks(TaskQueryEntity query)
{
var result = ResponseResult<List<TaskViewEntity>>.Default();
try
{
var taskList = new List<TaskViewEntity>();
var wfService = new WorkflowService();
var itemList = wfService.GetReadyTasks(query);
if (itemList != null)
{
taskList = itemList.ToList();
}
result = ResponseResult<List<TaskViewEntity>>.Success(taskList);
}
catch (System.Exception ex)
{
result = ResponseResult<List<TaskViewEntity>>.Error(string.Format(
"获取待办任务数据失败, 异常信息:{0}",
ex.Message));
}
return result;
}
示例7: WfAppRunner
private void btn综合部签字_Click(object sender, EventArgs e)
{
WfAppRunner appRunner = new WfAppRunner();
appRunner.ProcessGUID = process_guid;
appRunner.AppInstanceID = application_instance_id;
//第一步任务承担者,登录后要找到自己的任务
appRunner.AppName = "officeIn";
appRunner.UserID = "3";
appRunner.UserName = "user3";
IWorkflowService wfService = new WorkflowService();
TaskQueryEntity en = new TaskQueryEntity
{
UserID = "3"
};
IList<TaskViewEntity> taskViewList = wfService.GetReadyTasks(en);
appRunner.TaskID = taskViewList[0].TaskID;
PerformerList list = new PerformerList();
list.Add(new Performer("5", "user5"));
NodeView nv = wfService.GetNextActivity(appRunner);
Dictionary<String, PerformerList> dictPerformer = new Dictionary<String, PerformerList>();
dictPerformer.Add(nv.ActivityGUID, list);
appRunner.NextActivityPerformers = dictPerformer;
var result = wfService.RunProcessApp(appRunner);
var msg = string.Format("流程运行结果:{0}\r\n{1}\r\n", result.Status, result.Message);
tBoxResult.Text += msg;
}