#update
This commit is contained in:
@@ -47,7 +47,6 @@ public interface SysRoleMenuMapper
|
||||
/**
|
||||
* 查询角色权限
|
||||
* @param roleId 角色id
|
||||
* @return java.util.List<com.fastbee.system.domain.SysRoleMenu>
|
||||
*/
|
||||
List<SysRoleMenu> selectRoleMenuList(Long roleId);
|
||||
}
|
||||
|
||||
@@ -48,7 +48,6 @@ public class SysConfigServiceImpl implements ISysConfigService
|
||||
* @return 参数配置信息
|
||||
*/
|
||||
@Override
|
||||
@DataSource(DataSourceType.master)
|
||||
public SysConfig selectConfigById(Long configId)
|
||||
{
|
||||
SysConfig config = new SysConfig();
|
||||
|
||||
@@ -18,7 +18,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select id, language, country, time_zone, create_by, create_time, lang_name from app_language
|
||||
</sql>
|
||||
|
||||
<select id="selectAppLanguageList" parameterType="com.fastbee.system.domain.AppLanguage" resultMap="AppLanguageResult">
|
||||
<select id="selectAppLanguageList" parameterType="com.maibu.domain.AppLanguage" resultMap="AppLanguageResult">
|
||||
<include refid="selectAppLanguageVo"/>
|
||||
<where>
|
||||
<if test="language != null and language != ''"> and language = #{language}</if>
|
||||
@@ -33,7 +33,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertAppLanguage" parameterType="com.fastbee.system.domain.AppLanguage">
|
||||
<insert id="insertAppLanguage" parameterType="com.maibu.domain.AppLanguage">
|
||||
insert into app_language
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
@@ -55,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateAppLanguage" parameterType="com.fastbee.system.domain.AppLanguage">
|
||||
<update id="updateAppLanguage" parameterType="com.maibu.domain.AppLanguage">
|
||||
update app_language
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="language != null">language = #{language},</if>
|
||||
|
||||
@@ -20,7 +20,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select id, user_id, language, time_zone, create_by, create_time, update_by, update_time, remark from app_preferences
|
||||
</sql>
|
||||
|
||||
<select id="selectAppPreferencesList" parameterType="com.fastbee.system.domain.AppPreferences" resultMap="AppPreferencesResult">
|
||||
<select id="selectAppPreferencesList" parameterType="com.maibu.domain.AppPreferences" resultMap="AppPreferencesResult">
|
||||
<include refid="selectAppPreferencesVo"/>
|
||||
<where>
|
||||
<if test="userId != null "> and user_id = #{userId}</if>
|
||||
@@ -39,7 +39,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where user_id = #{userId}
|
||||
</select>
|
||||
|
||||
<insert id="insertAppPreferences" parameterType="com.fastbee.system.domain.AppPreferences">
|
||||
<insert id="insertAppPreferences" parameterType="com.maibu.domain.AppPreferences">
|
||||
insert into app_preferences
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
@@ -65,7 +65,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateAppPreferences" parameterType="com.fastbee.system.domain.AppPreferences">
|
||||
<update id="updateAppPreferences" parameterType="com.maibu.domain.AppPreferences">
|
||||
update app_preferences
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
from sys_dict_data
|
||||
</sql>
|
||||
|
||||
<select id="selectDictDataList" parameterType="com.fastbee.common.core.domain.entity.SysDictData"
|
||||
<select id="selectDictDataList" parameterType="com.maibu.core.domain.entity.SysDictData"
|
||||
resultMap="SysDictDataResult">
|
||||
select d.dict_code, d.dict_sort,
|
||||
case
|
||||
@@ -64,7 +64,7 @@
|
||||
order by d.dict_sort asc
|
||||
</select>
|
||||
|
||||
<select id="selectDictDataListAll" parameterType="com.fastbee.common.core.domain.entity.SysDictData"
|
||||
<select id="selectDictDataListAll" parameterType="com.maibu.core.domain.entity.SysDictData"
|
||||
resultMap="SysDictDataResult">
|
||||
select d.dict_code, d.dict_sort, d.dict_label, t.zh_cn as dict_label_zh_cn, t.en_us as dict_label_en_us,
|
||||
d.dict_value, d.dict_type, d.css_class, d.list_class, d.is_default, d.status, d.create_by, d.create_time,
|
||||
@@ -85,7 +85,7 @@
|
||||
order by d.dict_sort asc
|
||||
</select>
|
||||
|
||||
<select id="selectDictDataByType" parameterType="com.fastbee.common.core.domain.entity.SysDictData"
|
||||
<select id="selectDictDataByType" parameterType="com.maibu.core.domain.entity.SysDictData"
|
||||
resultMap="SysDictDataResult">
|
||||
select d.dict_code,
|
||||
d.dict_sort,
|
||||
@@ -143,7 +143,7 @@
|
||||
where dict_type = #{dictType}
|
||||
</select>
|
||||
|
||||
<select id="selectDictDataListByDictTypes" resultType="com.fastbee.common.core.domain.entity.SysDictData">
|
||||
<select id="selectDictDataListByDictTypes" resultType="com.maibu.core.domain.entity.SysDictData">
|
||||
select d.dict_code, d.dict_sort,
|
||||
case
|
||||
when #{language} = 'zh-CN' then d.dict_label
|
||||
@@ -174,7 +174,7 @@
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<update id="updateDictData" parameterType="com.fastbee.common.core.domain.entity.SysDictData">
|
||||
<update id="updateDictData" parameterType="com.maibu.core.domain.entity.SysDictData">
|
||||
update sys_dict_data
|
||||
<set>
|
||||
<if test="dictSort != null">dict_sort = #{dictSort},</if>
|
||||
@@ -198,7 +198,7 @@
|
||||
where dict_type = #{oldDictType}
|
||||
</update>
|
||||
|
||||
<insert id="insertDictData" parameterType="com.fastbee.common.core.domain.entity.SysDictData">
|
||||
<insert id="insertDictData" parameterType="com.maibu.core.domain.entity.SysDictData">
|
||||
insert into sys_dict_data(
|
||||
<if test="dictSort != null">dict_sort,</if>
|
||||
<if test="dictLabel != null and dictLabel != ''">dict_label,</if>
|
||||
@@ -226,7 +226,7 @@
|
||||
)
|
||||
</insert>
|
||||
|
||||
<select id="selectByDictTypeAndDictValue" resultType="com.fastbee.common.core.domain.entity.SysDictData">
|
||||
<select id="selectByDictTypeAndDictValue" resultType="com.maibu.core.domain.entity.SysDictData">
|
||||
select d.dict_code,
|
||||
d.dict_sort,
|
||||
case
|
||||
@@ -249,7 +249,7 @@
|
||||
and d.dict_value = #{dictValue}
|
||||
</select>
|
||||
|
||||
<select id="listByDictTypeAndDictValue" resultType="com.fastbee.common.core.domain.entity.SysDictData">
|
||||
<select id="listByDictTypeAndDictValue" resultType="com.maibu.core.domain.entity.SysDictData">
|
||||
select d.dict_code, d.dict_sort,
|
||||
case
|
||||
when #{language} = 'zh-CN' then d.dict_label
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
from sys_dict_type
|
||||
</sql>
|
||||
|
||||
<select id="selectDictTypeList" parameterType="com.fastbee.common.core.domain.entity.SysDictType" resultMap="SysDictTypeResult">
|
||||
<select id="selectDictTypeList" parameterType="com.maibu.core.domain.entity.SysDictType" resultMap="SysDictTypeResult">
|
||||
select d.dict_id,
|
||||
case
|
||||
when #{language} = 'zh-CN' then d.dict_name
|
||||
@@ -111,7 +111,7 @@
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<update id="updateDictType" parameterType="com.fastbee.common.core.domain.entity.SysDictType">
|
||||
<update id="updateDictType" parameterType="com.maibu.core.domain.entity.SysDictType">
|
||||
update sys_dict_type
|
||||
<set>
|
||||
<if test="dictName != null and dictName != ''">dict_name = #{dictName},</if>
|
||||
@@ -124,7 +124,7 @@
|
||||
where dict_id = #{dictId}
|
||||
</update>
|
||||
|
||||
<insert id="insertDictType" parameterType="com.fastbee.common.core.domain.entity.SysDictType">
|
||||
<insert id="insertDictType" parameterType="com.maibu.core.domain.entity.SysDictType">
|
||||
insert into sys_dict_type(
|
||||
<if test="dictName != null and dictName != ''">dict_name,</if>
|
||||
<if test="dictType != null and dictType != ''">dict_type,</if>
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
from sys_menu
|
||||
</sql>
|
||||
|
||||
<select id="selectMenuList" parameterType="com.fastbee.common.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
<select id="selectMenuList" parameterType="com.maibu.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
select distinct m.menu_id,
|
||||
case
|
||||
when #{language} = 'zh-CN' then m.menu_name
|
||||
@@ -70,7 +70,7 @@
|
||||
order by m.parent_id, m.order_num
|
||||
</select>
|
||||
|
||||
<select id="selectMenuListByUserId" parameterType="com.fastbee.common.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
<select id="selectMenuListByUserId" parameterType="com.maibu.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
select distinct m.menu_id, m.parent_id,
|
||||
case
|
||||
when #{language} = 'zh-CN' then m.menu_name
|
||||
@@ -165,13 +165,13 @@
|
||||
select count(1) from sys_menu where parent_id = #{menuId}
|
||||
</select>
|
||||
|
||||
<select id="checkMenuNameUnique" parameterType="com.fastbee.common.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
<select id="checkMenuNameUnique" parameterType="com.maibu.core.domain.entity.SysMenu" resultMap="SysMenuResult">
|
||||
select distinct menu_id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, ifnull(perms,'') as perms, icon, create_time
|
||||
from sys_menu
|
||||
where menu_name=#{menuName} and parent_id = #{parentId} limit 1
|
||||
</select>
|
||||
|
||||
<update id="updateMenu" parameterType="com.fastbee.common.core.domain.entity.SysMenu">
|
||||
<update id="updateMenu" parameterType="com.maibu.core.domain.entity.SysMenu">
|
||||
update sys_menu
|
||||
<set>
|
||||
<if test="menuName != null and menuName != ''">menu_name = #{menuName},</if>
|
||||
@@ -194,7 +194,7 @@
|
||||
where menu_id = #{menuId}
|
||||
</update>
|
||||
|
||||
<insert id="insertMenu" parameterType="com.fastbee.common.core.domain.entity.SysMenu">
|
||||
<insert id="insertMenu" parameterType="com.maibu.core.domain.entity.SysMenu">
|
||||
insert into sys_menu(
|
||||
<if test="menuId != null and menuId != 0">menu_id,</if>
|
||||
<if test="parentId != null and parentId != 0">parent_id,</if>
|
||||
|
||||
@@ -17,7 +17,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select count(1) from sys_role_dept where dept_id=#{deptId}
|
||||
</select>
|
||||
|
||||
<select id="selectRoleDeptByDeptIds" resultType="com.fastbee.system.domain.SysRoleDept">
|
||||
<select id="selectRoleDeptByDeptIds" resultType="com.maibu.domain.SysRoleDept">
|
||||
select dept_id, role_id
|
||||
from sys_role_dept
|
||||
where dept_id in
|
||||
@@ -26,7 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</foreach>
|
||||
</select>
|
||||
|
||||
<select id="selectByRoleId" resultType="com.fastbee.system.domain.SysRoleDept">
|
||||
<select id="selectByRoleId" resultType="com.maibu.domain.SysRoleDept">
|
||||
select dept_id, role_id
|
||||
from sys_role_dept
|
||||
where role_id = #{roleId}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.miabu.mapper.SysRoleMenuMapper">
|
||||
<mapper namespace="com.maibu.mapper.SysRoleMenuMapper">
|
||||
|
||||
<resultMap type="SysRoleMenu" id="SysRoleMenuResult">
|
||||
<result property="roleId" column="role_id" />
|
||||
@@ -13,7 +13,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select count(1) from sys_role_menu where menu_id = #{menuId}
|
||||
</select>
|
||||
|
||||
<select id="selectRoleMenuList" resultType="com.fastbee.system.domain.SysRoleMenu">
|
||||
<select id="selectRoleMenuList" resultType="com.maibu.domain.SysRoleMenu">
|
||||
select *
|
||||
from sys_role_menu
|
||||
where role_id = #{roleId}
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<result property="en_US" column="en_us" />
|
||||
</resultMap>
|
||||
|
||||
<insert id="insertSysTranslate" parameterType="com.fastbee.common.core.domain.entity.SysTranslate">
|
||||
<insert id="insertSysTranslate" parameterType="com.maibu.core.domain.entity.SysTranslate">
|
||||
insert into ${tableName}
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
@@ -30,7 +30,7 @@
|
||||
<if test="en_US != null">en_us = #{en_US}</if>
|
||||
</insert>
|
||||
|
||||
<select id="selectSysTranslateList" parameterType="com.fastbee.common.core.domain.entity.SysTranslate" resultMap="SysTranslateResult">
|
||||
<select id="selectSysTranslateList" parameterType="com.maibu.core.domain.entity.SysTranslate" resultMap="SysTranslateResult">
|
||||
select id, zh_cn, en_us from ${tableName}
|
||||
<where>
|
||||
<if test="zh_CN != null and zh_CN != ''"> and zh_cn = #{zh_CN}</if>
|
||||
@@ -39,7 +39,7 @@
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectSourceList" resultType="com.fastbee.common.core.domain.entity.SysTranslate" resultMap="SysTranslateResult">
|
||||
<select id="selectSourceList" resultType="com.maibu.core.domain.entity.SysTranslate" resultMap="SysTranslateResult">
|
||||
select ${idColumn} as id, ${nameColumn} as zh_cn from ${tableName}
|
||||
<where>
|
||||
<if test="productId != null">product_id = #{productId}</if>
|
||||
|
||||
@@ -4,17 +4,6 @@
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.maibu.mapper.SysUserClientMapper">
|
||||
|
||||
<update id="updateById">
|
||||
update sys_user_client
|
||||
set
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
<if test="userName != null">user_name = #{userName},</if>
|
||||
<if test="clientName != null">client_name = #{clientName},</if>
|
||||
<if test="deviceName != null">device_name = #{deviceName},</if>
|
||||
<if test="isAlive != null">is_alive = #{isAlive}</if>
|
||||
where client_id = #{clientId}
|
||||
</update>
|
||||
|
||||
<insert id="insertUserClient">
|
||||
insert into sys_user_client(user_id,user_name,client_name,device_name,is_alive)
|
||||
values(#{userId},#{userName},#{clientName},#{deviceName},#{isAlive})
|
||||
@@ -42,24 +31,24 @@
|
||||
delete from sys_user_client where client_name= #{clientName}
|
||||
</delete>
|
||||
|
||||
<select id="selectUserClientByUserId" resultType="com.fastbee.common.core.domain.entity.UserClient">
|
||||
<select id="selectUserClientByUserId" resultType="com.maibu.core.domain.entity.UserClient">
|
||||
select user_id,user_name,client_id,client_name,is_alive from sys_user_client where user_id=#{userId}
|
||||
</select>
|
||||
|
||||
<select id="selectUserClientByUserName" resultType="com.fastbee.common.core.domain.entity.UserClient">
|
||||
<select id="selectUserClientByUserName" resultType="com.maibu.core.domain.entity.UserClient">
|
||||
select user_id,user_name,client_id,client_name,is_alive from sys_user_client where user_name= #{userName}
|
||||
</select>
|
||||
|
||||
<select id="selectAllUserClient" resultType="com.fastbee.common.core.domain.entity.UserClient">
|
||||
<select id="selectAllUserClient" resultType="com.maibu.core.domain.entity.UserClient">
|
||||
select user_id,user_name,client_id,client_name,is_alive from sys_user_client
|
||||
</select>
|
||||
|
||||
<select id="selectUserClientByClientName" resultType="com.fastbee.common.core.domain.entity.UserClient">
|
||||
<select id="selectUserClientByClientName" resultType="com.maibu.core.domain.entity.UserClient">
|
||||
select user_id,user_name,client_id,client_name,device_name,is_alive from sys_user_client where client_name=
|
||||
#{clientName}
|
||||
</select>
|
||||
|
||||
<select id="getSysUserByUserName" resultType="com.fastbee.common.core.domain.entity.SysUser">
|
||||
<select id="getSysUserByUserName" resultType="com.maibu.core.domain.entity.SysUser">
|
||||
select user_id,user_name,nick_name,sex,avatar,email,phonenumber,status,del_flag,login_ip,login_date from
|
||||
sys_user where user_name= #{userName} and del_flag = 0
|
||||
</select>
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.miabu.mapper.SysUserMapper">
|
||||
<mapper namespace="com.maibu.mapper.SysUserMapper">
|
||||
|
||||
<resultMap type="com.maibu.core.domain.entity.SysUser" id="SysUserResult">
|
||||
<id property="userId" column="user_id"/>
|
||||
@@ -342,7 +342,7 @@
|
||||
su.user_id = #{userId,jdbcType=BIGINT})
|
||||
</select>
|
||||
|
||||
<select id="listTerminal" resultType="com.fastbee.common.core.domain.entity.SysUser">
|
||||
<select id="listTerminal" resultType="com.maibu.core.domain.entity.SysUser">
|
||||
select u.user_id, u.dept_id, u.nick_name, u.user_name, u.email, u.avatar, u.phonenumber, u.sex, u.status,
|
||||
u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark,
|
||||
d.dept_name, d.leader, d.dept_user_id, r.role_id, r.role_key
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.miabu.mapper.SysUserRoleMapper">
|
||||
<mapper namespace="com.maibu.mapper.SysUserRoleMapper">
|
||||
|
||||
<resultMap type="SysUserRole" id="SysUserRoleResult">
|
||||
<result property="userId" column="user_id" />
|
||||
@@ -17,7 +17,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select count(1) from sys_user_role where role_id=#{roleId}
|
||||
</select>
|
||||
|
||||
<select id="selectRoleByUserId" resultType="com.fastbee.system.domain.SysUserRole">
|
||||
<select id="selectRoleByUserId" resultType="com.maibu.domain.SysUserRole">
|
||||
select user_id, role_id
|
||||
from sys_user_role
|
||||
where user_id = #{userId}
|
||||
|
||||
Reference in New Issue
Block a user