You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
<?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.gaotao.modules.language.dao.SysObjectLanguageOthersDao">
<select id="searchSysLanguagePackList" parameterType="com.gaotao.modules.language.query.QuerySysLanguagePack" resultType="com.gaotao.modules.language.entity.vo.SysLanguagePackVo"> SELECT solb.function_id, solb.object_id as object_id_key, (CASE WHEN solb.object_type = 'table' THEN '表格' WHEN solb.object_type = 'button' THEN '按钮' WHEN solb.object_type = 'label' THEN '标签' END) as object_type, (CASE WHEN solb.object_type = 'table' THEN 't_' WHEN solb.object_type = 'button' THEN 'b_' WHEN solb.object_type = 'label' THEN 'l_' END) + object_id as object_id, solb.language_value, solb.table_id, fb.name as fun_desc FROM sys_object_language_base solb LEFT JOIN sys_menu fb ON (solb.function_id = fb.menu_id) <where> <if test="query.key != null and query.key != ''"> solb.function_id like #{query.key} </if> <if test="query.key != null and query.key != ''"> OR fb.name like '%'+#{query.key}+'%' </if> </where> order by solb.function_id </select> <select id="searchSysLanguageParam" parameterType="com.gaotao.modules.language.query.QuerySysLanguagePack" resultType="com.gaotao.modules.language.entity.SysObjectLanguageOthers"> SELECT object_id,min(language_value) as language_value FROM sys_object_language_others
<where> <if test="languageCode != null and languageCode != ''"> language_code = #{languageCode} </if> <if test="objectType != null and objectType != ''"> and object_type = #{objectType} </if> </where>
GROUP BY object_id
</select> <select id="searchLanguageListByLanguageCode" parameterType="com.gaotao.modules.language.query.QuerySysLanguagePack" resultType="com.gaotao.modules.language.entity.vo.LanguageOthersVo"> SELECT solb.object_type, solb.function_id, fb.name as fun_desc, solb.object_id, solb.table_id, sll.language_code, solo.language_value, solb.language_value baseName FROM sys_object_language_base solb LEFT JOIN sys_language_list sll ON ( 1 = 1 ) LEFT JOIN sys_menu fb ON (fb.menu_id = solb.function_id) LEFT JOIN sys_object_language_others solo ON ( sll.language_code = solo.language_code and solb.function_id = solo.function_id and solb.table_id = solo.table_id and solb.object_id = solo.object_id and solb.object_type = solo.object_type ) <where> <if test="languageCode != null and languageCode != ''"> sll.language_code = #{languageCode} </if> <if test="functionId != null and functionId != ''"> and (solb.function_id = #{functionId} OR fb.name like '%'+#{functionId}+'%') </if> </where> order by solb.function_id </select> <select id="searchFunctionButtonList" resultType="com.gaotao.modules.language.entity.SysObjectLanguageOthers"> SELECT b.object_id,o.language_code,CASE WHEN o.language_value is NULL THEN b.language_value ELSE o.language_value END as language_value FROM sys_object_language_base b LEFT JOIN sys_object_language_others o ON (b.function_id = o.function_id and b.table_id = o.table_id AND b.object_id = o.object_id AND o.language_code = #{languageCode}) <where> b.function_id = #{functionId} <if test="tableId !=null and tableId != ''"> AND b.table_id = #{tableId} </if> <if test="objectId !=null and objectId != ''"> and b.object_id = #{objectId} </if> <if test="objectType !=null and objectType != ''"> and b.object_type = #{objectType} </if> </where> </select>
</mapper>
|