mirror of https://gitee.com/y_project/RuoYi.git
新增方法(addTab、editTab)
parent
90131d1338
commit
6a3ba38b45
|
@ -46,7 +46,7 @@
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><img src="https://oscimg.oschina.net/oscnet/2e1ed87df9b476ed73ed650df20cf009b78.jpg"/></td>
|
<td><img src="https://oscimg.oschina.net/oscnet/2e1ed87df9b476ed73ed650df20cf009b78.jpg"/></td>
|
||||||
<td><img src="https://oscimg.oschina.net/oscnet/91bef110740ba9e36ff00804f8748a787fb.jpg"/></td>
|
<td><img src="https://oscimg.oschina.net/oscnet/693955d8914ee3c34ab904fa0602bc31267.jpg"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><img src="https://oscimg.oschina.net/oscnet/9a2851988f4e7433c9322154534865f57d7.jpg"/></td>
|
<td><img src="https://oscimg.oschina.net/oscnet/9a2851988f4e7433c9322154534865f57d7.jpg"/></td>
|
||||||
|
@ -62,7 +62,7 @@
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><img src="https://oscimg.oschina.net/oscnet/a714056081523b7dfa782cda866e8be4adc.jpg"/></td>
|
<td><img src="https://oscimg.oschina.net/oscnet/a714056081523b7dfa782cda866e8be4adc.jpg"/></td>
|
||||||
<td><img src="https://oscimg.oschina.net/oscnet/ab4b5797dfb2bc68c4974ad5458bd5f5bcf.jpg"/></td>
|
<td><img src="https://oscimg.oschina.net/oscnet/98beb69118d9ab59aa898d5d5baad20b755.jpg"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
|
@ -533,3 +533,22 @@ label {
|
||||||
.dropdown-menu > .divider {
|
.dropdown-menu > .divider {
|
||||||
background-color:#eee;
|
background-color:#eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.form-header {
|
||||||
|
font-size:15px;
|
||||||
|
color:#6379bb;
|
||||||
|
border-bottom:1px solid #ddd;
|
||||||
|
margin:8px 10px 25px 10px;
|
||||||
|
padding-bottom:5px
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-content {
|
||||||
|
background-color: #ffffff;
|
||||||
|
color: inherit;
|
||||||
|
padding: 10px 15px 15px 15px;
|
||||||
|
border-color: #e7eaec;
|
||||||
|
-webkit-border-image: none;
|
||||||
|
-o-border-image: none;
|
||||||
|
border-image: none;
|
||||||
|
border-width: 1px 0px;
|
||||||
|
}
|
||||||
|
|
|
@ -249,7 +249,7 @@ $(function() {
|
||||||
function closeTab() {
|
function closeTab() {
|
||||||
var closeTabId = $(this).parents('.menuTab').data('id');
|
var closeTabId = $(this).parents('.menuTab').data('id');
|
||||||
var currentWidth = $(this).parents('.menuTab').width();
|
var currentWidth = $(this).parents('.menuTab').width();
|
||||||
|
var panelUrl = $(this).parents('.menuTab').data('panel');
|
||||||
// 当前元素处于活动状态
|
// 当前元素处于活动状态
|
||||||
if ($(this).parents('.menuTab').hasClass('active')) {
|
if ($(this).parents('.menuTab').hasClass('active')) {
|
||||||
|
|
||||||
|
@ -307,6 +307,16 @@ $(function() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if($.common.isNotEmpty(panelUrl)){
|
||||||
|
$('.menuTab[data-id="' + panelUrl + '"]').addClass('active').siblings('.menuTab').removeClass('active');
|
||||||
|
$('.mainContent .RuoYi_iframe').each(function() {
|
||||||
|
if ($(this).data('id') == panelUrl) {
|
||||||
|
$(this).show().siblings('.RuoYi_iframe').hide();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 当前元素不处于活动状态
|
// 当前元素不处于活动状态
|
||||||
|
|
|
@ -123,8 +123,25 @@ var refreshItem = function(){
|
||||||
target.attr('src', url).ready();
|
target.attr('src', url).ready();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** 关闭选项卡 */
|
||||||
|
var closeItem = function(){
|
||||||
|
var topWindow = $(window.parent.document);
|
||||||
|
var panelUrl = window.frameElement.getAttribute('data-panel');
|
||||||
|
$('.page-tabs-content .active i', topWindow).click();
|
||||||
|
if($.common.isNotEmpty(panelUrl)){
|
||||||
|
$('.menuTab[data-id="' + panelUrl + '"]', topWindow).addClass('active').siblings('.menuTab').removeClass('active');
|
||||||
|
$('.mainContent .RuoYi_iframe', topWindow).each(function() {
|
||||||
|
if ($(this).data('id') == panelUrl) {
|
||||||
|
$(this).show().siblings('.RuoYi_iframe').hide();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/** 创建选项卡 */
|
/** 创建选项卡 */
|
||||||
function createMenuItem(dataUrl, menuName) {
|
function createMenuItem(dataUrl, menuName) {
|
||||||
|
var panelUrl = window.frameElement.getAttribute('data-id');
|
||||||
dataIndex = $.common.random(1,100),
|
dataIndex = $.common.random(1,100),
|
||||||
flag = true;
|
flag = true;
|
||||||
if (dataUrl == undefined || $.trim(dataUrl).length == 0) return false;
|
if (dataUrl == undefined || $.trim(dataUrl).length == 0) return false;
|
||||||
|
@ -149,13 +166,18 @@ function createMenuItem(dataUrl, menuName) {
|
||||||
});
|
});
|
||||||
// 选项卡菜单不存在
|
// 选项卡菜单不存在
|
||||||
if (flag) {
|
if (flag) {
|
||||||
var str = '<a href="javascript:;" class="active menuTab" data-id="' + dataUrl + '">' + menuName + ' <i class="fa fa-times-circle"></i></a>';
|
var str = '<a href="javascript:;" class="active menuTab" data-id="' + dataUrl + '" data-panel="' + panelUrl + '">' + menuName + ' <i class="fa fa-times-circle"></i></a>';
|
||||||
$('.menuTab', topWindow).removeClass('active');
|
$('.menuTab', topWindow).removeClass('active');
|
||||||
|
|
||||||
// 添加选项卡对应的iframe
|
// 添加选项卡对应的iframe
|
||||||
var str1 = '<iframe class="RuoYi_iframe" name="iframe' + dataIndex + '" width="100%" height="100%" src="' + dataUrl + '" frameborder="0" data-id="' + dataUrl + '" seamless></iframe>';
|
var str1 = '<iframe class="RuoYi_iframe" name="iframe' + dataIndex + '" width="100%" height="100%" src="' + dataUrl + '" frameborder="0" data-id="' + dataUrl + '" data-panel="' + panelUrl + '" seamless></iframe>';
|
||||||
$('.mainContent', topWindow).find('iframe.RuoYi_iframe').hide().parents('.mainContent').append(str1);
|
$('.mainContent', topWindow).find('iframe.RuoYi_iframe').hide().parents('.mainContent').append(str1);
|
||||||
|
|
||||||
|
window.parent.$.modal.loading("数据加载中,请稍后...");
|
||||||
|
$('.mainContent iframe:visible', topWindow).load(function () {
|
||||||
|
window.parent.$.modal.closeLoading();
|
||||||
|
});
|
||||||
|
|
||||||
// 添加选项卡
|
// 添加选项卡
|
||||||
$('.menuTabs .page-tabs-content', topWindow).append(str);
|
$('.menuTabs .page-tabs-content', topWindow).append(str);
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,7 +74,7 @@
|
||||||
// 请求获取数据后处理回调函数
|
// 请求获取数据后处理回调函数
|
||||||
responseHandler: function(res) {
|
responseHandler: function(res) {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
if ($.common.isNotEmpty($.table._option.sidePagination) && $.table._option.sidePagination === 'client') {
|
if ($.common.isNotEmpty($.table._option.sidePagination) && $.table._option.sidePagination == 'client') {
|
||||||
return res.rows;
|
return res.rows;
|
||||||
} else {
|
} else {
|
||||||
return { rows: res.rows, total: res.total };
|
return { rows: res.rows, total: res.total };
|
||||||
|
@ -503,6 +503,10 @@
|
||||||
});
|
});
|
||||||
layer.full(index);
|
layer.full(index);
|
||||||
},
|
},
|
||||||
|
// 选卡页方式打开
|
||||||
|
openTab: function (title, url) {
|
||||||
|
createMenuItem(url, title);
|
||||||
|
},
|
||||||
// 禁用按钮
|
// 禁用按钮
|
||||||
disable: function() {
|
disable: function() {
|
||||||
var doc = window.top == window.parent ? window.document : window.parent.document;
|
var doc = window.top == window.parent ? window.document : window.parent.document;
|
||||||
|
@ -609,13 +613,21 @@
|
||||||
$.operate.submit(url, "post", "json", "");
|
$.operate.submit(url, "post", "json", "");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
// 添加访问请求
|
||||||
|
addUrl: function(id) {
|
||||||
|
var url = $.common.isEmpty(id) ? $.table._option.createUrl : $.table._option.createUrl.replace("{id}", id);
|
||||||
|
return url;
|
||||||
|
},
|
||||||
// 添加信息
|
// 添加信息
|
||||||
add: function(id) {
|
add: function(id) {
|
||||||
var url = $.common.isEmpty(id) ? $.table._option.createUrl : $.table._option.createUrl.replace("{id}", id);
|
$.modal.open("添加" + $.table._option.modalName, $.operate.addUrl(id));
|
||||||
$.modal.open("添加" + $.table._option.modalName, url);
|
|
||||||
},
|
},
|
||||||
// 修改信息
|
// 添加信息,以tab页展现
|
||||||
edit: function(id) {
|
addTab: function (id) {
|
||||||
|
$.modal.openTab("添加" + $.table._option.modalName, $.operate.addUrl(id));
|
||||||
|
},
|
||||||
|
// 修改访问请求
|
||||||
|
editUrl: function(id) {
|
||||||
var url = "/404.html";
|
var url = "/404.html";
|
||||||
if ($.common.isNotEmpty(id)) {
|
if ($.common.isNotEmpty(id)) {
|
||||||
url = $.table._option.updateUrl.replace("{id}", id);
|
url = $.table._option.updateUrl.replace("{id}", id);
|
||||||
|
@ -627,7 +639,15 @@
|
||||||
}
|
}
|
||||||
url = $.table._option.updateUrl.replace("{id}", id);
|
url = $.table._option.updateUrl.replace("{id}", id);
|
||||||
}
|
}
|
||||||
$.modal.open("修改" + $.table._option.modalName, url);
|
return url;
|
||||||
|
},
|
||||||
|
// 修改信息
|
||||||
|
edit: function(id) {
|
||||||
|
$.modal.open("修改" + $.table._option.modalName, $.operate.editUrl(id));
|
||||||
|
},
|
||||||
|
// 修改信息,以tab页展现
|
||||||
|
editTab: function(id) {
|
||||||
|
$.modal.openTab("修改" + $.table._option.modalName, $.operate.editUrl(id));
|
||||||
},
|
},
|
||||||
// 工具栏表格树修改
|
// 工具栏表格树修改
|
||||||
editTree: function() {
|
editTree: function() {
|
||||||
|
@ -672,6 +692,22 @@
|
||||||
};
|
};
|
||||||
$.ajax(config)
|
$.ajax(config)
|
||||||
},
|
},
|
||||||
|
// 保存选项卡信息
|
||||||
|
saveTab: function(url, data) {
|
||||||
|
var config = {
|
||||||
|
url: url,
|
||||||
|
type: "post",
|
||||||
|
dataType: "json",
|
||||||
|
data: data,
|
||||||
|
beforeSend: function () {
|
||||||
|
$.modal.loading("正在处理中,请稍后...");
|
||||||
|
},
|
||||||
|
success: function(result) {
|
||||||
|
$.operate.successTabCallback(result);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
$.ajax(config)
|
||||||
|
},
|
||||||
// 保存结果弹出msg刷新table表格
|
// 保存结果弹出msg刷新table表格
|
||||||
ajaxSuccess: function (result) {
|
ajaxSuccess: function (result) {
|
||||||
if (result.code == web_status.SUCCESS) {
|
if (result.code == web_status.SUCCESS) {
|
||||||
|
@ -710,6 +746,25 @@
|
||||||
}
|
}
|
||||||
$.modal.closeLoading();
|
$.modal.closeLoading();
|
||||||
$.modal.enable();
|
$.modal.enable();
|
||||||
|
},
|
||||||
|
// 选项卡成功回调执行事件(父窗体静默更新)
|
||||||
|
successTabCallback: function(result) {
|
||||||
|
if (result.code == web_status.SUCCESS) {
|
||||||
|
var topWindow = $(window.parent.document);
|
||||||
|
var currentId = $('.page-tabs-content', topWindow).find('.active').attr('data-panel');
|
||||||
|
var $contentWindow = $('.RuoYi_iframe[data-id="' + currentId + '"]', topWindow)[0].contentWindow;
|
||||||
|
$.modal.close();
|
||||||
|
$contentWindow.$.modal.msgSuccess(result.msg);
|
||||||
|
if ($contentWindow.$("#bootstrap-table").length > 0) {
|
||||||
|
$contentWindow.$.table.refresh();
|
||||||
|
} else if ($contentWindow.$("#bootstrap-tree-table").length > 0) {
|
||||||
|
$contentWindow.$.treeTable.refresh();
|
||||||
|
}
|
||||||
|
closeItem();
|
||||||
|
} else {
|
||||||
|
$.modal.alertError(result.msg);
|
||||||
|
}
|
||||||
|
$.modal.closeLoading();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 校验封装处理
|
// 校验封装处理
|
||||||
|
@ -780,7 +835,7 @@
|
||||||
searchNode: function() {
|
searchNode: function() {
|
||||||
// 取得输入的关键字的值
|
// 取得输入的关键字的值
|
||||||
var value = $.common.trim($("#keyword").val());
|
var value = $.common.trim($("#keyword").val());
|
||||||
if ($.tree._lastValue === value) {
|
if ($.tree._lastValue == value) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// 保存最后一次搜索名称
|
// 保存最后一次搜索名称
|
||||||
|
|
|
@ -7,10 +7,10 @@
|
||||||
<title>若依管理系统</title>
|
<title>若依管理系统</title>
|
||||||
<meta name="keywords" content="若依,若依开源,若依框架,若依系统,ruoyi">
|
<meta name="keywords" content="若依,若依开源,若依框架,若依系统,ruoyi">
|
||||||
<meta name="description" content="若依基于SpringBoot2.0的权限管理系统 易读易懂、界面简洁美观。 核心技术采用Spring、MyBatis、Shiro没有任何其它重度依赖">
|
<meta name="description" content="若依基于SpringBoot2.0的权限管理系统 易读易懂、界面简洁美观。 核心技术采用Spring、MyBatis、Shiro没有任何其它重度依赖">
|
||||||
<link href="../static/css/bootstrap.min.css" th:href="@{css/bootstrap.min.css}" rel="stylesheet"/>
|
<link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
|
||||||
<link href="../static/css/font-awesome.min.css" th:href="@{css/font-awesome.min.css}" rel="stylesheet"/>
|
<link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
|
||||||
<link href="../static/css/style.css" th:href="@{css/style.css}" rel="stylesheet"/>
|
<link href="../static/css/style.css" th:href="@{/css/style.css}" rel="stylesheet"/>
|
||||||
<link href="../static/css/login.min.css" th:href="@{css/login.min.css}" rel="stylesheet"/>
|
<link href="../static/css/login.min.css" th:href="@{/css/login.min.css}" rel="stylesheet"/>
|
||||||
<link href="../static/ruoyi/css/ry-ui.css" th:href="@{/ruoyi/css/ry-ui.css?v=3.2.0}" rel="stylesheet"/>
|
<link href="../static/ruoyi/css/ry-ui.css" th:href="@{/ruoyi/css/ry-ui.css?v=3.2.0}" rel="stylesheet"/>
|
||||||
<!--[if lt IE 9]>
|
<!--[if lt IE 9]>
|
||||||
<meta http-equiv="refresh" content="0;ie.html" />
|
<meta http-equiv="refresh" content="0;ie.html" />
|
||||||
|
|
|
@ -2,59 +2,84 @@
|
||||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<head th:include="include :: header"></head>
|
<head th:include="include :: header"></head>
|
||||||
<body class="white-bg">
|
<body>
|
||||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
<div class="form-content">
|
||||||
<form class="form-horizontal m" id="form-user-add">
|
<form id="form-user-add" class="form-horizontal">
|
||||||
<input name="deptId" type="hidden" id="treeId"/>
|
<input name="deptId" type="hidden" id="treeId"/>
|
||||||
|
<h4 class="form-header h4">基本信息</h4>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label ">登录名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>用户名称:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" id="loginName" name="loginName"/>
|
<input name="userName" autocomplete="off" placeholder="请输入用户名称" class="form-control" type="text" maxlength="30"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">部门名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>归属部门:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="deptName" onclick="selectDeptTree()" readonly="true" id="treeName">
|
<input name="deptName" onclick="selectDeptTree()" id="treeName" readonly="readonly" type="text" placeholder="请选择归属部门" class="form-control"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">用户名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>手机号码:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="userName" id="userName">
|
<input name="phonenumber" autocomplete="off" placeholder="请输入手机号码" class="form-control" type="text" maxlength="11"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">密码:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>邮箱:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="password" name="password" id="password" th:value="${@config.getKey('sys.user.initPassword')}">
|
<input name="email" autocomplete="off" class="form-control email" type="text" maxlength="50" placeholder="请输入邮箱">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">邮箱:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>登录账号:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="email" id="email">
|
<input name="loginName" placeholder="请输入登录账号" autocomplete="off" class="form-control required" type="text" maxlength="30">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">手机:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>登录密码:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="phonenumber" id="phonenumber">
|
<input name="password" placeholder="请输入登录密码" autocomplete="off" class="form-control" type="password" th:value="${@config.getKey('sys.user.initPassword')}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">性别:</label>
|
<label class="col-sm-4 control-label">用户性别:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<select id="sex" class="form-control m-b" th:with="type=${@dict.getType('sys_user_sex')}">
|
<div class="input-group" style="width: 100%">
|
||||||
|
<select name="sex" class="form-control m-b" th:with="type=${@dict.getType('sys_user_sex')}">
|
||||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">状态:</label>
|
<label class="col-sm-4 control-label">用户状态:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<div class="onoffswitch">
|
<div class="onoffswitch">
|
||||||
<input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="status" name="status">
|
<input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="status">
|
||||||
<label class="onoffswitch-label" for="status">
|
<label class="onoffswitch-label" for="status">
|
||||||
<span class="onoffswitch-inner"></span>
|
<span class="onoffswitch-inner"></span>
|
||||||
<span class="onoffswitch-switch"></span>
|
<span class="onoffswitch-switch"></span>
|
||||||
|
@ -62,28 +87,56 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">岗位:</label>
|
<label class="col-xs-2 control-label">岗位:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-xs-4">
|
||||||
<select id="post" name="post" class="form-control select2-hidden-accessible" multiple="">
|
<select id="post" class="form-control select2-hidden-accessible" multiple="">
|
||||||
<option th:each="post:${posts}" th:value="${post.postId}" th:text="${post.postName}" th:disabled="${post.status == '1'}"></option>
|
<option th:each="post:${posts}" th:value="${post.postId}" th:text="${post.postName}" th:disabled="${post.status == '1'}"></option>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">角色:</label>
|
<label class="col-xs-2 control-label">角色:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-xs-10">
|
||||||
<label th:each="role:${roles}" class="check-box">
|
<label th:each="role:${roles}" class="check-box">
|
||||||
<input name="role" type="checkbox" th:value="${role.roleId}" th:text="${role.roleName}" th:disabled="${role.status == '1'}">
|
<input name="role" type="checkbox" th:value="${role.roleId}" th:text="${role.roleName}" th:disabled="${role.status == '1'}">
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<h4 class="form-header h4">其他信息</h4>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-xs-2 control-label">备注:</label>
|
||||||
|
<div class="col-xs-10">
|
||||||
|
<textarea name="remark" autocomplete="off" maxlength="500" class="form-control" rows="3"></textarea>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-offset-5 col-sm-10">
|
||||||
|
<button type="button" class="btn btn-sm btn-primary" onclick="submitHandler()"><i class="fa fa-check"></i>保 存</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-danger" onclick="closeItem()"><i class="fa fa-reply-all"></i>关 闭 </button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div th:include="include::footer"></div>
|
<div th:include="include::footer"></div>
|
||||||
<script th:src="@{/ajax/libs/select/select2.js}"></script>
|
<script th:src="@{/ajax/libs/select/select2.js}"></script>
|
||||||
<script>
|
<script>
|
||||||
|
var prefix = ctx + "system/user";
|
||||||
|
|
||||||
$("#form-user-add").validate({
|
$("#form-user-add").validate({
|
||||||
rules:{
|
rules:{
|
||||||
loginName:{
|
loginName:{
|
||||||
|
@ -91,7 +144,7 @@
|
||||||
minlength: 2,
|
minlength: 2,
|
||||||
maxlength: 20,
|
maxlength: 20,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkLoginNameUnique",
|
url: prefix + "/checkLoginNameUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
@ -119,7 +172,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
email:true,
|
email:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkEmailUnique",
|
url: prefix + "/checkEmailUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
@ -136,7 +189,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
isPhone:true,
|
isPhone:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkPhoneUnique",
|
url: prefix + "/checkPhoneUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
@ -165,47 +218,15 @@
|
||||||
|
|
||||||
function submitHandler() {
|
function submitHandler() {
|
||||||
if ($.validate.form()) {
|
if ($.validate.form()) {
|
||||||
add();
|
var data = $("#form-user-add").serializeArray();
|
||||||
}
|
var status = $("input[id='status']").is(':checked') == true ? 0 : 1;
|
||||||
}
|
|
||||||
|
|
||||||
function add() {
|
|
||||||
var userId = $("input[name='userId']").val();
|
|
||||||
var deptId = $("input[name='deptId']").val();
|
|
||||||
var loginName = $("input[name='loginName']").val();
|
|
||||||
var userName = $("input[name='userName']").val();
|
|
||||||
var password = $("input[name='password']").val();
|
|
||||||
var email = $("input[name='email']").val();
|
|
||||||
var phonenumber = $("input[name='phonenumber']").val();
|
|
||||||
var sex = $("#sex option:selected").val();
|
|
||||||
var status = $("input[name='status']").is(':checked') == true ? 0 : 1;
|
|
||||||
var roleIds = $.form.selectCheckeds("role");
|
var roleIds = $.form.selectCheckeds("role");
|
||||||
var postIds = $.form.selectSelects("post");
|
var postIds = $.form.selectSelects("post");
|
||||||
$.ajax({
|
data.push({"name": "status", "value": status});
|
||||||
cache : true,
|
data.push({"name": "roleIds", "value": roleIds});
|
||||||
type : "POST",
|
data.push({"name": "postIds", "value": postIds});
|
||||||
url : ctx + "system/user/add",
|
$.operate.saveTab(prefix + "/add", data);
|
||||||
data : {
|
|
||||||
"userId": userId,
|
|
||||||
"deptId": deptId,
|
|
||||||
"loginName": loginName,
|
|
||||||
"userName": userName,
|
|
||||||
"password": password,
|
|
||||||
"email": email,
|
|
||||||
"phonenumber": phonenumber,
|
|
||||||
"sex": sex,
|
|
||||||
"status": status,
|
|
||||||
"roleIds": roleIds,
|
|
||||||
"postIds": postIds
|
|
||||||
},
|
|
||||||
async : false,
|
|
||||||
error : function(request) {
|
|
||||||
$.modal.alertError("系统错误");
|
|
||||||
},
|
|
||||||
success : function(data) {
|
|
||||||
$.operate.successCallback(data);
|
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*用户管理-新增-选择部门树*/
|
/*用户管理-新增-选择部门树*/
|
||||||
|
|
|
@ -2,54 +2,63 @@
|
||||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<head th:include="include :: header"></head>
|
<head th:include="include :: header"></head>
|
||||||
<body class="white-bg">
|
<body>
|
||||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
<div class="form-content">
|
||||||
<form class="form-horizontal m" id="form-user-edit" th:object="${user}">
|
<form class="form-horizontal" id="form-user-edit" th:object="${user}">
|
||||||
<input name="userId" type="hidden" th:field="*{userId}" />
|
<input name="userId" type="hidden" th:field="*{userId}" />
|
||||||
<input name="deptId" type="hidden" th:field="*{deptId}" id="treeId"/>
|
<input name="deptId" type="hidden" th:field="*{deptId}" id="treeId"/>
|
||||||
|
<h4 class="form-header h4">基本信息</h4>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label ">登录名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>用户名称:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" readonly="true" th:field="*{loginName}"/>
|
<input name="userName" autocomplete="off" placeholder="请输入用户名称" class="form-control" type="text" maxlength="30" th:field="*{userName}"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">部门名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>归属部门:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="deptName" onclick="selectDeptTree()" readonly="true" id="treeName" th:field="*{dept.deptName}">
|
<input class="form-control" type="text" name="deptName" onclick="selectDeptTree()" readonly="true" id="treeName" th:field="*{dept.deptName}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">用户名称:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>手机号码:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="userName" id="userName" th:field="*{userName}">
|
<input name="phonenumber" autocomplete="off" placeholder="请输入手机号码" class="form-control" type="text" maxlength="11" th:field="*{phonenumber}"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">邮箱:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>邮箱:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="email" id="email" th:field="*{email}">
|
<input name="email" autocomplete="off" class="form-control email" type="text" maxlength="50" placeholder="请输入邮箱" th:field="*{email}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">手机:</label>
|
<label class="col-sm-4 control-label"><span style="color: red; ">*</span>登录账号:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input class="form-control" type="text" name="phonenumber" id="phonenumber" th:field="*{phonenumber}">
|
<input class="form-control" type="text" readonly="true" th:field="*{loginName}"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">性别:</label>
|
<label class="col-sm-4 control-label">用户状态:</label>
|
||||||
<div class="col-sm-8">
|
|
||||||
<select id="sex" class="form-control m-b" th:with="type=${@dict.getType('sys_user_sex')}">
|
|
||||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{sex}"></option>
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">状态:</label>
|
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<div class="onoffswitch">
|
<div class="onoffswitch">
|
||||||
<input type="checkbox" th:checked="${user.status == '0' ? true : false}" class="onoffswitch-checkbox" id="status" name="status">
|
<input type="checkbox" th:checked="${user.status == '0' ? true : false}" class="onoffswitch-checkbox" id="status">
|
||||||
<label class="onoffswitch-label" for="status">
|
<label class="onoffswitch-label" for="status">
|
||||||
<span class="onoffswitch-inner"></span>
|
<span class="onoffswitch-inner"></span>
|
||||||
<span class="onoffswitch-switch"></span>
|
<span class="onoffswitch-switch"></span>
|
||||||
|
@ -57,28 +66,68 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">岗位:</label>
|
<label class="col-sm-4 control-label">岗位:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<select id="post" name="post" class="form-control select2-hidden-accessible" multiple="">
|
<select id="post" class="form-control select2-hidden-accessible" multiple="">
|
||||||
<option th:each="post:${posts}" th:value="${post.postId}" th:text="${post.postName}" th:selected="${post.flag}" th:disabled="${post.status == '1'}"></option>
|
<option th:each="post:${posts}" th:value="${post.postId}" th:text="${post.postName}" th:selected="${post.flag}" th:disabled="${post.status == '1'}"></option>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">角色:</label>
|
<label class="col-sm-4 control-label">用户性别:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group" style="width: 100%">
|
||||||
|
<select name="sex" class="form-control m-b" th:with="type=${@dict.getType('sys_user_sex')}">
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{sex}"></option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-xs-2 control-label">角色:</label>
|
||||||
|
<div class="col-xs-10">
|
||||||
<label th:each="role:${roles}" class="check-box">
|
<label th:each="role:${roles}" class="check-box">
|
||||||
<input name="role" type="checkbox" th:value="${role.roleId}" th:text="${role.roleName}" th:checked="${role.flag}" th:disabled="${role.status == '1'}">
|
<input name="role" type="checkbox" th:value="${role.roleId}" th:text="${role.roleName}" th:checked="${role.flag}" th:disabled="${role.status == '1'}">
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<h4 class="form-header h4">其他信息</h4>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-xs-2 control-label">备注:</label>
|
||||||
|
<div class="col-xs-10">
|
||||||
|
<textarea name="remark" autocomplete="off" maxlength="500" class="form-control" rows="3">[[*{remark}]]</textarea>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-offset-5 col-sm-10">
|
||||||
|
<button type="button" class="btn btn-sm btn-primary" onclick="submitHandler()"><i class="fa fa-check"></i>保 存</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-danger" onclick="closeItem()"><i class="fa fa-reply-all"></i>关 闭 </button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div th:include="include::footer"></div>
|
<div th:include="include::footer"></div>
|
||||||
<script th:src="@{/ajax/libs/select/select2.js}"></script>
|
<script th:src="@{/ajax/libs/select/select2.js}"></script>
|
||||||
<script>
|
<script>
|
||||||
|
var prefix = ctx + "system/user";
|
||||||
|
|
||||||
$("#form-user-edit").validate({
|
$("#form-user-edit").validate({
|
||||||
rules:{
|
rules:{
|
||||||
userName:{
|
userName:{
|
||||||
|
@ -91,7 +140,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
email:true,
|
email:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkEmailUnique",
|
url: prefix + "/checkEmailUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
@ -111,7 +160,7 @@
|
||||||
required:true,
|
required:true,
|
||||||
isPhone:true,
|
isPhone:true,
|
||||||
remote: {
|
remote: {
|
||||||
url: ctx + "system/user/checkPhoneUnique",
|
url: prefix + "/checkPhoneUnique",
|
||||||
type: "post",
|
type: "post",
|
||||||
dataType: "json",
|
dataType: "json",
|
||||||
data: {
|
data: {
|
||||||
|
@ -135,51 +184,20 @@
|
||||||
"phonenumber":{
|
"phonenumber":{
|
||||||
remote: "手机号码已经存在"
|
remote: "手机号码已经存在"
|
||||||
}
|
}
|
||||||
},
|
|
||||||
submitHandler:function(form){
|
|
||||||
edit();
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
function submitHandler() {
|
function submitHandler() {
|
||||||
if ($.validate.form()) {
|
if ($.validate.form()) {
|
||||||
edit();
|
var data = $("#form-user-edit").serializeArray();
|
||||||
}
|
var status = $("input[id='status']").is(':checked') == true ? 0 : 1;
|
||||||
}
|
|
||||||
|
|
||||||
function edit() {
|
|
||||||
var userId = $("input[name='userId']").val();
|
|
||||||
var deptId = $("input[name='deptId']").val();
|
|
||||||
var userName = $("input[name='userName']").val();
|
|
||||||
var email = $("input[name='email']").val();
|
|
||||||
var phonenumber = $("input[name='phonenumber']").val();
|
|
||||||
var sex = $("#sex option:selected").val();
|
|
||||||
var status = $("input[name='status']").is(':checked') == true ? 0 : 1;
|
|
||||||
var roleIds = $.form.selectCheckeds("role");
|
var roleIds = $.form.selectCheckeds("role");
|
||||||
var postIds = $.form.selectSelects("post");
|
var postIds = $.form.selectSelects("post");
|
||||||
$.ajax({
|
data.push({"name": "status", "value": status});
|
||||||
cache : true,
|
data.push({"name": "roleIds", "value": roleIds});
|
||||||
type : "POST",
|
data.push({"name": "postIds", "value": postIds});
|
||||||
url : ctx + "system/user/edit",
|
$.operate.saveTab(prefix + "/edit", data);
|
||||||
data : {
|
|
||||||
"userId": userId,
|
|
||||||
"deptId": deptId,
|
|
||||||
"userName": userName,
|
|
||||||
"email": email,
|
|
||||||
"phonenumber": phonenumber,
|
|
||||||
"sex": sex,
|
|
||||||
"status": status,
|
|
||||||
"roleIds": roleIds,
|
|
||||||
"postIds": postIds
|
|
||||||
},
|
|
||||||
async : false,
|
|
||||||
error : function(request) {
|
|
||||||
$.modal.alertError("系统错误");
|
|
||||||
},
|
|
||||||
success : function(data) {
|
|
||||||
$.operate.successCallback(data);
|
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*用户管理-修改-选择部门树*/
|
/*用户管理-修改-选择部门树*/
|
||||||
|
|
|
@ -64,10 +64,10 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
||||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:user:add">
|
<a class="btn btn-success" onclick="$.operate.addTab()" shiro:hasPermission="system:user:add">
|
||||||
<i class="fa fa-plus"></i> 新增
|
<i class="fa fa-plus"></i> 新增
|
||||||
</a>
|
</a>
|
||||||
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()" shiro:hasPermission="system:user:edit">
|
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.editTab()" shiro:hasPermission="system:user:edit">
|
||||||
<i class="fa fa-edit"></i> 修改
|
<i class="fa fa-edit"></i> 修改
|
||||||
</a>
|
</a>
|
||||||
<a class="btn btn-danger btn-del disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:user:remove">
|
<a class="btn btn-danger btn-del disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:user:remove">
|
||||||
|
@ -168,7 +168,7 @@
|
||||||
align: 'center',
|
align: 'center',
|
||||||
formatter: function(value, row, index) {
|
formatter: function(value, row, index) {
|
||||||
var actions = [];
|
var actions = [];
|
||||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.userId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.editTab(\'' + row.userId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.userId + '\')"><i class="fa fa-remove"></i>删除</a> ');
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.userId + '\')"><i class="fa fa-remove"></i>删除</a> ');
|
||||||
actions.push('<a class="btn btn-info btn-xs ' + resetPwdFlag + '" href="#" onclick="resetPwd(\'' + row.userId + '\')"><i class="fa fa-key"></i>重置</a>');
|
actions.push('<a class="btn btn-info btn-xs ' + resetPwdFlag + '" href="#" onclick="resetPwd(\'' + row.userId + '\')"><i class="fa fa-key"></i>重置</a>');
|
||||||
return actions.join('');
|
return actions.join('');
|
||||||
|
|
Loading…
Reference in New Issue