Преглед на файлове

cdss-core启动报错相应mapper修改

wanghn преди 1 месец
родител
ревизия
6d9e4e2825
променени са 1 файла, в които са добавени 72 реда и са изтрити 71 реда
  1. 72 71
      src/main/resources/mapper/KlDiagnoseBaseMapper.xml

+ 72 - 71
src/main/resources/mapper/KlDiagnoseBaseMapper.xml

@@ -25,79 +25,80 @@
 
     <select id="getAllBaseDiagnose" resultType="com.diagbot.dto.BaseDiagnoseDTO">
         SELECT
-            t.type baseType,
-            t.max_operator baseMaxOperator,
-            t.max_value baseMaxValue,
-            t.max_unit baseMaxUnit,
-            t.min_operator baseMinOperator,
-            t.min_value baseMinValue,
-            t.min_unit baseMinUnit,
-            t.eq_operator baseEqOperator,
-            t.eq_value baseEqValue,
-            t.eq_unit baseEqUnit,
-            t.conceptids baseConceptids,
-            t.lib_name baseLibName,
-            t.lib_type baseLibType,
-            GROUP_CONCAT(t.id) ids
+        t.type baseType,
+        t.max_operator baseMaxOperator,
+        t.max_value baseMaxValue,
+        t.max_unit baseMaxUnit,
+        t.min_operator baseMinOperator,
+        t.min_value baseMinValue,
+        t.min_unit baseMinUnit,
+        t.eq_operator baseEqOperator,
+        t.eq_value baseEqValue,
+        t.eq_unit baseEqUnit,
+        t.conceptids baseConceptids,
+        t.lib_name baseLibName,
+        t.lib_type baseLibType,
+        GROUP_CONCAT(t.id) ids
         FROM
-            (
-                SELECT
-                    t1.id,
-                    t1.type,
-                    t1.max_operator,
-                    t1.max_value,
-                    t1.max_unit,
-                    t1.min_operator,
-                    t1.min_value,
-                    t1.min_unit,
-                    t1.eq_operator,
-                    t1.eq_value,
-                    t1.eq_unit,
-                    IFNULL(t2.conceptids, 0) conceptids,
-                    IFNULL(t2.lib_name, '') lib_name,
-                    IFNULL(t2.lib_type, 0) lib_type
-                FROM
-                    kl_diagnose_base t1
-                LEFT JOIN (
-                    SELECT
-                        diagnose_base_id,
-                        lib_type,
-                        GROUP_CONCAT(
-                            concept_id
-                            ORDER BY
-                                concept_id
-                        ) conceptids,
-                        GROUP_CONCAT(
-                            lib_name
-                            ORDER BY
-                                concept_id SEPARATOR '#'
-                        ) lib_name
-                    FROM
-                        `kl_diagnose_base_relation` m,
-                        kl_concept c
-                    WHERE
-                        m.is_deleted = 'N'
-                    AND c.is_deleted = 'N'
-                    AND c. STATUS = 1
-                    AND m.concept_id = c.id
-                    GROUP BY m.diagnose_base_id, c.lib_type
-                ) t2 ON t1.id = t2.diagnose_base_id
-                WHERE
-                    t1.is_deleted = 'N'
-            ) t
+        (
+        SELECT
+        t1.id,
+        t1.type,
+        t1.max_operator,
+        t1.max_value,
+        t1.max_unit,
+        t1.min_operator,
+        t1.min_value,
+        t1.min_unit,
+        t1.eq_operator,
+        t1.eq_value,
+        t1.eq_unit,
+        IFNULL(t2.conceptids, 0) conceptids,
+        IFNULL(t2.lib_name, '') lib_name,
+        IFNULL(t2.lib_type, 0) lib_type
+        FROM
+        kl_diagnose_base t1
+        LEFT JOIN (
+        SELECT
+        diagnose_base_id,
+        lib_type,
+        GROUP_CONCAT(
+        concept_id
+        ORDER BY
+        concept_id
+        ) conceptids,
+        GROUP_CONCAT(
+        lib_name
+        ORDER BY
+        concept_id SEPARATOR '#'
+        ) lib_name
+        FROM
+        `kl_diagnose_base_relation` m,
+        kl_concept c
+        WHERE
+        m.is_deleted = 'N'
+        AND c.is_deleted = 'N'
+        AND c. STATUS = 1
+        AND m.concept_id = c.id
+        GROUP BY m.diagnose_base_id, c.lib_type
+        ) t2 ON t1.id = t2.diagnose_base_id
+        WHERE
+        t1.is_deleted = 'N'
+        ) t
         GROUP BY
-            t.type,
-            t.max_operator,
-            t.max_value,
-            t.max_unit,
-            t.min_operator,
-            t.min_value,
-            t.min_unit,
-            t.eq_operator,
-            t.eq_value,
-            t.eq_unit,
-            t.conceptids,
-            t.lib_name
+        t.type,
+        t.max_operator,
+        t.max_value,
+        t.max_unit,
+        t.min_operator,
+        t.min_value,
+        t.min_unit,
+        t.eq_operator,
+        t.eq_value,
+        t.eq_unit,
+        t.conceptids,
+        t.lib_name,
+        t.lib_type  <!-- 添加这一项 -->
     </select>
 
 </mapper>