注册氚云社区,学习低代码知识,与更多氚友互动交流
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
想要获取流程中,接受任务到完成任务这两个节点的时间,并且计算出两个时间的区间,并且显示出来,自己写了一段,但是总是提示没有找到适合的方法来重写,希望大佬们能解答下,谢谢- protected override void OnWorkflowInstanceStateChanged(H3.Workflow.Instance.WorkflowInstanceState nowState, H3.Workflow.Instance.WorkflowInstance aa )
- {
- if(nowState == H3.Workflow.Instance.WorkflowInstanceState.Running)
- {
- //当流程正在进行中,并且流程状态为接收任务,向开始时间控件赋值
- if(H3.Workflow.Instance.WorkflowInstance.InstanceId == "Activity18")
- {
- this.Request.BizObject["F0000033"] = this.Request.BizObject["F0000033"] != null ? this.Request.BizObject["F0000033"] : System.DateTime.Now;
- }
- //当流程正在进行中,并且流程状态为完成任务,向结束时间控件赋值
- if(H3.Workflow.Instance.WorkflowInstance.InstanceId == "Activity24")
- {
- this.Request.BizObject["F0000034"] = this.Request.BizObject["F0000034"] != null ? this.Request.BizObject["F0000034"] : System.DateTime.Now;
- }
- }
- base.OnWorkflowInstanceStateChanged(nowState);
- }
复制代码
|