From 4bd1bd1a4618126858242f4ca4a61c303f5c7529 Mon Sep 17 00:00:00 2001
From: wuzeyu <1223318623@qq.com>
Date: 星期三, 11 十二月 2024 14:10:25 +0800
Subject: [PATCH] 实现接口 获取一个巡检员问题上报详情
---
pipIrr-platform/pipIrr-global/src/main/resources/mapper/UgRtuTaskMapper.xml | 47 +++++++++++++++++++++++++++++++++--------------
1 files changed, 33 insertions(+), 14 deletions(-)
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/UgRtuTaskMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/UgRtuTaskMapper.xml
index a8d38c4..c59e372 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/UgRtuTaskMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/UgRtuTaskMapper.xml
@@ -1,7 +1,7 @@
<?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="com.dy.pipIrrGlobal.daoRm.UgRtuTaskMapper">
- <resultMap id="BaseResultMap" type="com.dy.pipIrrGlobal.pojoRm.UgRtuTask">
+ <resultMap id="BaseResultMap" type="com.dy.pipIrrGlobal.pojoUg.UgRtuTask">
<!--@mbg.generated-->
<!--@Table ug_rtu_task-->
<id column="id" jdbcType="BIGINT" property="id" />
@@ -17,15 +17,6 @@
<!--@mbg.generated-->
id, program_id, creator, remark, dt, is_execute, is_over, deleted
</sql>
- <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
- <!--@mbg.generated-->
- select
- <include refid="Base_Column_List" />,
- (CASE WHEN is_execute = 1 THEN '鏄�' ELSE '鍚�' END) AS isExecuteStr,
- (CASE WHEN is_over = 1 THEN '鏄�' ELSE '鍚�' END) AS isOverStr
- from ug_rtu_task
- where id = #{id,jdbcType=BIGINT}
- </select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
<!--@mbg.generated-->
delete from ug_rtu_task
@@ -37,6 +28,23 @@
where id = #{id,jdbcType=BIGINT}
</delete>
+ <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+ <!--@mbg.generated-->
+ select
+ <include refid="Base_Column_List" />,
+ (CASE WHEN is_execute = 1 THEN '鏄�' ELSE '鍚�' END) AS isExecuteStr,
+ (CASE WHEN is_over = 1 THEN '鏄�' ELSE '鍚�' END) AS isOverStr
+ from ug_rtu_task
+ where id = #{id,jdbcType=BIGINT}
+ </select>
+
+ <select id="selectLastTask" parameterType="java.lang.Long" resultMap="BaseResultMap">
+ <!--@mbg.generated-->
+ select
+ <include refid="Base_Column_List" />
+ from ug_rtu_task
+ order by id desc limit 0, 1
+ </select>
<select id="selectTotal" parameterType="java.util.Map" resultType="java.lang.Long">
<!--@mbg.generated-->
@@ -87,8 +95,19 @@
order by bd.id DESC
</select>
+ <select id="selectTaskDetail" parameterType="java.lang.Long" resultType="com.dy.pipIrrGlobal.voUg.VoUpgradeDetail">
+ <!--@mbg.generated-->
+ select
+ ttb.id as taskId,
+ ttb.creator as taskCreator,
+ ttb.dt as taskDt,
+ ptb.hex_file_name as hexFileName
+ from ug_rtu_task ttb
+ inner join ug_rtu_program ptb on ttb.program_id = ptb.id
+ where ttb.id = #{taskId,jdbcType=BIGINT}
+ </select>
- <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoRm.UgRtuTask">
+ <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoUg.UgRtuTask">
<!--@mbg.generated-->
insert into ug_rtu_task (id, program_id, creator,
remark, dt, is_execute, is_over, deleted
@@ -98,7 +117,7 @@
#{isOver,jdbcType=TINYINT}, #{deleted,jdbcType=TINYINT}
)
</insert>
- <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoRm.UgRtuTask">
+ <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoUg.UgRtuTask">
<!--@mbg.generated-->
insert into ug_rtu_task
<trim prefix="(" suffix=")" suffixOverrides=",">
@@ -154,7 +173,7 @@
</if>
</trim>
</insert>
- <update id="updateByPrimaryKeySelective" parameterType="com.dy.pipIrrGlobal.pojoRm.UgRtuTask">
+ <update id="updateByPrimaryKeySelective" parameterType="com.dy.pipIrrGlobal.pojoUg.UgRtuTask">
<!--@mbg.generated-->
update ug_rtu_task
<set>
@@ -182,7 +201,7 @@
</set>
where id = #{id,jdbcType=BIGINT}
</update>
- <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoRm.UgRtuTask">
+ <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoUg.UgRtuTask">
<!--@mbg.generated-->
update ug_rtu_task
set program_id = #{programId,jdbcType=BIGINT},
--
Gitblit v1.8.0