|
@@ -25,6 +25,7 @@
|
|
<result property="updateTime" column="update_time"/>
|
|
<result property="updateTime" column="update_time"/>
|
|
<result property="updateBy" column="update_by"/>
|
|
<result property="updateBy" column="update_by"/>
|
|
<result property="remark" column="remark"/>
|
|
<result property="remark" column="remark"/>
|
|
|
|
+ <result property="frontType" column="front_type" />
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectMenuVo">
|
|
<sql id="selectMenuVo">
|
|
@@ -42,7 +43,8 @@
|
|
status,
|
|
status,
|
|
ifnull(perms, '') as perms,
|
|
ifnull(perms, '') as perms,
|
|
icon,
|
|
icon,
|
|
- create_time
|
|
|
|
|
|
+ create_time,
|
|
|
|
+ front_type
|
|
from sys_menu
|
|
from sys_menu
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
@@ -58,6 +60,9 @@
|
|
<if test="status != null and status != ''">
|
|
<if test="status != null and status != ''">
|
|
AND status = #{status}
|
|
AND status = #{status}
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="frontType != null and frontType != ''">
|
|
|
|
+ AND front_type = #{frontType}
|
|
|
|
+ </if>
|
|
</where>
|
|
</where>
|
|
order by parent_id, order_num
|
|
order by parent_id, order_num
|
|
</select>
|
|
</select>
|
|
@@ -81,6 +86,12 @@
|
|
from sys_menu m
|
|
from sys_menu m
|
|
where m.menu_type in ('M', 'C')
|
|
where m.menu_type in ('M', 'C')
|
|
and m.status = 0
|
|
and m.status = 0
|
|
|
|
+ <if test="frontTypes != null">
|
|
|
|
+ and m.front_type
|
|
|
|
+ <foreach collection="frontTypes" item="frontType" index="index" open="in (" close=")" separator="," >
|
|
|
|
+ #{frontType}
|
|
|
|
+ </foreach>
|
|
|
|
+ </if>
|
|
order by m.parent_id, m.order_num
|
|
order by m.parent_id, m.order_num
|
|
</select>
|
|
</select>
|
|
|
|
|
|
@@ -101,6 +112,9 @@
|
|
<if test="status != null and status != ''">
|
|
<if test="status != null and status != ''">
|
|
AND m.status = #{status}
|
|
AND m.status = #{status}
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="frontType != null and frontType != ''">
|
|
|
|
+ AND m.front_type = #{frontType}
|
|
|
|
+ </if>
|
|
order by m.parent_id, m.order_num
|
|
order by m.parent_id, m.order_num
|
|
</select>
|
|
</select>
|
|
|
|
|
|
@@ -126,6 +140,12 @@
|
|
left join sys_role ro on ur.role_id = ro.role_id
|
|
left join sys_role ro on ur.role_id = ro.role_id
|
|
left join sys_user u on ur.user_id = u.user_id
|
|
left join sys_user u on ur.user_id = u.user_id
|
|
where u.user_id = #{userId}
|
|
where u.user_id = #{userId}
|
|
|
|
+ <if test="frontTypes != null">
|
|
|
|
+ and m.front_type
|
|
|
|
+ <foreach collection="frontTypes" item="frontType" index="index" open="in (" close=")" separator="," >
|
|
|
|
+ #{frontType}
|
|
|
|
+ </foreach>
|
|
|
|
+ </if>
|
|
and m.menu_type in ('M', 'C')
|
|
and m.menu_type in ('M', 'C')
|
|
and m.status = 0
|
|
and m.status = 0
|
|
AND ro.status = 0
|
|
AND ro.status = 0
|
|
@@ -204,6 +224,7 @@
|
|
<if test="icon !=null and icon != ''">icon = #{icon},</if>
|
|
<if test="icon !=null and icon != ''">icon = #{icon},</if>
|
|
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
|
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
|
|
|
+ <if test="frontType != null and frontType != ''">front_type = #{frontType},</if>
|
|
update_time = sysdate()
|
|
update_time = sysdate()
|
|
</set>
|
|
</set>
|
|
where menu_id = #{menuId}
|
|
where menu_id = #{menuId}
|
|
@@ -227,6 +248,7 @@
|
|
<if test="icon != null and icon != ''">icon,</if>
|
|
<if test="icon != null and icon != ''">icon,</if>
|
|
<if test="remark != null and remark != ''">remark,</if>
|
|
<if test="remark != null and remark != ''">remark,</if>
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
|
|
+ <if test="frontType != null and frontType != ''">front_type,</if>
|
|
create_time
|
|
create_time
|
|
)values(
|
|
)values(
|
|
<if test="menuId != null and menuId != 0">#{menuId},</if>
|
|
<if test="menuId != null and menuId != 0">#{menuId},</if>
|
|
@@ -245,6 +267,7 @@
|
|
<if test="icon != null and icon != ''">#{icon},</if>
|
|
<if test="icon != null and icon != ''">#{icon},</if>
|
|
<if test="remark != null and remark != ''">#{remark},</if>
|
|
<if test="remark != null and remark != ''">#{remark},</if>
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
|
|
+ <if test="frontType != null and frontType != ''">#{frontType},</if>
|
|
sysdate()
|
|
sysdate()
|
|
)
|
|
)
|
|
</insert>
|
|
</insert>
|