From fc6b946b1020ddff4fe2b01c9e439680cbda6b47 Mon Sep 17 00:00:00 2001
From: luohairen <3399054449@qq.com>
Date: 星期三, 04 十二月 2024 09:32:53 +0800
Subject: [PATCH] 分角色展示项目计划,实现不同角色的功能

---
 business/src/main/resources/mapper/ProjectPlanProgressReportMapper.xml |   35 ++++++++++++++++++++++++++++-------
 1 files changed, 28 insertions(+), 7 deletions(-)

diff --git a/business/src/main/resources/mapper/ProjectPlanProgressReportMapper.xml b/business/src/main/resources/mapper/ProjectPlanProgressReportMapper.xml
index 80f9304..8d2b74d 100644
--- a/business/src/main/resources/mapper/ProjectPlanProgressReportMapper.xml
+++ b/business/src/main/resources/mapper/ProjectPlanProgressReportMapper.xml
@@ -10,12 +10,32 @@
         <result column="progress_status" property="progressStatus" />
         <result column="actual_invest" property="actualInvest" />
     </resultMap>
-
-
-
-
-
-
+    <insert id="insertOne">
+        INSERT INTO t_project_plan_progress_report (
+            project_plan_info_id,
+            start_time,
+            end_time,
+            progress_status,
+            actual_invest
+        )
+        VALUES (
+            #{projectPlanInfoId},
+            #{startTime},
+            #{endTime},
+            #{progressStatus},
+            #{actualInvest}
+        )
+    </insert>
+    <update id="updateOne">
+        UPDATE t_project_plan_progress_report
+        SET
+            start_time = #{startTime},
+            end_time = #{endTime},
+            progress_status = #{progressStatus},
+            actual_invest = #{actualInvest}
+        WHERE
+            id = #{id}
+    </update>
 
 
     <select id="getById" resultMap="BaseResultMap">
@@ -51,6 +71,8 @@
     <select id="getDetail" resultType="com.ycl.domain.vo.ProgressReportResponseVO">
         SELECT
             ppi.id,
+            pppr.id AS progress_report_id,
+            pper.id AS examine_record_id,
             ppr.plan_time,
             ppr.plan_time_flag,
             ppi.title,
@@ -71,7 +93,6 @@
                  LEFT JOIN t_project_plan_progress_report AS pppr ON pppr.project_plan_info_id = ppi.id
                  RIGHT JOIN t_project_plan_examine_record AS pper ON pper.project_plan_info_id = ppi.id
         WHERE ppi.id = #{id}
-        ORDER BY pper.gmt_create DESC LIMIT 1
     </select>
 
 </mapper>

--
Gitblit v1.8.0