{"sql":"select bwf.id                            as 流程任务id,\n       bwf.activityCode                  as 任务节点id,\n       bwf.activityName                  as 任务节点名称,\n       bwf.instanceId                    as 流程实例id,\n       bwf.participant                   as 任务处理人id,\n       bwf.participantName               as 任务处理人姓名,\n       bwf.startTime                     as 任务接收时间,\n       bwf.receiveTime                   as 任务处理时间,\n       round(bwf.usedTime / 1000, 2)     as \"耗时（秒）\",\n       round(bwf.usedTime / 60000, 2)    as \"耗时（分）\",\n       round(bwf.usedTime / 3600000, 2)  as \"耗时（小时）\",\n       round(bwf.usedTime / 86400000, 2) as \"耗时（天）\",\n       case bwf.approval\n           when 'AGREE' then '同意'\n           when 'REJECT' then '驳回'\n           when 'FORWARD' then '转办'\n           when 'CANCELLED' then '取消'\n           when 'UNDO' then '未处理'\n           when 'TIMEOUT_CANCELLED' then '超时取消'\n           else '超时通过' end               as 任务操作,\n       case bwf.state\n           when 'FINISHED' then '已完成'\n           when 'CANCELLED' then '被取消'\n           when 'REVOKE' then '被撤回'\n           when 'TIMEOUT_CANCELLED' then '超时作废'\n           else '已完成' end                as 任务状态,\n       bwf.workflowCode                  as 流程模版编码,\n       wh.workflowName                   as 流程模板名称,\n       bwf.originator                    as 流程发起人id,\n       bwf.originatorName                as 流程发起人姓名,\n       bwi.startTime                     as 流程发起时间,\n       bwi.finishTime                    as 流程结束时间,\n       bwi.state                         as 流程状态,\n       wh.schemaCode                     as 所属模型编码,\n       haf.name                          as 所属模型名称,\n       bwf.appCode                       as 所属应用编码,\n       hap.name                          as 所属应用名称,\n       hou.departmentId                  as 任务处理人部门id,\n       hod.name                          as 任务处理人部门名称,\n       bwf.originatorDeptQueryCode       as 部门查询字段\nfrom biz_workitem_finished bwf\n         left join biz_workflow_instance bwi on bwf.instanceId = bwi.id\n         left join h_workflow_header wh on bwf.workflowCode = wh.workflowCode\n         left join h_app_function haf on wh.schemaCode = haf.code\n         left join h_app_package hap on bwf.appCode = hap.code\n         left join h_org_user hou on bwf.participant = hou.id\n         left join h_org_department hod on hou.departmentId = hod.id\n","title":"已办任务","dbConfig":null,"encrypted":true,"dynamicParams":null}