| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.sxkj.gd.workOrder.mapper.GdPatrolTaskMapper"> |
| | | <mapper namespace="org.sxkj.gd.workorder.mapper.GdPatrolTaskMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="gdPatrolTaskResultMap" type="org.sxkj.gd.workorder.entity.GdPatrolTaskEntity"> |
| | |
| | | |
| | | |
| | | <select id="selectGdPatrolTaskPage" resultMap="gdPatrolTaskResultMap"> |
| | | select * from ja_gd_patrol_task where is_deleted = 0 |
| | | select pt.*, wo.work_order_name |
| | | from ja_gd_patrol_task pt |
| | | left join ja_gd_work_order wo on pt.work_order_id = wo.id |
| | | <where> |
| | | <if test="param2.workOrderId != null and param2.workOrderId != ''"> |
| | | and pt.work_order_id = #{param2.workOrderId} |
| | | </if> |
| | | <if test="param2.patrolTaskName != null and param2.patrolTaskName != ''"> |
| | | and pt.patrol_task_name like concat(#{param2.patrolTaskName},'%') |
| | | </if> |
| | | <if test="param2.patrolTaskType != null and param2.patrolTaskType != ''"> |
| | | and pt.patrol_task_type = #{param2.patrolTaskType} |
| | | </if> |
| | | <if test="param2.taskStatus != null and param2.taskStatus != ''"> |
| | | and pt.task_status = #{param2.taskStatus} |
| | | </if> |
| | | <if test="param2.startTime != null and param2.startTime != '' and param2.endTime != null and param2.endTime != '' "> |
| | | and pt.execute_time BETWEEN #{param2.startTime} AND #{param2.endTime} |
| | | </if> |
| | | </where> |
| | | </select> |
| | | |
| | | |