Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
guns-vip
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenjunxiong
guns-vip
Commits
5a5d2145
Commit
5a5d2145
authored
Jul 29, 2019
by
fengshuonan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
表单弹框样式修改
parent
b7acae5f
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
104 additions
and
62 deletions
+104
-62
guns-base-support/guns-sys/src/main/webapp/assets/common/js/common.js
+2
-1
guns-base-support/guns-sys/src/main/webapp/assets/expand/module/func/func.js
+71
-0
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/dept/dept.js
+8
-15
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/position/position.js
+8
-15
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/role/role.js
+9
-16
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/user/user.js
+6
-15
No files found.
guns-base-support/guns-sys/src/main/webapp/assets/common/js/common.js
View file @
5a5d2145
...
...
@@ -119,7 +119,8 @@ layui.config({
selectPlus
:
'../../expand/module/selectPlus/selectPlus'
,
ax
:
'../../expand/module/ax/ax'
,
ztree
:
'../../expand/module/ztree/ztree-object'
,
iconPicker
:
'../../expand/module/iconPicker/iconPicker'
iconPicker
:
'../../expand/module/iconPicker/iconPicker'
,
func
:
'../../expand/module/func/func'
}).
use
([
'admin'
],
function
()
{
var
$
=
layui
.
jquery
;
var
admin
=
layui
.
admin
;
...
...
guns-base-support/guns-sys/src/main/webapp/assets/expand/module/func/func.js
0 → 100644
View file @
5a5d2145
/**
* 高频方法集
*
* @author fengshuonan
* @Date 2019/7/29 21:20
*/
layui
.
define
([
'jquery'
,
'layer'
,
'admin'
,
'table'
],
function
(
exports
)
{
var
$
=
layui
.
$
;
var
layer
=
layui
.
layer
;
var
admin
=
layui
.
admin
;
var
table
=
layui
.
table
;
var
func
=
{
/**
* 获取内部高度,返回数值
*/
getClientHeight
:
function
()
{
let
clientHeight
=
0
;
if
(
document
.
body
.
clientHeight
&&
document
.
documentElement
.
clientHeight
)
{
clientHeight
=
(
document
.
body
.
clientHeight
<
document
.
documentElement
.
clientHeight
)
?
document
.
body
.
clientHeight
:
document
.
documentElement
.
clientHeight
;
}
else
{
clientHeight
=
(
document
.
body
.
clientHeight
>
document
.
documentElement
.
clientHeight
)
?
document
.
body
.
clientHeight
:
document
.
documentElement
.
clientHeight
;
}
return
clientHeight
;
},
/**
* 获取内部高度,返回字符串
*/
getClientHeightPx
:
function
()
{
return
Feng
.
getClientHeight
()
+
'px'
;
},
/**
* 打开表单的弹框
*/
open
:
function
(
param
)
{
//计算高度
let
clientHeight
=
func
.
getClientHeight
();
if
(
param
.
height
)
{
if
(
clientHeight
<
param
.
height
)
{
param
.
area
=
[
'1000px'
,
clientHeight
+
"px"
];
}
else
{
param
.
area
=
[
'1000px'
,
param
.
height
+
"px"
];
}
}
else
{
param
.
area
=
[
'1000px'
,
clientHeight
+
"px"
];
}
param
.
skin
=
'layui-layer-admin'
;
param
.
offset
=
'35px'
;
param
.
type
=
2
;
admin
.
putTempData
(
'formOk'
,
false
);
param
.
end
=
function
()
{
layer
.
closeAll
(
'tips'
);
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
param
.
tableId
);
};
param
.
fixed
=
false
;
param
.
resize
=
false
;
param
.
shade
=
.
1
;
return
top
.
layui
.
layer
.
open
(
param
);
}
};
exports
(
'func'
,
func
);
});
\ No newline at end of file
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/dept/dept.js
View file @
5a5d2145
layui
.
use
([
'table'
,
'admin'
,
'ax'
,
'ztree'
],
function
()
{
layui
.
use
([
'table'
,
'admin'
,
'ax'
,
'ztree'
,
'func'
],
function
()
{
var
$
=
layui
.
$
;
var
table
=
layui
.
table
;
var
$ax
=
layui
.
ax
;
var
admin
=
layui
.
admin
;
var
$ZTree
=
layui
.
ztree
;
var
func
=
layui
.
func
;
/**
* 系统管理--部门管理
...
...
@@ -54,15 +55,11 @@ layui.use(['table', 'admin', 'ax', 'ztree'], function () {
* 弹出添加
*/
Dept
.
openAddDept
=
function
()
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
height
:
530
,
title
:
'添加部门'
,
content
:
Feng
.
ctxPath
+
'/dept/dept_add'
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Dept
.
tableId
);
}
tableId
:
Dept
.
tableId
});
};
...
...
@@ -72,15 +69,11 @@ layui.use(['table', 'admin', 'ax', 'ztree'], function () {
* @param data 点击按钮时候的行数据
*/
Dept
.
onEditDept
=
function
(
data
)
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
height
:
530
,
title
:
'编辑部门'
,
content
:
Feng
.
ctxPath
+
"/dept/dept_update?deptId="
+
data
.
deptId
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Dept
.
tableId
);
}
tableId
:
Dept
.
tableId
});
};
...
...
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/position/position.js
View file @
5a5d2145
layui
.
use
([
'table'
,
'admin'
,
'ax'
,
'form'
],
function
()
{
layui
.
use
([
'table'
,
'admin'
,
'ax'
,
'form'
,
'func'
],
function
()
{
var
$
=
layui
.
$
;
var
table
=
layui
.
table
;
var
$ax
=
layui
.
ax
;
var
admin
=
layui
.
admin
;
var
form
=
layui
.
form
;
var
func
=
layui
.
func
;
/**
* 职位表管理
...
...
@@ -44,15 +45,11 @@ layui.use(['table', 'admin', 'ax', 'form'], function () {
* 弹出添加对话框
*/
Position
.
openAddDlg
=
function
()
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
height
:
470
,
title
:
'添加职位'
,
content
:
Feng
.
ctxPath
+
'/position/add'
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Position
.
tableId
);
}
tableId
:
Position
.
tableId
});
};
...
...
@@ -62,15 +59,11 @@ layui.use(['table', 'admin', 'ax', 'form'], function () {
* @param data 点击按钮时候的行数据
*/
Position
.
openEditDlg
=
function
(
data
)
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
height
:
470
,
title
:
'修改职位'
,
content
:
Feng
.
ctxPath
+
'/position/edit?positionId='
+
data
.
positionId
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Position
.
tableId
);
}
tableId
:
Position
.
tableId
});
};
...
...
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/role/role.js
View file @
5a5d2145
layui
.
use
([
'layer'
,
'form'
,
'table'
,
'admin'
,
'ax'
],
function
()
{
layui
.
use
([
'layer'
,
'form'
,
'table'
,
'admin'
,
'ax'
,
'func'
],
function
()
{
var
$
=
layui
.
$
;
var
layer
=
layui
.
layer
;
var
form
=
layui
.
form
;
var
table
=
layui
.
table
;
var
$ax
=
layui
.
ax
;
var
admin
=
layui
.
admin
;
var
func
=
layui
.
func
;
/**
* 系统管理--角色管理
...
...
@@ -45,15 +46,11 @@ layui.use(['layer', 'form', 'table', 'admin', 'ax'], function () {
* 弹出添加角色
*/
Role
.
openAddRole
=
function
()
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
height
:
470
,
title
:
'添加角色'
,
content
:
Feng
.
ctxPath
+
'/role/role_add'
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Role
.
tableId
);
}
tableId
:
Role
.
tableId
});
};
...
...
@@ -63,15 +60,11 @@ layui.use(['layer', 'form', 'table', 'admin', 'ax'], function () {
* @param data 点击按钮时候的行数据
*/
Role
.
onEditRole
=
function
(
data
)
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
title
:
'添加角色'
,
func
.
open
({
height
:
470
,
title
:
'修改角色'
,
content
:
Feng
.
ctxPath
+
"/role/role_edit?roleId="
+
data
.
roleId
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
Role
.
tableId
);
}
tableId
:
Role
.
tableId
});
};
...
...
guns-base-support/guns-sys/src/main/webapp/assets/modular/system/user/user.js
View file @
5a5d2145
layui
.
use
([
'layer'
,
'form'
,
'table'
,
'ztree'
,
'laydate'
,
'admin'
,
'ax'
],
function
()
{
layui
.
use
([
'layer'
,
'form'
,
'table'
,
'ztree'
,
'laydate'
,
'admin'
,
'ax'
,
'func'
],
function
()
{
var
layer
=
layui
.
layer
;
var
form
=
layui
.
form
;
var
table
=
layui
.
table
;
...
...
@@ -6,6 +6,7 @@ layui.use(['layer', 'form', 'table', 'ztree', 'laydate', 'admin', 'ax'], functio
var
$ax
=
layui
.
ax
;
var
laydate
=
layui
.
laydate
;
var
admin
=
layui
.
admin
;
var
func
=
layui
.
func
;
/**
* 系统管理--用户管理
...
...
@@ -62,15 +63,10 @@ layui.use(['layer', 'form', 'table', 'ztree', 'laydate', 'admin', 'ax'], functio
* 弹出添加用户对话框
*/
MgrUser
.
openAddUser
=
function
()
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
title
:
'添加用户'
,
content
:
Feng
.
ctxPath
+
'/mgr/user_add'
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
MgrUser
.
tableId
);
}
tableId
:
MgrUser
.
tableId
});
};
...
...
@@ -80,15 +76,10 @@ layui.use(['layer', 'form', 'table', 'ztree', 'laydate', 'admin', 'ax'], functio
* @param data 点击按钮时候的行数据
*/
MgrUser
.
onEditUser
=
function
(
data
)
{
admin
.
putTempData
(
'formOk'
,
false
);
top
.
layui
.
admin
.
open
({
area
:
[
'1000px'
,
Feng
.
getClientHeightPx
()],
type
:
2
,
func
.
open
({
title
:
'编辑用户'
,
content
:
Feng
.
ctxPath
+
'/mgr/user_edit?userId='
+
data
.
userId
,
end
:
function
()
{
admin
.
getTempData
(
'formOk'
)
&&
table
.
reload
(
MgrUser
.
tableId
);
}
tableId
:
MgrUser
.
tableId
});
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment