From b0ea50dd24a7ed5ada38dc6c8209f78fc09f0441 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期五, 21 六月 2024 17:45:33 +0800
Subject: [PATCH] 修复bug
---
server/dmvisit_service/src/main/resources/mappers/SystemDictDataMapper.xml | 47 +++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 47 insertions(+), 0 deletions(-)
diff --git a/server/dmvisit_service/src/main/resources/mappers/SystemDictDataMapper.xml b/server/dmvisit_service/src/main/resources/mappers/SystemDictDataMapper.xml
new file mode 100644
index 0000000..ae3a515
--- /dev/null
+++ b/server/dmvisit_service/src/main/resources/mappers/SystemDictDataMapper.xml
@@ -0,0 +1,47 @@
+<?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.doumee.dao.system.SystemDictDataMapper">
+
+ <!-- 鏌ヨ瀛楀吀鏁版嵁鍒楄〃 -->
+ <resultMap id="SystemDictDataListVO" type="com.doumee.dao.system.vo.SystemDictDataListVO" autoMapping="true">
+ <id column="ID" property="id"/>
+ <association property="createUserInfo" javaType="com.doumee.dao.system.model.SystemUser">
+ <result column="CREATE_USER_ID" property="id"/>
+ <result column="CREATE_USER_NAME" property="username"/>
+ </association>
+ <association property="updateUserInfo" javaType="com.doumee.dao.system.model.SystemUser">
+ <result column="UPDATE_USER_ID" property="id"/>
+ <result column="UPDATE_USER_NAME" property="username"/>
+ </association>
+ </resultMap>
+ <select id="selectManageList" parameterType="com.doumee.dao.system.dto.QuerySystemDictDataDTO" resultMap="SystemDictDataListVO">
+ SELECT
+ dict_data.`ID`, dict_data.`DICT_ID`, dict_data.`CODE`, dict_data.`LABEL`, dict_data.`SORT`, dict_data.`DISABLED`, dict_data.`CREATE_TIME`, dict_data.`UPDATE_TIME`, dict_data.`CREATE_USER`, dict_data.`UPDATE_USER`,
+ create_user.ID CREATE_USER_ID, create_user.`USERNAME` CREATE_USER_NAME,
+ update_user.ID UPDETE_USER_ID, update_user.`USERNAME` UPDATE_USER_NAME
+ FROM SYSTEM_DICT_DATA dict_data
+ LEFT JOIN `SYSTEM_USER` create_user ON create_user.ID = dict_data.CREATE_USER
+ LEFT JOIN `SYSTEM_USER` update_user ON update_user.ID = dict_data.UPDATE_USER
+ <where>
+ dict_data.DELETED = 0
+ <if test="dictId != null">
+ AND dict_data.`DICT_ID` = #{dictId}
+ </if>
+ </where>
+ </select>
+ <select id="list" resultType="com.doumee.dao.system.vo.SystemDictDataListVO">
+ SELECT
+ dict_data.`ID`, dict_data.`DICT_ID`, dict_data.`CODE`, dict_data.`LABEL`
+ FROM SYSTEM_DICT_DATA dict_data
+ <where>
+ dict_data.DELETED = 0
+ <if test="codes != null and codes.size > 0">
+ AND dict_data.`LABEL` in
+ <foreach collection="codes" index="index" item="code" open="(" separator="," close=")">
+ #{code}
+ </foreach>
+ </if>
+ </where>
+ </select>
+
+</mapper>
--
Gitblit v1.9.3