WorkflowExtraMapper.xml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="com.xjrsoft.module.workflow.mapper.XjrWorkflowExtraMapper">
  6. <select id="myApproveRecord" parameterType="com.xjrsoft.module.workflow.dto.MyExaminePageDto" resultType="com.xjrsoft.module.workflow.vo.PendingTaskVo">
  7. SELECT t.id,
  8. t.serial_number,
  9. t.process_name,
  10. t.task_id,
  11. t.task_name,
  12. t.task_key,
  13. (select MAX(t1.current_progress) FROM xjr_workflow_extra t1 where t1.process_id = t.process_id) as current_progress,
  14. t.schema_id,
  15. t.schema_name,
  16. t.process_id,
  17. t.start_user_id,
  18. t.start_user_name,
  19. t.start_time,
  20. t.end_time,
  21. t.launch_time,
  22. t.approve_user_ids
  23. FROM xjr_workflow_extra t
  24. WHERE 1 = 1
  25. <if test="dto.taskIds != null and dto.taskIds.size() > 0">
  26. and t.task_id in
  27. <foreach item="taskId" index="index" collection="dto.taskIds" open="(" close=")" separator=",">
  28. #{taskId}
  29. </foreach>
  30. </if>
  31. <if test="dto.keyword != null and dto.keyword != ''">
  32. and (t.task_name like concat('%',#{dto.keyword}, '%')
  33. or t.process_name like concat('%',#{dto.keyword}, '%')
  34. or t.schema_name like concat('%',#{dto.keyword}, '%')
  35. or t.start_user_name like concat('%',#{dto.keyword}, '%')
  36. )
  37. </if>
  38. order by t.start_time DESC
  39. </select>
  40. </mapper>