From ad82e755b335e38e29a5d722f7e8abe67b35a4c8 Mon Sep 17 00:00:00 2001
From: liusheng <337615773@qq.com>
Date: 星期六, 20 七月 2024 16:40:15 +0800
Subject: [PATCH] 代码提交
---
smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml | 57 +++++++++++++++++++++++++++++++++++++++++++--------------
1 files changed, 43 insertions(+), 14 deletions(-)
diff --git a/smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml b/smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml
index 2ef18f7..6fdf155 100644
--- a/smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml
+++ b/smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml
@@ -71,17 +71,48 @@
from svy_lib_template
</sql>
- <select id="selectSvyLibTemplateList" parameterType="com.smartor.domain.SvyLibTemplateReq" resultMap="SvyLibTemplateResult">
- select a.svyid, a.categoryid, a.svycode, a.svyname, a.description, a.introduce,a.submitprompt, a.templateid,
- a.version,a.centerlibrarycode, a.centerlibraryid, a.islocal, a.isenable, a.orgid, a.del_flag, a.create_by,
- a.create_time, a.update_by, a.update_time, a.isupload,
- a.upload_time,a.dept_names,a.value_type,a.label_info,a.reply,
- a.campus,a.suitway,a.script_score,a.score_type,a.otherdata
- ,c.icdname from svy_lib_template
- a,icd10_association b,icd10 c
+ <select id="selectSvyLibTemplateList" parameterType="com.smartor.domain.SvyLibTemplateReq"
+ resultMap="SvyLibTemplateResult">
+ SELECT
+ a.svyid,
+ a.categoryid,
+ a.svycode,
+ a.svyname,
+ a.description,
+ a.introduce,
+ a.submitprompt,
+ a.templateid,
+ a.version,
+ a.centerlibrarycode,
+ a.centerlibraryid,
+ a.islocal,
+ a.isenable,
+ a.orgid,
+ a.del_flag,
+ a.create_by,
+ a.create_time,
+ a.update_by,
+ a.update_time,
+ a.isupload,
+ a.upload_time,
+ a.dept_names,
+ a.value_type,
+ a.label_info,
+ a.reply,
+ a.campus,
+ a.suitway,
+ a.script_score,
+ a.score_type,
+ a.otherdata,
+ b.icd10code,
+ b.icd10name
+ FROM
+ svy_lib_template a
+ JOIN (select outid,GROUP_CONCAT(icd10code) as icd10code,GROUP_CONCAT(icd10name) as icd10name from
+ icd10_association group by outid) b ON a.del_flag = 0
+ AND a.svyid = b.outid
<where>
- a.del_flag=0 and
- a.svyid=b.SVYID and b.ICD10CODE=c.icdcode
+ a.del_flag=0
<if test="categoryid != null ">and a.categoryid = #{categoryid}</if>
<if test="svyid != null ">and a.svyid = #{svyid}</if>
<if test="svyname != null and svyname != ''">and a.svyname like concat('%', #{svyname}, '%')</if>
@@ -128,8 +159,6 @@
<if test="reply != null">reply,</if>
<if test="scriptScore != null">script_score,</if>
<if test="scoreType != null">score_type,</if>
- value_type,
- reply,
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="categoryid != null">#{categoryid},</if>
@@ -201,8 +230,8 @@
</update>
<delete id="deleteSvyLibTemplateBySvyid" parameterType="Long">
- delete
- from svy_lib_template
+ update svy_lib_template
+ set del_flag=1
where svyid = #{svyid}
</delete>
--
Gitblit v1.9.3