Pre Merge pull request !157 from li_oxen/master
This commit is contained in:
commit
645fbb5807
2
pom.xml
2
pom.xml
|
|
@ -67,7 +67,7 @@
|
||||||
<version>${shiro.version}</version>
|
<version>${shiro.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- Shiro使用Srping框架 -->
|
<!-- Shiro使用Spring框架 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.shiro</groupId>
|
<groupId>org.apache.shiro</groupId>
|
||||||
<artifactId>shiro-spring</artifactId>
|
<artifactId>shiro-spring</artifactId>
|
||||||
|
|
|
||||||
|
|
@ -4,13 +4,14 @@
|
||||||
<!-- 磁盘缓存位置 -->
|
<!-- 磁盘缓存位置 -->
|
||||||
<diskStore path="java.io.tmpdir"/>
|
<diskStore path="java.io.tmpdir"/>
|
||||||
|
|
||||||
<!-- maxEntriesLocalHeap:堆内存中最大缓存对象数,0没有限制 -->
|
<!-- maxEntriesLocalHeap: 堆内存中最大缓存对象数,0没有限制 -->
|
||||||
<!-- maxElementsInMemory: 在内存中缓存的element的最大数目。-->
|
<!-- maxElementsInMemory:在内存中缓存的element的最大数目。-->
|
||||||
<!-- eternal:elements是否永久有效,如果为true,timeouts将被忽略,element将永不过期 -->
|
<!-- eternal: elements是否永久有效,如果为true,timeouts将被忽略,element将永不过期 -->
|
||||||
<!-- timeToIdleSeconds:失效前的空闲秒数,当eternal为false时,这个属性才有效,0为不限制 -->
|
<!-- timeToIdleSeconds: 失效前的空闲秒数,当eternal为false时,这个属性才有效,0为不限制 -->
|
||||||
<!-- timeToLiveSeconds:失效前的存活秒数,创建时间到失效时间的间隔为存活时间,当eternal为false时,这个属性才有效,0为不限制 -->
|
<!-- timeToLiveSeconds: 失效前的存活秒数,创建时间到失效时间的间隔为存活时间,当eternal为false时,这个属性才有效,0为不限制 -->
|
||||||
<!-- overflowToDisk: 如果内存中数据超过内存限制,是否要缓存到磁盘上 -->
|
<!-- overflowToDisk:如果内存中数据超过内存限制,是否要缓存到磁盘上 -->
|
||||||
<!-- statistics:是否收集统计信息。如果需要监控缓存使用情况,应该打开这个选项。默认为关闭(统计会影响性能)。设置statistics="true"开启统计 -->
|
<!-- statistics:是否收集统计信息。如果需要监控缓存使用情况,应该打开这个选项。默认为关闭(统计会影响性能)。设置statistics="true"开启统计 -->
|
||||||
|
<!-- diskPersistent:是否持久化磁盘缓存,当这个属性的值为true时,系统在初始化时会在磁盘中查找文件名为cache名称,后缀名为data的文件。指重启jvm后,数据是否有效。默认为false -->
|
||||||
|
|
||||||
<!-- 默认缓存 -->
|
<!-- 默认缓存 -->
|
||||||
<defaultCache
|
<defaultCache
|
||||||
|
|
|
||||||
|
|
@ -3083,10 +3083,6 @@ a:hover, a:focus {
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
video {
|
|
||||||
width: 100% !important;
|
|
||||||
height: auto !important;
|
|
||||||
}
|
|
||||||
/* GALLERY */
|
/* GALLERY */
|
||||||
.gallery>.row>div {
|
.gallery>.row>div {
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
|
|
|
||||||
|
|
@ -14,13 +14,11 @@ $(function() {
|
||||||
$('#side-menu').metisMenu();
|
$('#side-menu').metisMenu();
|
||||||
|
|
||||||
//固定菜单栏
|
//固定菜单栏
|
||||||
$(function() {
|
$('.sidebar-collapse').slimScroll({
|
||||||
$('.sidebar-collapse').slimScroll({
|
height: '96%',
|
||||||
height: '100%',
|
railOpacity: 0.9,
|
||||||
railOpacity: 0.9,
|
alwaysVisible: false
|
||||||
alwaysVisible: false
|
});
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
// 菜单切换
|
// 菜单切换
|
||||||
$('.navbar-minimalize').click(function() {
|
$('.navbar-minimalize').click(function() {
|
||||||
|
|
@ -36,8 +34,8 @@ $(function() {
|
||||||
if ($('body').hasClass('canvas-menu mini-navbar')) {
|
if ($('body').hasClass('canvas-menu mini-navbar')) {
|
||||||
NavToggle();
|
NavToggle();
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
$('#side-menu>li li a:not(:has(span))').click(function() {
|
$('#side-menu>li li a:not(:has(span))').click(function() {
|
||||||
if ($(window).width() < 769) {
|
if ($(window).width() < 769) {
|
||||||
NavToggle();
|
NavToggle();
|
||||||
|
|
|
||||||
|
|
@ -215,9 +215,15 @@ var table = {
|
||||||
$(optionsIds).off("click").on("click", '.img-circle', function() {
|
$(optionsIds).off("click").on("click", '.img-circle', function() {
|
||||||
var src = $(this).attr('src');
|
var src = $(this).attr('src');
|
||||||
var target = $(this).data('target');
|
var target = $(this).data('target');
|
||||||
var height = $(this).data('height');
|
|
||||||
var width = $(this).data('width');
|
|
||||||
if($.common.equals("self", target)) {
|
if($.common.equals("self", target)) {
|
||||||
|
var height = $(this).data('height');
|
||||||
|
var width = $(this).data('width');
|
||||||
|
//如果是移动端,就使用自适应大小弹窗
|
||||||
|
if ($.common.isMobile()) {
|
||||||
|
width = 'auto';
|
||||||
|
height = 'auto';
|
||||||
|
}
|
||||||
|
|
||||||
layer.open({
|
layer.open({
|
||||||
title: false,
|
title: false,
|
||||||
type: 1,
|
type: 1,
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ function login() {
|
||||||
data: {
|
data: {
|
||||||
"username": username,
|
"username": username,
|
||||||
"password": password,
|
"password": password,
|
||||||
"validateCode" : validateCode,
|
"validateCode": validateCode,
|
||||||
"rememberMe": rememberMe
|
"rememberMe": rememberMe
|
||||||
},
|
},
|
||||||
success: function(r) {
|
success: function(r) {
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
<head th:fragment=header(title)>
|
<head th:fragment=header(title)>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||||
<meta name="keywords" content="">
|
<meta name="keywords" content="">
|
||||||
<meta name="description" content="">
|
<meta name="description" content="">
|
||||||
<title th:text="${title}"></title>
|
<title th:text="${title}"></title>
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,8 @@
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<meta name="renderer" content="webkit">
|
<meta name="renderer" content="webkit">
|
||||||
<title>若依系统首页</title>
|
<title>若依系统首页</title>
|
||||||
<!--[if lt IE 9]>
|
<!-- 避免IE使用兼容模式 -->
|
||||||
<meta http-equiv="refresh" content="0;ie.html"/>
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||||
<![endif]-->
|
|
||||||
<link th:href="@{favicon.ico}" rel="stylesheet"/>
|
<link th:href="@{favicon.ico}" rel="stylesheet"/>
|
||||||
<link th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
|
<link th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
|
||||||
<link th:href="@{/css/jquery.contextMenu.min.css}" rel="stylesheet"/>
|
<link th:href="@{/css/jquery.contextMenu.min.css}" rel="stylesheet"/>
|
||||||
|
|
@ -276,14 +275,15 @@ function resetPwd() {
|
||||||
var url = ctx + 'system/user/profile/resetPwd';
|
var url = ctx + 'system/user/profile/resetPwd';
|
||||||
$.modal.open("重置密码", url, '770', '380');
|
$.modal.open("重置密码", url, '770', '380');
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 切换主题 */
|
/* 切换主题 */
|
||||||
function switchSkin() {
|
function switchSkin() {
|
||||||
layer.open({
|
layer.open({
|
||||||
type : 2,
|
type: 2,
|
||||||
shadeClose : true,
|
shadeClose: true,
|
||||||
title : "切换主题",
|
title: "切换主题",
|
||||||
area : ["530px", "386px"],
|
area: ["530px", "386px"],
|
||||||
content : [ctx + "system/switchSkin", 'no']
|
content: [ctx + "system/switchSkin", 'no']
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -108,7 +108,10 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'remark',
|
field: 'remark',
|
||||||
title: '备注'
|
title: '备注',
|
||||||
|
formatter: function(value, row, index) {
|
||||||
|
return $.table.tooltip(value);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'createTime',
|
field: 'createTime',
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-4 control-label is-required">用户名称:</label>
|
<label class="col-sm-4 control-label is-required">用户名称:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input name="userName" placeholder="请输入用户名称" class="form-control" type="text" maxlength="30" required>
|
<input name="userName" placeholder="请输入用户名称" class="form-control" type="text" maxlength="30" autocomplete="new-password" required>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -61,7 +61,7 @@
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-4 control-label is-required">登录密码:</label>
|
<label class="col-sm-4 control-label is-required">登录密码:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input name="password" placeholder="请输入登录密码" class="form-control" type="password" th:value="${@config.getKey('sys.user.initPassword')}" required>
|
<input name="password" placeholder="请输入登录密码" class="form-control" type="password" th:value="${@config.getKey('sys.user.initPassword')}" autocomplete="new-password" required>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -20,22 +20,22 @@ public interface ShiroConstants
|
||||||
/**
|
/**
|
||||||
* 消息key
|
* 消息key
|
||||||
*/
|
*/
|
||||||
public static String MESSAGE = "message";
|
public static final String MESSAGE = "message";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 错误key
|
* 错误key
|
||||||
*/
|
*/
|
||||||
public static String ERROR = "errorMsg";
|
public static final String ERROR = "errorMsg";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 编码格式
|
* 编码格式
|
||||||
*/
|
*/
|
||||||
public static String ENCODING = "UTF-8";
|
public static final String ENCODING = "UTF-8";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 当前在线会话
|
* 当前在线会话
|
||||||
*/
|
*/
|
||||||
public String ONLINE_SESSION = "online_session";
|
public static final String ONLINE_SESSION = "online_session";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 验证码key
|
* 验证码key
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,7 @@ public class FileUploadUtils
|
||||||
*
|
*
|
||||||
* @param baseDir 相对应用的基目录
|
* @param baseDir 相对应用的基目录
|
||||||
* @param file 上传的文件
|
* @param file 上传的文件
|
||||||
* @param extension 上传文件类型
|
* @param allowedExtension 上传文件类型
|
||||||
* @return 返回上传成功的文件名
|
* @return 返回上传成功的文件名
|
||||||
* @throws FileSizeLimitExceededException 如果超出最大大小
|
* @throws FileSizeLimitExceededException 如果超出最大大小
|
||||||
* @throws FileNameLengthLimitExceededException 文件名太长
|
* @throws FileNameLengthLimitExceededException 文件名太长
|
||||||
|
|
|
||||||
|
|
@ -9,8 +9,6 @@ import com.ruoyi.common.utils.StringUtils;
|
||||||
*/
|
*/
|
||||||
public class EscapeUtil
|
public class EscapeUtil
|
||||||
{
|
{
|
||||||
public static final String RE_HTML_MARK = "(<[^<]*?>)|(<[\\s]*?/[^<]*?>)|(<[^<]*?/[\\s]*?>)";
|
|
||||||
|
|
||||||
private static final char[][] TEXT = new char[64][];
|
private static final char[][] TEXT = new char[64][];
|
||||||
|
|
||||||
static
|
static
|
||||||
|
|
@ -141,14 +139,4 @@ public class EscapeUtil
|
||||||
}
|
}
|
||||||
return tmp.toString();
|
return tmp.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void main(String[] args)
|
|
||||||
{
|
|
||||||
String html = "<script>alert(1);</script>";
|
|
||||||
// String html = "<scr<script>ipt>alert(\"XSS\")</scr<script>ipt>";
|
|
||||||
// String html = "<123";
|
|
||||||
System.out.println(EscapeUtil.clean(html));
|
|
||||||
System.out.println(EscapeUtil.escape(html));
|
|
||||||
System.out.println(EscapeUtil.unescape(html));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,8 @@ public class DataScopeAspect
|
||||||
*
|
*
|
||||||
* @param joinPoint 切点
|
* @param joinPoint 切点
|
||||||
* @param user 用户
|
* @param user 用户
|
||||||
* @param alias 别名
|
* @param deptAlias 别名
|
||||||
|
* @param userAlias 别名
|
||||||
*/
|
*/
|
||||||
public static void dataScopeFilter(JoinPoint joinPoint, SysUser user, String deptAlias, String userAlias)
|
public static void dataScopeFilter(JoinPoint joinPoint, SysUser user, String deptAlias, String userAlias)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,7 @@ public abstract class RepeatSubmitInterceptor extends HandlerInterceptorAdapter
|
||||||
/**
|
/**
|
||||||
* 验证是否重复提交由子类实现具体的防重复提交的规则
|
* 验证是否重复提交由子类实现具体的防重复提交的规则
|
||||||
*
|
*
|
||||||
* @param httpServletRequest
|
* @param request
|
||||||
* @return
|
* @return
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -80,7 +80,7 @@ public class SysPasswordService
|
||||||
|
|
||||||
public String encryptPassword(String username, String password, String salt)
|
public String encryptPassword(String username, String password, String salt)
|
||||||
{
|
{
|
||||||
return new Md5Hash(username + password + salt).toHex().toString();
|
return new Md5Hash(username + password + salt).toHex();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void unlock(String loginName){
|
public void unlock(String loginName){
|
||||||
|
|
|
||||||
|
|
@ -80,12 +80,12 @@ public class OnlineSessionDAO extends EnterpriseCacheSessionDAO
|
||||||
boolean isGuest = onlineSession.getUserId() == null || onlineSession.getUserId() == 0L;
|
boolean isGuest = onlineSession.getUserId() == null || onlineSession.getUserId() == 0L;
|
||||||
|
|
||||||
// session 数据变更了 同步
|
// session 数据变更了 同步
|
||||||
if (isGuest == false && onlineSession.isAttributeChanged())
|
if (!isGuest && onlineSession.isAttributeChanged())
|
||||||
{
|
{
|
||||||
needSync = true;
|
needSync = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (needSync == false)
|
if (!needSync)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ public class ConfigService
|
||||||
/**
|
/**
|
||||||
* 根据键名查询参数配置信息
|
* 根据键名查询参数配置信息
|
||||||
*
|
*
|
||||||
* @param configName 参数名称
|
* @param configKey 参数名称
|
||||||
* @return 参数键值
|
* @return 参数键值
|
||||||
*/
|
*/
|
||||||
public String getKey(String configKey)
|
public String getKey(String configKey)
|
||||||
|
|
|
||||||
|
|
@ -115,8 +115,8 @@
|
||||||
#if($column.pk)
|
#if($column.pk)
|
||||||
#elseif($column.list && "" != $dictType)
|
#elseif($column.list && "" != $dictType)
|
||||||
{
|
{
|
||||||
field : '${javaField}',
|
field: '${javaField}',
|
||||||
title : '${comment}',
|
title: '${comment}',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
formatter: function(value, row, index) {
|
formatter: function(value, row, index) {
|
||||||
return $.table.selectDictLabel(${javaField}Datas, value);
|
return $.table.selectDictLabel(${javaField}Datas, value);
|
||||||
|
|
@ -124,8 +124,8 @@
|
||||||
},
|
},
|
||||||
#elseif($column.list && "" != $javaField)
|
#elseif($column.list && "" != $javaField)
|
||||||
{
|
{
|
||||||
field : '${javaField}',
|
field: '${javaField}',
|
||||||
title : '${comment}',
|
title: '${comment}',
|
||||||
align: 'left'
|
align: 'left'
|
||||||
},
|
},
|
||||||
#end
|
#end
|
||||||
|
|
|
||||||
|
|
@ -111,22 +111,22 @@
|
||||||
#end
|
#end
|
||||||
#if($column.pk)
|
#if($column.pk)
|
||||||
{
|
{
|
||||||
field : '${javaField}',
|
field: '${javaField}',
|
||||||
title : '${comment}',
|
title: '${comment}',
|
||||||
visible: false
|
visible: false
|
||||||
},
|
},
|
||||||
#elseif($column.list && "" != $dictType)
|
#elseif($column.list && "" != $dictType)
|
||||||
{
|
{
|
||||||
field : '${javaField}',
|
field: '${javaField}',
|
||||||
title : '${comment}',
|
title: '${comment}',
|
||||||
formatter: function(value, row, index) {
|
formatter: function(value, row, index) {
|
||||||
return $.table.selectDictLabel(${javaField}Datas, value);
|
return $.table.selectDictLabel(${javaField}Datas, value);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
#elseif($column.list && "" != $javaField)
|
#elseif($column.list && "" != $javaField)
|
||||||
{
|
{
|
||||||
field : '${javaField}',
|
field: '${javaField}',
|
||||||
title : '${comment}'
|
title: '${comment}'
|
||||||
},
|
},
|
||||||
#end
|
#end
|
||||||
#end
|
#end
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ public class JobInvokeUtil
|
||||||
/**
|
/**
|
||||||
* 校验是否为为class包名
|
* 校验是否为为class包名
|
||||||
*
|
*
|
||||||
* @param str 名称
|
* @param invokeTarget 名称
|
||||||
* @return true是 false否
|
* @return true是 false否
|
||||||
*/
|
*/
|
||||||
public static boolean isValidClassName(String invokeTarget)
|
public static boolean isValidClassName(String invokeTarget)
|
||||||
|
|
|
||||||
|
|
@ -177,6 +177,7 @@ public class SysRole extends BaseEntity
|
||||||
this.deptIds = deptIds;
|
this.deptIds = deptIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
.append("roleId", getRoleId())
|
.append("roleId", getRoleId())
|
||||||
|
|
|
||||||
|
|
@ -346,6 +346,7 @@ public class SysUser extends BaseEntity
|
||||||
.append("updateTime", getUpdateTime())
|
.append("updateTime", getUpdateTime())
|
||||||
.append("remark", getRemark())
|
.append("remark", getRemark())
|
||||||
.append("dept", getDept())
|
.append("dept", getDept())
|
||||||
|
.append("roles", getRoles())
|
||||||
.toString();
|
.toString();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -307,7 +307,7 @@ public class SysUserServiceImpl implements ISysUserService
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 校验用户名称是否唯一
|
* 校验手机号是否唯一
|
||||||
*
|
*
|
||||||
* @param user 用户信息
|
* @param user 用户信息
|
||||||
* @return
|
* @return
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="status != null and status != ''">
|
<if test="status != null and status != ''">
|
||||||
AND status = #{status}
|
AND status = #{status}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<!-- 数据范围过滤 -->
|
<!-- 数据范围过滤 -->
|
||||||
${params.dataScope}
|
${params.dataScope}
|
||||||
order by d.parent_id, d.order_num
|
order by d.parent_id, d.order_num
|
||||||
|
|
@ -65,7 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<select id="checkDeptNameUnique" resultMap="SysDeptResult">
|
<select id="checkDeptNameUnique" resultMap="SysDeptResult">
|
||||||
<include refid="selectDeptVo"/>
|
<include refid="selectDeptVo"/>
|
||||||
where dept_name=#{deptName} and parent_id = #{parentId}
|
where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectDeptById" parameterType="Long" resultMap="SysDeptResult">
|
<select id="selectDeptById" parameterType="Long" resultMap="SysDeptResult">
|
||||||
|
|
|
||||||
|
|
@ -131,13 +131,13 @@
|
||||||
<if test="menuName != null and menuName != ''">menu_name = #{menuName},</if>
|
<if test="menuName != null and menuName != ''">menu_name = #{menuName},</if>
|
||||||
<if test="parentId != null and parentId != 0">parent_id = #{parentId},</if>
|
<if test="parentId != null and parentId != 0">parent_id = #{parentId},</if>
|
||||||
<if test="orderNum != null and orderNum != ''">order_num = #{orderNum},</if>
|
<if test="orderNum != null and orderNum != ''">order_num = #{orderNum},</if>
|
||||||
<if test="url != null and url != ''">url = #{url},</if>
|
<if test="url != null">url = #{url},</if>
|
||||||
<if test="target != null and target != ''">target = #{target},</if>
|
<if test="target != null and target != ''">target = #{target},</if>
|
||||||
<if test="menuType != null and menuType != ''">menu_type = #{menuType},</if>
|
<if test="menuType != null and menuType != ''">menu_type = #{menuType},</if>
|
||||||
<if test="visible != null">visible = #{visible},</if>
|
<if test="visible != null">visible = #{visible},</if>
|
||||||
<if test="perms !=null">perms = #{perms},</if>
|
<if test="perms !=null">perms = #{perms},</if>
|
||||||
<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">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = sysdate()
|
||||||
</set>
|
</set>
|
||||||
|
|
|
||||||
|
|
@ -119,29 +119,29 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<select id="selectUserByLoginName" parameterType="String" resultMap="SysUserResult">
|
<select id="selectUserByLoginName" parameterType="String" resultMap="SysUserResult">
|
||||||
<include refid="selectUserVo"/>
|
<include refid="selectUserVo"/>
|
||||||
where u.login_name = #{userName}
|
where u.login_name = #{userName} and u.del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectUserByPhoneNumber" parameterType="String" resultMap="SysUserResult">
|
<select id="selectUserByPhoneNumber" parameterType="String" resultMap="SysUserResult">
|
||||||
<include refid="selectUserVo"/>
|
<include refid="selectUserVo"/>
|
||||||
where u.phonenumber = #{phonenumber}
|
where u.phonenumber = #{phonenumber} and u.del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectUserByEmail" parameterType="String" resultMap="SysUserResult">
|
<select id="selectUserByEmail" parameterType="String" resultMap="SysUserResult">
|
||||||
<include refid="selectUserVo"/>
|
<include refid="selectUserVo"/>
|
||||||
where u.email = #{email}
|
where u.email = #{email} and u.del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="checkLoginNameUnique" parameterType="String" resultType="int">
|
<select id="checkLoginNameUnique" parameterType="String" resultType="int">
|
||||||
select count(1) from sys_user where login_name=#{loginName}
|
select count(1) from sys_user where login_name=#{loginName} and del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="checkPhoneUnique" parameterType="String" resultMap="SysUserResult">
|
<select id="checkPhoneUnique" parameterType="String" resultMap="SysUserResult">
|
||||||
select user_id, phonenumber from sys_user where phonenumber=#{phonenumber}
|
select user_id, phonenumber from sys_user where phonenumber=#{phonenumber} and del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="checkEmailUnique" parameterType="String" resultMap="SysUserResult">
|
<select id="checkEmailUnique" parameterType="String" resultMap="SysUserResult">
|
||||||
select user_id, email from sys_user where email=#{email}
|
select user_id, email from sys_user where email=#{email} and del_flag = '0'
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectUserById" parameterType="Long" resultMap="SysUserResult">
|
<select id="selectUserById" parameterType="Long" resultMap="SysUserResult">
|
||||||
|
|
@ -150,7 +150,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="deleteUserById" parameterType="Long">
|
<delete id="deleteUserById" parameterType="Long">
|
||||||
delete from sys_user where user_id = #{userId}
|
update sys_user set del_flag = '2' where user_id = #{userId}
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<delete id="deleteUserByIds" parameterType="Long">
|
<delete id="deleteUserByIds" parameterType="Long">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue