Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
h5
/
account
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit b68230a6
authored
Aug 06, 2021
by
李长胜
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
2021-08-06 样式修改
2 parents
973ce8f3
4e4076e9
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
1415 additions
and
289 deletions
html/components/header.html
html/employee/add.html
html/employee/index.html
html/employee/validPeriod.html
html/merchant/edit.html
html/merchant/index.html
html/merchant/validPeriodForm.html
html/role/add.html
html/role/detail.html
html/role/index.html
html/role/tree.html
js/gtree.js
js/helper.js
js/load.js
js/request.js
js/xm-select.js
js/ztree.js
login.html
html/components/header.html
View file @
b68230a
...
@@ -35,7 +35,8 @@
...
@@ -35,7 +35,8 @@
var
_href
=
'/html/'
+
_path
var
_href
=
'/html/'
+
_path
$
(
'.header-nav-item'
).
each
(
function
(
i
,
e
)
{
$
(
'.header-nav-item'
).
each
(
function
(
i
,
e
)
{
var
_hr
=
$
(
e
).
find
(
'a'
).
attr
(
'href'
)
var
_hr
=
$
(
e
).
find
(
'a'
).
attr
(
'href'
)
if
(
_hr
.
startsWith
(
_href
))
{
if
(
_hr
.
indexOf
(
_href
)
!==
-
1
)
{
// if (_hr.startsWith(_href)) {
$
(
e
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
$
(
e
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
return
false
return
false
}
}
...
...
html/employee/add.html
View file @
b68230a
...
@@ -103,21 +103,18 @@
...
@@ -103,21 +103,18 @@
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<div
class=
"upload-img-box"
>
<div
class=
"upload-img-box"
>
<div
class=
"icon-add img-add show"
>
+
</div>
<div
class=
"icon-add img-add show"
>
+
</div>
<img
class=
"upload-img upload-img-wh hide"
id=
"img"
src=
""
>
<img
class=
"upload-img upload-img-wh hide"
id=
"img"
>
<input
type=
"file"
id=
"upload"
name=
"merhcnatImg"
ref=
"file"
<input
type=
"file"
id=
"upload"
name=
"merhcnatImg"
ref=
"file"
class=
"upload upload-img-box upload-img-wh"
accept=
"image/png, image/jpeg, image/gif, image/jpg"
class=
"upload upload-img-box upload-img-wh"
accept=
"image/png, image/jpeg, image/gif, image/jpg"
data-idx=
"0"
style=
"opacity: 0;"
>
data-idx=
"0"
style=
"opacity: 0;"
>
</div>
</div>
<span
class=
"tips"
>
图片格式仅支持JPG,PNG格式,大小1M以内
</span>
<span
class=
"tips"
>
图片格式仅支持JPG,PNG格式,大小1M以内
</span>
<!-- <div class="layui-upload-img" id="uploadImg">
<i class="layui-icon"></i>
</div> -->
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
邮箱:
</label>
<label
class=
"layui-form-label"
>
邮箱:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"staffEmail"
lay-verify=
"
email
"
placeholder=
"请输入邮箱"
autocomplete=
"off"
class=
"layui-input"
/>
<input
type=
"text"
name=
"staffEmail"
lay-verify=
""
placeholder=
"请输入邮箱"
autocomplete=
"off"
class=
"layui-input"
/>
</div>
</div>
</div>
</div>
...
@@ -142,7 +139,9 @@
...
@@ -142,7 +139,9 @@
//Demo
//Demo
layui
.
use
([
'form'
,
'upload'
,
'gtree'
,
'request'
,
'helper'
],
function
()
{
layui
.
use
([
'form'
,
'upload'
,
'gtree'
,
'request'
,
'helper'
],
function
()
{
console
.
log
(
qs
(
'id'
))
console
.
log
(
qs
(
'merchantId'
))
var
merchantId
=
qs
(
'merchantId'
)
var
id
=
qs
(
'id'
)
var
form
=
layui
.
form
var
form
=
layui
.
form
var
upload
=
layui
.
upload
var
upload
=
layui
.
upload
var
tree
=
layui
.
gtree
var
tree
=
layui
.
gtree
...
@@ -150,18 +149,14 @@
...
@@ -150,18 +149,14 @@
var
helper
=
layui
.
helper
var
helper
=
layui
.
helper
var
$
=
layui
.
$
var
$
=
layui
.
$
var
merchantFileRequest
=
{}
var
merchantFileRequest
=
{}
var
id
=
null
var
employeeForm
=
{}
var
employeeForm
=
{}
var
pwd
=
$
(
'#password'
)
// 密码输入框
var
pwd
=
$
(
'#password'
)
// 密码输入框
var
resetpsw
=
$
(
'#resetpsw'
)
var
resetpsw
=
$
(
'#resetpsw'
)
pwd
.
attr
(
'readonly'
,
false
)
pwd
.
attr
(
'readonly'
,
false
)
if
(
qs
(
'id'
))
{
if
(
id
)
{
id
=
qs
(
'id'
)
resetpsw
.
removeClass
(
'hide'
)
resetpsw
.
removeClass
(
'hide'
)
resetpsw
.
addClass
(
'show'
)
resetpsw
.
addClass
(
'show'
)
}
else
{
// resetpsw.addClass('hide')
}
}
// 重置密码
// 重置密码
resetpsw
.
on
(
'click'
,
function
()
{
resetpsw
.
on
(
'click'
,
function
()
{
...
@@ -173,7 +168,7 @@
...
@@ -173,7 +168,7 @@
findRoleList
()
findRoleList
()
// 查询角色权限列表
// 查询角色权限列表
function
findRoleList
()
{
function
findRoleList
()
{
var
params
=
{
method
:
'org.ore.api.role.list'
,
id
:
31
}
var
params
=
{
method
:
'org.ore.api.role.list'
,
id
:
merchantId
}
request
(
params
,
function
(
res
)
{
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
if
(
res
.
code
==
'0'
)
{
var
list
=
res
.
data
var
list
=
res
.
data
...
@@ -187,23 +182,23 @@
...
@@ -187,23 +182,23 @@
}
}
// 可见商户
// 可见商户
var
visibleMerchantParams
=
{
id
:
31
,
method
:
'cn.com.glsx.merchants.merchant.findMerchantTree'
}
var
visibleMerchantParams
=
{
id
:
merchantId
,
method
:
'cn.com.glsx.merchants.merchant.findMerchantTree'
}
var
visibleMerchant
=
{}
var
visibleMerchant
=
{}
request
(
visibleMerchantParams
,
function
(
res
)
{
request
(
visibleMerchantParams
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
if
(
res
.
code
==
'0'
)
{
if
(
id
)
{
if
(
id
)
{
getById
(
function
(
p
)
{
getById
(
function
(
checkedList
)
{
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
,
{
onNodeCreated
:
function
(
event
,
treeId
,
treeNode
)
{
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
,
{
checkedList
:
checkedList
}
if
(
p
.
indexOf
(
treeNode
.
id
+
''
)
!=
-
1
)
{
// { onNodeCreated: function(event, treeId, treeNode) {
treeNode
.
checked
=
true
// if (p.indexOf(treeNode.id+'') != -1) {
visibleMerchant
.
updateNode
(
treeNode
);
// treeNode.checked = true
}
// visibleMerchant.updateNode(treeNode);
}})
// }
visibleMerchant
.
expandAll
(
true
)
// }}
)
})
})
}
else
{
}
else
{
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
)
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
)
visibleMerchant
.
expandAll
(
true
)
}
}
}
}
})
})
...
@@ -221,11 +216,13 @@
...
@@ -221,11 +216,13 @@
staffPhone
:
data
.
staffPhone
,
staffPhone
:
data
.
staffPhone
,
password
:
data
.
password
,
password
:
data
.
password
,
// visibleInferiorMer: "1",
// visibleInferiorMer: "1",
roleIds
:
data
.
roleIds
.
join
(
''
),
roleIds
:
+
data
.
roleIds
.
join
(
''
),
staffEmail
:
data
.
staffEmail
,
staffEmail
:
data
.
staffEmail
,
staffJob
:
data
.
staffJob
,
staffJob
:
data
.
staffJob
,
}
}
merchantFileRequest
=
{
fileName
:
data
.
merchantFileResponse
.
fileName
,
fileUrl
:
data
.
merchantFileResponse
.
fileUrl
}
if
(
data
.
merchantFileResponse
)
{
merchantFileRequest
=
{
fileName
:
data
.
merchantFileResponse
.
fileName
,
fileUrl
:
data
.
merchantFileResponse
.
fileUrl
}
}
var
imgEl
=
$
(
'#img'
)
var
imgEl
=
$
(
'#img'
)
var
addEl
=
$
(
'.img-add'
)
var
addEl
=
$
(
'.img-add'
)
imgEl
.
attr
(
'src'
,
merchantFileRequest
.
fileUrl
)
imgEl
.
attr
(
'src'
,
merchantFileRequest
.
fileUrl
)
...
@@ -233,8 +230,8 @@
...
@@ -233,8 +230,8 @@
imgEl
.
addClass
(
'show'
)
imgEl
.
addClass
(
'show'
)
addEl
.
removeClass
(
'show'
)
addEl
.
removeClass
(
'show'
)
addEl
.
addClass
(
'hide'
)
addEl
.
addClass
(
'hide'
)
//
var visibleInferiorMerArr = data.visibleInferiorMer.split(',')
var
visibleInferiorMerArr
=
data
.
visibleInferiorMer
.
split
(
','
)
var
visibleInferiorMerArr
=
"34,38"
.
split
(
','
)
// var visibleInferiorMerArr = [32, 38]
callback
(
visibleInferiorMerArr
)
callback
(
visibleInferiorMerArr
)
}
}
console
.
log
(
employeeForm
)
console
.
log
(
employeeForm
)
...
@@ -282,12 +279,22 @@
...
@@ -282,12 +279,22 @@
}).
join
(
','
)
}).
join
(
','
)
var
otherParams
=
{
var
otherParams
=
{
visibleInferiorMer
:
visibleInferiorMer
,
visibleInferiorMer
:
visibleInferiorMer
,
merchantFileRequest
:
JSON
.
stringify
(
merchantFileRequest
)
// merchantFileRequest: JSON.stringify(merchantFileRequest),
merchantId
:
merchantId
}
}
var
params
=
helper
.
clone
(
true
,
{
method
:
'cn.com.glsx.merchants.staff.saveStaff'
,
merchantId
:
31
},
data
.
field
,
otherParams
)
if
(
merchantFileRequest
.
fileName
)
{
otherParams
.
merchantFileRequest
=
JSON
.
stringify
(
merchantFileRequest
)
}
else
if
(
id
)
{
otherParams
.
id
=
id
otherParams
.
method
=
'cn.com.glsx.merchants.staff.updateStaff'
}
else
{
otherParams
.
method
=
'cn.com.glsx.merchants.staff.saveStaff'
}
var
params
=
helper
.
clone
(
true
,
data
.
field
,
otherParams
)
request
(
params
,
function
(
result
)
{
request
(
params
,
function
(
result
)
{
if
(
result
.
code
==
'0'
)
{
if
(
result
.
code
==
'0'
)
{
window
.
history
.
back
()
//
window.history.back()
layer
.
msg
(
'操作成功'
,
{
layer
.
msg
(
'操作成功'
,
{
icon
:
1
icon
:
1
})
})
...
...
html/employee/index.html
View file @
b68230a
<!DOCTYPE html>
<!DOCTYPE html>
<html
lang=
"zh"
>
<html
lang=
"zh"
>
<<<<<<
< HEAD
<
head
>
<
head
>
<meta
charset=
"utf-8"
/>
<meta
charset=
"utf-8"
/>
...
@@ -39,6 +40,28 @@
...
@@ -39,6 +40,28 @@
<i
class=
"layui-icon layui-icon-add-circle"
></i>
<i
class=
"layui-icon layui-icon-add-circle"
></i>
创建员工
创建员工
</button>
</button>
=======
<head>
<meta
charset=
"utf-8"
/>
<meta
content=
"IE=edge"
/>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1.0"
/>
<meta
name=
"description"
content=
"广联帐户管理中心-员工管理"
/>
<meta
name=
"author"
content=
"GLSX Web Team"
/>
<meta
name=
"keywords"
itemprop=
"keywords"
content=
"广联,帐户管理,员工管理"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/employee.css"
/>
<title>
员工管理
</title>
</head>
<body>
<div
id=
"app"
>
<main>
<div
class=
"bg-white"
>
<form
action=
""
class=
"layui-form layui-form-pane"
lay-filter=
"employeeForm"
>
<div
class=
"layui-form-item"
pane
>
<button
type=
"button"
class=
"layui-btn layui-btn-normal"
id=
"addEmployee"
>
<i
class=
"layui-icon"
>

</i>
创建员工
</button>
<div
class=
"layui-inline"
pane
>
<div
class=
"layui-inline"
pane
>
<label
class=
"layui-form-label"
>
商户名称
</label>
<label
class=
"layui-form-label"
>
商户名称
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
...
@@ -50,8 +73,37 @@
...
@@ -50,8 +73,37 @@
<div
class=
"layui-inline"
>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
创建者
</label>
<label
class=
"layui-form-label"
>
创建者
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"createdName"
required
lay-verify=
"required"
placeholder=
"请输入创建者"
autocomplete=
"off"
class=
"layui-input"
/>
</div>
</div>
>>>>>>> 4e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
<div
class=
"layui-inline"
pane
>
<label
class=
"layui-form-label"
>
商户名称
</label>
<div
class=
"layui-input-block"
>
<select
name=
"merchantId"
id=
"merchantName"
lay-verify=
"required"
>
</select>
</div>
</div>
<<<<<<
< HEAD
</
div
>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
创建者
</label>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"createdName"
required
lay-verify=
"required"
placeholder=
"请输入创建者"
<input
type=
"text"
name=
"createdName"
required
lay-verify=
"required"
placeholder=
"请输入创建者"
autocomplete=
"off"
class=
"layui-input"
/>
autocomplete=
"off"
class=
"layui-input"
/>
=======
<div
class=
"layui-inline"
pane
>
<div
class=
"layui-input-inline"
>
<select
name=
"type"
lay-verify=
"required"
>
<option
value=
""
></option>
<option
value=
"0"
>
员工姓名
</option>
<option
value=
"1"
>
手机号
</option>
</select>
</div>
<div
class=
"layui-input-inline"
>
<input
type=
"text"
name=
"keywords"
required
lay-verify=
"required"
placeholder=
"请输入"
autocomplete=
"off"
class=
"layui-input"
/>
</div>
>>>>>>> 4e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
</div>
</div>
</div>
</div>
<div
class=
"layui-inline"
pane
>
<div
class=
"layui-inline"
pane
>
...
@@ -64,6 +116,7 @@
...
@@ -64,6 +116,7 @@
<option
value=
"2"
>
已注销
</option>
<option
value=
"2"
>
已注销
</option>
</select>
</select>
</div>
</div>
<<<<<<
< HEAD
</
div
>
</
div
>
<div
class=
"layui-inline"
pane
>
<div
class=
"layui-inline"
pane
>
<div
class=
"layui-input-inline"
>
<div
class=
"layui-input-inline"
>
...
@@ -141,6 +194,69 @@
...
@@ -141,6 +194,69 @@
if
(
isResetPageNum
)
{
if
(
isResetPageNum
)
{
options
.
page
=
{
options
.
page
=
{
curr
:
1
curr
:
1
=======
<
/form
>
<
table
id
=
"employeeTable"
lay
-
filter
=
"employeeTool"
><
/table
>
<
/div
>
<
/main
>
<
/div
>
<
script
src
=
"https://www.layuicdn.com/layui/layui.js"
>
</script>
<script
src=
"/js/load.js"
></script>
<script>
layui
.
use
([
'table'
,
'request'
,
'form'
,
'helper'
],
function
()
{
var
request
=
layui
.
request
var
table
=
layui
.
table
var
form
=
layui
.
form
var
helper
=
layui
.
helper
var
$
=
layui
.
$
// 商户名称列表
var
merchantName
=
$
(
"#merchantName"
)
findAllMerchant
()
//创建table实例
var
employeeTable
=
table
.
render
({
elem
:
'#employeeTable'
,
page
:
true
,
cols
:
[
[
//表头
{
field
:
''
,
title
:
'序号'
,
type
:
'numbers'
,
width
:
80
,
fixed
:
'left'
},
{
field
:
'staffName'
,
title
:
'员工姓名'
,
width
:
120
},
{
field
:
'staffCode'
,
title
:
'员工号'
},
{
field
:
'roleName'
,
title
:
'角色'
},
{
field
:
'staffPhone'
,
title
:
'登录手机号'
,
width
:
125
},
{
field
:
'password'
,
title
:
'登录密码'
},
{
field
:
'statusName'
,
title
:
'状态'
},
{
field
:
'createdAccount'
,
title
:
'创建者'
},
{
field
:
'merchantName'
,
title
:
'商户名(商户号)'
,
width
:
160
},
{
field
:
'createdTime'
,
title
:
'更新时间'
,
width
:
160
},
{
fixed
:
'right'
,
title
:
'操作'
,
width
:
240
,
align
:
'center'
,
toolbar
:
'#employeeBar'
}
]
]
})
getTabelList
(
employeeTable
)
// 获取table列表接口
function
getTabelList
(
table
,
search
,
isResetPageNum
)
{
search
=
search
||
{}
var
params
=
helper
.
clone
(
false
,
{
pageNum
:
table
.
config
.
index
,
pageSize
:
table
.
config
.
limit
,
method
:
'cn.com.glsx.merchants.staff.findStaffByPage'
},
search
)
request
(
params
,
function
(
res
)
{
console
.
log
(
res
)
// table.reload('testReload', {
// data: res.data.data
// })
var
data
=
res
.
data
var
options
=
{
data
:
data
.
data
}
if
(
isResetPageNum
)
{
options
.
page
=
{
curr
:
1
}
>>>>>>>
4
e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
}
}
}
}
table
.
reload
(
options
)
table
.
reload
(
options
)
...
@@ -178,13 +294,34 @@
...
@@ -178,13 +294,34 @@
method
:
'cn.com.glsx.merchants.staff.deleteStaff'
,
method
:
'cn.com.glsx.merchants.staff.deleteStaff'
,
id
:
data
.
id
id
:
data
.
id
}
}
<<<<<<<
HEAD
request
(
params
,
function
(
res
)
{
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
if
(
res
.
code
==
'0'
)
{
layer
.
close
(
index
)
layer
.
close
(
index
)
console
.
log
(
'shanchu'
)
console
.
log
(
'shanchu'
)
getTabelList
(
employeeTable
)
getTabelList
(
employeeTable
)
=======
})
}
// table工具条事件
table
.
on
(
'tool(employeeTool)'
,
function
(
obj
)
{
var
data
=
obj
.
data
var
layEvent
=
obj
.
event
var
tr
=
obj
.
tr
if
(
layEvent
===
'detail'
)
{
go
(
'employee'
,
'detail'
,
{
id
:
data
.
id
})
}
else
if
(
layEvent
===
'edit'
)
{
go
(
'employee'
,
'add'
,
{
id
:
data
.
id
,
merchantId
:
data
.
merchantId
})
}
else
if
(
layEvent
===
'del'
)
{
layer
.
confirm
(
'真的删除行么'
,
function
(
index
)
{
// obj.del() //删除对应行(tr)的DOM结构,并更新缓存
var
params
=
{
method
:
'cn.com.glsx.merchants.staff.deleteStaff'
,
id
:
data
.
id
>>>>>>>
4
e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
}
}
})
})
<<<<<<<
HEAD
//向服务端发送删除指令
//向服务端发送删除指令
})
})
}
else
if
(
layEvent
===
'updateTime'
)
{
}
else
if
(
layEvent
===
'updateTime'
)
{
...
@@ -217,6 +354,64 @@
...
@@ -217,6 +354,64 @@
}
}
})
})
}
}
=======
}
else
if
(
layEvent
===
'updateTime'
)
{
layer
.
open
({
type
:
2
,
title
:
'修改账户的有效期'
,
area
:
[
'600px'
,
'320px'
],
fixed
:
false
,
//不固定
// maxmin: true,
btn
:
[
'确定'
,
'取消'
],
content
:
'validPeriod.html?id='
+
data
.
id
+
'&effectiveTime='
+
data
.
effectiveTime
,
yes
:
function
(
index
,
layero
)
{
var
body
=
layer
.
getChildFrame
(
'body'
,
index
)
helper
.
store
.
set
(
'isRefresh'
,
false
)
body
.
find
(
'#periodVerifyBtn'
).
click
()
},
end
:
function
()
{
var
isRefresh
=
helper
.
store
.
get
(
'isRefresh'
)
if
(
isRefresh
)
{
getTabelList
(
employeeTable
)
layer
.
msg
(
'修改成功'
,
{
icon
:
1
})
}
helper
.
store
.
remove
(
'isRefresh'
)
},
})
}
})
// 新增点击事件
$
(
'#addEmployee'
).
on
(
'click'
,
function
()
{
var
value
=
merchantName
.
val
()
if
(
value
)
{
go
(
'employee'
,
'add'
,
{
merchantId
:
value
})
}
else
{
layer
.
msg
(
'请选择商户'
)
}
})
// 查询事件
$
(
'#employeeSearch'
).
on
(
'click'
,
function
()
{
var
formVal
=
form
.
val
(
'employeeForm'
)
var
searchData
=
helper
.
clone
(
false
,
formVal
)
console
.
log
(
formVal
)
if
(
searchData
.
type
==
0
)
{
searchData
.
staffName
=
formVal
.
keywords
searchData
.
staffPhone
=
''
}
else
if
(
searchData
.
type
==
1
)
{
searchData
.
staffName
=
''
searchData
.
staffPhone
=
formVal
.
keywords
}
else
{
searchData
.
staffName
=
''
searchData
.
staffPhone
=
''
}
delete
searchData
.
type
delete
searchData
.
keywords
console
.
log
(
searchData
)
getTabelList
(
employeeTable
,
searchData
)
})
>>>>>>>
4
e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
})
})
// 新增点击事件
// 新增点击事件
$
(
document
).
on
(
'click'
,
'#addEmployee'
,
function
()
{
$
(
document
).
on
(
'click'
,
'#addEmployee'
,
function
()
{
...
...
html/employee/validPeriod.html
View file @
b68230a
...
@@ -26,7 +26,7 @@
...
@@ -26,7 +26,7 @@
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-label required"
style=
"width: 120px;"
>
账户有效期:
</div>
<div
class=
"layui-form-label required"
style=
"width: 120px;"
>
账户有效期:
</div>
<div
class=
"layui-input-inline"
style=
"width: auto;"
>
<div
class=
"layui-input-inline"
style=
"width: auto;"
>
<select
name=
"
validPeriod
"
id=
"periodSelect"
required
lay-verify=
"required"
>
<select
name=
"
effectiveTime
"
id=
"periodSelect"
required
lay-verify=
"required"
>
<option
value=
""
>
请选择
</option>
<option
value=
""
>
请选择
</option>
</select>
</select>
<p>
(注:永久有效不超过所属工厂商户的有效期)
</p>
<p>
(注:永久有效不超过所属工厂商户的有效期)
</p>
...
@@ -40,21 +40,22 @@
...
@@ -40,21 +40,22 @@
</div> -->
</div> -->
</div>
</div>
</form>
</form>
<input
type=
"text"
id=
"isValid"
name=
"isValid"
value=
"no"
style=
"display: none;"
class=
"layui-input"
>
</main>
</main>
</div>
</div>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"/js/load.js"
></script>
<script
src=
"/js/load.js"
></script>
<script>
<script>
layui
.
use
([
'form'
,
'request'
],
function
()
{
layui
.
use
([
'form'
,
'request'
,
'helper'
],
function
()
{
var
form
=
layui
.
form
var
form
=
layui
.
form
var
request
=
layui
.
request
var
request
=
layui
.
request
var
$
=
layui
.
$
var
$
=
layui
.
$
var
helper
=
layui
.
helper
var
currLayerIdx
=
parent
.
layer
.
getFrameIndex
(
window
.
name
)
var
currLayerIdx
=
parent
.
layer
.
getFrameIndex
(
window
.
name
)
var
baseData
=
{}
var
baseData
=
{}
var
vaildData
=
{
var
vaildData
=
{
id
:
getQueryString
(
'id'
)
id
:
getQueryString
(
'id'
),
effectiveTime
:
getQueryString
(
'effectiveTime'
)
}
}
...
@@ -64,28 +65,17 @@
...
@@ -64,28 +65,17 @@
// 调接口
// 调接口
var
params
=
{
var
params
=
{
method
:
'cn.com.glsx.merchants.staff.updateValPerByStaffId'
,
method
:
'cn.com.glsx.merchants.staff.updateValPerByStaffId'
,
effectiveTime
:
data
.
field
.
validPeriod
,
effectiveTime
:
data
.
field
.
effectiveTime
,
id
:
vaildData
.
id
id
:
vaildData
.
id
}
}
updateVal
(
params
,
function
(
e
)
{
console
.
log
(
e
,
'============kkkkk'
)
if
(
e
)
{
$
(
'#isValid'
).
attr
(
'value'
,
'yes'
)
}
})
return
false
})
function
updateVal
(
params
,
callback
)
{
request
(
params
,
function
(
res
)
{
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
if
(
res
.
code
==
'0'
)
{
callback
(
true
)
helper
.
store
.
set
(
'isRefresh'
,
true
)
parent
.
layer
.
close
(
currLayerIdx
)
}
}
})
})
}
return
false
})
// function callbackdata() {
// return vaildData
// }
// 获取参数
// 获取参数
function
getQueryString
(
name
)
{
function
getQueryString
(
name
)
{
...
@@ -104,13 +94,13 @@
...
@@ -104,13 +94,13 @@
dictType
:
'staff_validity_period'
dictType
:
'staff_validity_period'
},
function
(
res
)
{
},
function
(
res
)
{
if
(
res
.
code
===
'0'
)
{
if
(
res
.
code
===
'0'
)
{
baseData
.
validPeriod
List
=
res
.
data
baseData
.
effectiveTime
List
=
res
.
data
var
periodSelect
=
$
(
'#periodSelect'
)
var
periodSelect
=
$
(
'#periodSelect'
)
$
.
each
(
baseData
.
validPeriod
List
,
function
(
index
,
item
)
{
$
.
each
(
baseData
.
effectiveTime
List
,
function
(
index
,
item
)
{
periodSelect
.
append
(
new
Option
(
item
.
dictLabel
,
item
.
dictValue
))
periodSelect
.
append
(
new
Option
(
item
.
dictLabel
,
item
.
dictValue
))
})
})
form
.
val
(
'periodFilter'
,
{
form
.
val
(
'periodFilter'
,
{
validPeriod
:
vaildData
.
validPeriod
effectiveTime
:
vaildData
.
effectiveTime
})
})
form
.
render
(
'select'
)
form
.
render
(
'select'
)
}
}
...
...
html/merchant/edit.html
View file @
b68230a
...
@@ -210,7 +210,7 @@
...
@@ -210,7 +210,7 @@
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
主营品牌:
</label>
<label
class=
"layui-form-label"
>
主营品牌:
</label>
<div
class=
"layui-input-inline"
>
<div
class=
"layui-input-inline"
>
<input
class=
"layui-input"
placeholder=
"车型品牌"
>
<input
class=
"layui-input"
placeholder=
"车型品牌"
id=
"brand"
>
<div
id=
"carBrandTree"
style=
"width: 300px; height: 200px; overflow-y: scroll;"
></div>
<div
id=
"carBrandTree"
style=
"width: 300px; height: 200px; overflow-y: scroll;"
></div>
</div>
</div>
</div>
</div>
...
@@ -300,6 +300,7 @@
...
@@ -300,6 +300,7 @@
var
editData
=
{}
var
editData
=
{}
var
scopeIdx
=
1
var
scopeIdx
=
1
var
treeObj
=
null
var
treeObj
=
null
var
all_nodes
=
[]
// 1-创建新商户;2-创建子商户;3-修改
// 1-创建新商户;2-创建子商户;3-修改
var
editLevel
=
1
var
editLevel
=
1
var
id
=
null
var
id
=
null
...
@@ -370,6 +371,7 @@
...
@@ -370,6 +371,7 @@
helper
.
store
.
set
(
'merchantMapObj'
,
merchantForm
)
helper
.
store
.
set
(
'merchantMapObj'
,
merchantForm
)
form
.
on
(
'submit(handleSubmit)'
,
function
(
data
)
{
form
.
on
(
'submit(handleSubmit)'
,
function
(
data
)
{
console
.
log
(
editLevel
)
// console.log(data.field)
// console.log(data.field)
var
formData
=
data
.
field
var
formData
=
data
.
field
var
params
=
{
var
params
=
{
...
@@ -382,7 +384,7 @@
...
@@ -382,7 +384,7 @@
'merchantAccountLevel'
,
'effectiveTime'
'merchantAccountLevel'
,
'effectiveTime'
]
]
if
(
formData
.
isloginName
==
'on'
)
{
if
(
formData
.
isloginName
==
'on'
)
{
formData
.
isloginName
=
1
params
.
isloginName
=
1
}
}
if
(
formData
.
bussinessBegintime
)
{
if
(
formData
.
bussinessBegintime
)
{
merchantForm
.
bussinessBegintime
=
new
Date
(
formData
.
bussinessBegintime
)
merchantForm
.
bussinessBegintime
=
new
Date
(
formData
.
bussinessBegintime
)
...
@@ -409,8 +411,6 @@
...
@@ -409,8 +411,6 @@
},
{
},
{
attr
:
'accounttypeId'
,
attr
:
'accounttypeId'
,
toString
:
','
toString
:
','
// toString: false,
// toArray: true
}]
}]
$
.
each
(
checkClassNameList
,
function
(
index
,
item
)
{
$
.
each
(
checkClassNameList
,
function
(
index
,
item
)
{
var
checkedArr
=
[]
var
checkedArr
=
[]
...
@@ -422,10 +422,6 @@
...
@@ -422,10 +422,6 @@
merchantForm
[
item
.
attr
]
=
checkedArr
.
join
(
item
.
toString
)
merchantForm
[
item
.
attr
]
=
checkedArr
.
join
(
item
.
toString
)
params
[
item
.
attr
]
=
checkedArr
.
join
(
item
.
toString
)
params
[
item
.
attr
]
=
checkedArr
.
join
(
item
.
toString
)
}
}
// else if (item.toArray) {
// merchantForm[item.attr] = checkedArr
// params[item.attr] = JSON.stringify(checkedArr)
// }
}
}
})
})
var
elList
=
$
(
'.business-scope-cust'
)
var
elList
=
$
(
'.business-scope-cust'
)
...
@@ -436,13 +432,16 @@
...
@@ -436,13 +432,16 @@
merchantForm
.
businessScopeCustomize
=
tempList
.
join
(
','
)
merchantForm
.
businessScopeCustomize
=
tempList
.
join
(
','
)
params
.
businessScopeCustomize
=
tempList
.
join
(
','
)
params
.
businessScopeCustomize
=
tempList
.
join
(
','
)
merchantForm
.
merchantBrand
=
treeObj
.
getCheckedNodes
(
true
)
merchantForm
.
merchantBrand
=
treeObj
.
getCheckedNodes
(
true
)
params
.
merchantBrand
=
findId
(
merchantForm
.
merchantBrand
,
[]).
join
(
','
)
params
.
merchantBrand
=
findId
(
merchantForm
.
merchantBrand
).
join
(
','
)
if
(
merchantForm
.
merchantFiles
.
length
)
{
params
.
merchantFiles
=
JSON
.
stringify
(
merchantForm
.
merchantFiles
)
params
.
merchantFiles
=
JSON
.
stringify
(
merchantForm
.
merchantFiles
)
}
if
(
editLevel
==
1
)
{
if
(
editLevel
==
1
)
{
params
.
method
=
'cn.com.glsx.merchants.merchant.saveMerchant'
params
.
method
=
'cn.com.glsx.merchants.merchant.saveMerchant'
}
else
if
(
editLevel
==
2
)
{
}
else
if
(
editLevel
==
2
)
{
params
.
method
=
'cn.com.glsx.merchants.merchant.saveMerchant'
params
.
method
=
'cn.com.glsx.merchants.merchant.saveMerchant'
}
else
if
(
editLevel
==
3
)
{
}
else
if
(
editLevel
==
3
)
{
params
.
id
=
id
params
.
method
=
'cn.com.glsx.merchants.merchant.updateMerchant'
params
.
method
=
'cn.com.glsx.merchants.merchant.updateMerchant'
}
}
// 保存状态 1.草稿 2.发布 3.注销 4.过期
// 保存状态 1.草稿 2.发布 3.注销 4.过期
...
@@ -455,18 +454,18 @@
...
@@ -455,18 +454,18 @@
console
.
log
(
params
)
console
.
log
(
params
)
request
(
params
,
function
(
res
)
{
request
(
params
,
function
(
res
)
{
console
.
log
(
res
)
console
.
log
(
res
)
layer
.
msg
(
'操作成功'
,
{
icon
:
1
})
// go('merchant', 'index')
})
})
return
false
return
false
})
})
function
findId
(
nodeList
,
idList
)
{
function
findId
(
nodeList
)
{
//
var idList = []
var
idList
=
[]
$
.
each
(
nodeList
,
function
(
index
,
item
)
{
$
.
each
(
nodeList
,
function
(
index
,
item
)
{
if
(
item
.
children
)
{
findId
(
item
.
children
,
idList
)
}
else
{
idList
.
push
(
item
.
id
)
idList
.
push
(
item
.
id
)
}
})
})
return
idList
return
idList
}
}
...
@@ -500,7 +499,7 @@
...
@@ -500,7 +499,7 @@
var
body
=
layer
.
getChildFrame
(
'body'
,
index
)
var
body
=
layer
.
getChildFrame
(
'body'
,
index
)
body
.
find
(
'#mapBtn'
).
click
()
body
.
find
(
'#mapBtn'
).
click
()
var
res
=
helper
.
store
.
get
(
'merchantMapObj'
)
var
res
=
helper
.
store
.
get
(
'merchantMapObj'
)
console
.
log
(
res
)
//
console.log(res)
merchantForm
.
lat
=
res
.
lat
merchantForm
.
lat
=
res
.
lat
merchantForm
.
lng
=
res
.
lng
merchantForm
.
lng
=
res
.
lng
merchantForm
.
merchantAddress
=
res
.
merchantAddress
merchantForm
.
merchantAddress
=
res
.
merchantAddress
...
@@ -604,8 +603,20 @@
...
@@ -604,8 +603,20 @@
getChannel
()
getChannel
()
getAccountLevel
()
getAccountLevel
()
getPeriod
()
getPeriod
()
bindEvent
()
}
function
bindEvent
(){
$
(
'#brand'
).
on
(
'input'
,
helper
.
debounce
(
function
(){
var
txt
=
$
(
this
).
val
()
if
(
!
txt
){
treeObj
.
showNodes
(
all_nodes
)
}
else
{
var
show_nodes
=
treeObj
.
getNodesByParamFuzzy
(
'label'
,
txt
)
treeObj
.
hideNodes
(
all_nodes
)
treeObj
.
showNodes
(
show_nodes
)
}
},
500
))
}
}
function
setCheckbox
(
checkedStr
,
attr
)
{
function
setCheckbox
(
checkedStr
,
attr
)
{
if
(
!
checkedStr
||
!
checkedStr
.
length
)
{
if
(
!
checkedStr
||
!
checkedStr
.
length
)
{
return
false
return
false
...
@@ -616,6 +627,7 @@
...
@@ -616,6 +627,7 @@
}
else
{
}
else
{
list
=
checkedStr
.
split
(
','
)
list
=
checkedStr
.
split
(
','
)
}
}
console
.
log
(
list
)
$
.
each
(
list
,
function
(
index
,
item
)
{
$
.
each
(
list
,
function
(
index
,
item
)
{
$
(
'input[class='
+
attr
+
']'
).
attr
(
"checked"
,
true
)
$
(
'input[class='
+
attr
+
']'
).
attr
(
"checked"
,
true
)
})
})
...
@@ -633,9 +645,6 @@
...
@@ -633,9 +645,6 @@
getBusiScope
()
getBusiScope
()
getCarBrandTree
()
getCarBrandTree
()
getAccountType
()
getAccountType
()
// if (merchantForm.accountTypes.length) {
// setCheckbox(merchantForm.accountTypes, 'accounttypeId')
// }
})
})
}
}
...
@@ -652,11 +661,26 @@
...
@@ -652,11 +661,26 @@
request
({
request
({
method
:
'cn.com.glsx.merchants.merchantCommon.getCarbrandTree'
method
:
'cn.com.glsx.merchants.merchantCommon.getCarbrandTree'
},
function
(
res
)
{
},
function
(
res
)
{
// console.log(res.data)
baseData
.
carBrandTreeList
=
res
.
data
baseData
.
carBrandTreeList
=
res
.
data
treeObj
=
tree
.
create
(
'carBrandTree'
,
res
.
data
)
treeObj
=
tree
.
create
(
'carBrandTree'
,
res
.
data
)
all_nodes
=
treeObj
.
getNodes
()
var
checkedList
=
[]
if
(
editLevel
==
3
)
{
checkedList
=
merchantForm
.
merchantBrand
.
split
(
','
)
}
treeObj
=
tree
.
create
(
'carBrandTree'
,
res
.
data
,
{
checkedList
:
checkedList
})
// 修改-回显
// if (editLevel == 3) {
// checkedList = merchantForm.merchantBrand.split(',')
// for (var i = 0; i <= checkedList.length; i++) {
// treeObj.checkNode(treeObj.getNodeByParam("id", checkedList[i]), true)
// }
// }
})
})
}
}
// 获取字典数据
// 获取字典数据
function
getDictData
(
dictType
,
fn
)
{
function
getDictData
(
dictType
,
fn
)
{
request
({
request
({
...
@@ -701,17 +725,26 @@
...
@@ -701,17 +725,26 @@
function
getBusiScope
()
{
function
getBusiScope
()
{
getDictData
(
'business_scope'
,
function
(
res
)
{
getDictData
(
'business_scope'
,
function
(
res
)
{
baseData
.
busiScopeList
=
res
.
data
baseData
.
busiScopeList
=
res
.
data
var
checkedList
=
[]
if
(
editLevel
==
3
)
{
checkedList
=
merchantForm
.
businessScope
.
split
(
','
)
}
var
el
=
$
(
'#busiScopeEl'
)
var
el
=
$
(
'#busiScopeEl'
)
$
.
each
(
baseData
.
busiScopeList
,
function
(
index
,
item
)
{
$
.
each
(
baseData
.
busiScopeList
,
function
(
index
,
item
)
{
var
optionEl
=
$
(
'<input type="checkbox" class="businessScope" name="businessScope['
+
item
var
optionEl
=
$
(
'<input type="checkbox" class="businessScope" name="businessScope['
+
item
.
dictValue
+
']" title='
+
.
dictValue
+
']" title='
+
item
.
dictLabel
+
' value="'
+
item
.
dictValue
+
'" lay-skin="primary">'
)
item
.
dictLabel
+
' value="'
+
item
.
dictValue
+
'" lay-skin="primary">'
)
el
.
append
(
optionEl
)
form
.
render
(
'checkbox'
)
// 修改-回显
// 修改-回显
if
(
editLevel
==
3
&&
merchantForm
.
businessScopName
)
{
if
(
editLevel
==
3
)
{
setCheckbox
(
merchantForm
.
businessScopName
,
'businessScope'
)
for
(
var
i
=
0
;
i
<=
checkedList
.
length
;
i
++
)
{
if
(
checkedList
[
i
]
==
item
.
dictValue
)
{
optionEl
.
attr
(
"checked"
,
true
)
break
}
}
}
}
el
.
append
(
optionEl
)
form
.
render
(
'checkbox'
)
})
})
})
})
}
}
...
@@ -721,17 +754,26 @@
...
@@ -721,17 +754,26 @@
getDictData
(
'account_type'
,
function
(
res
)
{
getDictData
(
'account_type'
,
function
(
res
)
{
// console.log(res.data)
// console.log(res.data)
baseData
.
accountTypeList
=
res
.
data
baseData
.
accountTypeList
=
res
.
data
var
checkedList
=
[]
if
(
editLevel
==
3
)
{
checkedList
=
merchantForm
.
accountType
.
split
(
','
)
}
var
el
=
$
(
'#accountTypeEl'
)
var
el
=
$
(
'#accountTypeEl'
)
$
.
each
(
baseData
.
accountTypeList
,
function
(
index
,
item
)
{
$
.
each
(
baseData
.
accountTypeList
,
function
(
index
,
item
)
{
var
optionEl
=
$
(
'<input type="checkbox" class="accounttypeId" name="accountType['
+
item
var
optionEl
=
$
(
'<input type="checkbox" class="accounttypeId" name="accountType['
+
item
.
dictValue
+
']" title='
+
.
dictValue
+
']" title='
+
item
.
dictLabel
+
' value="'
+
item
.
dictValue
+
'">'
)
item
.
dictLabel
+
' value="'
+
item
.
dictValue
+
'">'
)
el
.
append
(
optionEl
)
form
.
render
(
'checkbox'
)
// 修改-回显
// 修改-回显
if
(
editLevel
==
3
&&
merchantForm
.
accountTypes
.
length
)
{
if
(
editLevel
==
3
)
{
setCheckbox
(
merchantForm
.
accountTypes
,
'accounttypeId'
)
for
(
var
i
=
0
;
i
<=
checkedList
.
length
;
i
++
)
{
if
(
checkedList
[
i
]
==
item
.
dictValue
)
{
optionEl
.
attr
(
"checked"
,
true
)
break
}
}
}
}
el
.
append
(
optionEl
)
form
.
render
(
'checkbox'
)
})
})
})
})
}
}
...
...
html/merchant/index.html
View file @
b68230a
...
@@ -26,6 +26,10 @@
...
@@ -26,6 +26,10 @@
white-space
:
normal
;
white-space
:
normal
;
}
}
.merchant
#searchForm
.layui-inline
{
margin-bottom
:
5px
;
}
.layui-btn-xs
{
.layui-btn-xs
{
cursor
:
pointer
;
cursor
:
pointer
;
}
}
...
@@ -39,13 +43,40 @@
...
@@ -39,13 +43,40 @@
<!-- <div id="tree"></div> -->
<!-- <div id="tree"></div> -->
<div
class=
"context-block"
>
<div
class=
"context-block"
>
<div
class=
"search-block"
>
<div
class=
"search-block"
>
<<<<<<
< HEAD
<
button
class=
"layui-btn"
id=
"addBtn"
lay-filter=
"handleAdd"
style=
"padding: 0 15px;"
>
<
button
class=
"layui-btn"
id=
"addBtn"
lay-filter=
"handleAdd"
style=
"padding: 0 15px;"
>
<i
class=
"layui-icon layui-icon-add-circle"
></i>
<i
class=
"layui-icon layui-icon-add-circle"
></i>
创建商户
</button>
创建商户
</button>
=======
>>>>>>> 4e4076e9661f54b986fc5b70d941ec0e9eaa1bf3
<form
class=
"layui-form"
lay-filter=
"searchFilter"
id=
"searchForm"
>
<form
class=
"layui-form"
lay-filter=
"searchFilter"
id=
"searchForm"
>
<!-- <div>
<div
class=
"layui-inline"
id=
"operateEl"
>
<button class="layui-btn" lay-filter="handleAdd">创建商户</button>
<button
class=
"layui-btn"
id=
"addBtn"
>
创建商户
</button>
</div> -->
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
渠道:
</label>
<div
class=
"layui-input-inline"
>
<select
name=
"channelId"
id=
"channelIdEl"
>
<option
value=
""
>
请选择渠道
</option>
</select>
</div>
</div>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
账户等级:
</label>
<div
class=
"layui-input-inline"
>
<select
name=
"merchantAccountLevel"
id=
"accountLevelEl"
>
<option
value=
""
>
请选择账户等级
</option>
</select>
</div>
</div>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
账户类型:
</label>
<div
class=
"layui-input-inline"
>
<select
name=
"accounttypeId"
id=
"accountTypeIdEl"
>
<option
value=
""
>
请选择账户类型
</option>
</select>
</div>
</div>
</div>
<div
class=
"layui-inline"
>
<div
class=
"layui-inline"
>
<div
class=
"layui-input-inline"
style=
"width: 120px;"
>
<div
class=
"layui-input-inline"
style=
"width: 120px;"
>
<select
name=
"name"
lay-filter=
"nameFilter"
>
<select
name=
"name"
lay-filter=
"nameFilter"
>
...
@@ -60,14 +91,14 @@
...
@@ -60,14 +91,14 @@
<div
class=
"layui-inline"
>
<div
class=
"layui-inline"
>
<label
class=
"layui-form-label"
>
客户状态:
</label>
<label
class=
"layui-form-label"
>
客户状态:
</label>
<div
class=
"layui-input-inline"
>
<div
class=
"layui-input-inline"
>
<select
name=
"status"
id=
"searchStatus"
>
<select
name=
"status"
id=
"searchStatus
El
"
>
<option
value=
""
>
请选择客户状态
</option>
<option
value=
""
>
请选择客户状态
</option>
</select>
</select>
</div>
</div>
</div>
</div>
<div
style=
"float: right;"
>
<div
style=
"float: right;"
>
<div
class=
"layui-inline"
>
<div
class=
"layui-inline"
>
<input
class=
"layui-input"
placeholder=
"请输入客户名称"
>
<input
class=
"layui-input"
name=
"merchantName"
placeholder=
"请输入客户名称"
>
</div>
</div>
<div
class=
"layui-inline"
>
<div
class=
"layui-inline"
>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"searchSubmit"
>
查询
</button>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"searchSubmit"
>
查询
</button>
...
@@ -84,108 +115,37 @@
...
@@ -84,108 +115,37 @@
<script
src=
"/js/load.js"
></script>
<script
src=
"/js/load.js"
></script>
<script
type=
"text/html"
id=
"merchantBtns"
>
<script
type=
"text/html"
id=
"merchantBtns"
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleDetail"
>
查看
<
/a
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleDetail"
>
查看
<
/a
>
{{
#
if
((
d
.
btn
.
edit
)){
}}
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleEdit"
>
修改
<
/a
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleEdit"
>
修改
<
/a
>
{{
#
if
((
d
.
merchantAccountLevel
!=
4
)
||
(
d
.
status
==
2
&&
d
.
merchantAccountLevel
!=
4
)){
}}
{{
#
}
}}
{{
#
if
((
d
.
btn
.
createSubMerchant
)){
}}
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleAddMerchant"
>
创建子商户
/
门店
<
/a
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleAddMerchant"
>
创建子商户
/
门店
<
/a
>
{{
#
}
}}
{{
#
}
}}
{{
#
if
((
d
.
btn
.
createStaff
)){
}}
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleAddStaff"
>
创建员工
<
/a
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleAddStaff"
>
创建员工
<
/a
>
{{
#
}
}}
{{
#
if
((
d
.
btn
.
editPeriod
)){
}}
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleVaildPeriod"
>
修改账户有效期
<
/a
>
<
a
class
=
"layui-btn-xs"
lay
-
event
=
"handleVaildPeriod"
>
修改账户有效期
<
/a
>
{{
#
}
}}
</script>
</script>
<script>
<script>
layui
.
use
([
'gtree'
,
'request'
,
'
store
'
,
'table'
,
'layer'
],
function
()
{
layui
.
use
([
'gtree'
,
'request'
,
'
helper
'
,
'table'
,
'layer'
],
function
()
{
var
tree
=
layui
.
gtree
var
tree
=
layui
.
gtree
var
request
=
layui
.
request
var
request
=
layui
.
request
var
table
=
layui
.
table
var
table
=
layui
.
table
var
form
=
layui
.
form
var
form
=
layui
.
form
var
$
=
layui
.
$
var
$
=
layui
.
$
var
helper
=
layui
.
helper
var
user
=
helper
.
store
.
get
(
'user'
)
var
isDxternal
=
helper
.
store
.
get
(
'isDxternal'
)
var
baseData
=
{
var
baseData
=
{
statusList
:
[]
statusList
:
[],
}
channelList
:
[],
// var list = [{
accountLevelList
:
[],
// confId: '1',
accountTypeList
:
[]
// confLabel: '账号登陆名'
// }, {
// confId: '2',
// confLabel: '手机号'
// }]
// var select = $("#searchName")
// $.each(list, function (index, item) {
// select.append(new Option(item.confLabel, item.confId))
// })
// form.render('select')
// request({
// a: 1
// })
var
inst
=
tree
.
create
(
'tree'
,
[{
id
:
1
,
label
:
'一级菜单'
,
children
:
[{
id
:
4
,
label
:
'二级菜单'
,
children
:
[{
id
:
9
,
label
:
'三级功能'
,
children
:
[
// value: '1,2,3|人保,平安,寿险'
{
id
:
111
,
label
:
'人保'
,
logo
:
'PR'
},
{
id
:
112
,
label
:
'平安'
,
logo
:
'PR'
},
{
id
:
113
,
label
:
'寿险'
,
logo
:
'PR'
}
}
]
},
{
id
:
10
,
label
:
'三级功能-1'
,
value
:
null
}
]
}]
},
{
id
:
2
,
label
:
'一级菜单2'
,
children
:
[{
id
:
5
,
label
:
'二级菜单2'
,
children
:
[
// value: '1,2,3|人保,平安,寿险'
{
id
:
114
,
label
:
'人保'
,
logo
:
'PR'
},
{
id
:
115
,
label
:
'平安'
,
logo
:
'PR'
},
{
id
:
116
,
label
:
'寿险'
,
logo
:
'PR'
}
]
},
{
id
:
6
,
label
:
'二级菜单2.0'
}
]
}
])
var
merchantTable
=
table
.
render
({
var
merchantTable
=
table
.
render
({
elem
:
'#merchantTable'
,
elem
:
'#merchantTable'
,
page
:
true
,
page
:
true
,
...
@@ -253,7 +213,7 @@
...
@@ -253,7 +213,7 @@
})
})
table
.
on
(
'tool(merchant-table-filter)'
,
function
(
obj
)
{
table
.
on
(
'tool(merchant-table-filter)'
,
function
(
obj
)
{
console
.
log
(
obj
)
//
console.log(obj)
var
eventName
=
obj
.
event
var
eventName
=
obj
.
event
var
row
=
obj
.
data
var
row
=
obj
.
data
console
.
log
(
row
)
console
.
log
(
row
)
...
@@ -286,41 +246,35 @@
...
@@ -286,41 +246,35 @@
// 修改账户有效期
// 修改账户有效期
case
'handleVaildPeriod'
:
case
'handleVaildPeriod'
:
// console.log(row)
// console.log(row)
var
layerIdx
=
layer
.
open
({
layer
.
open
({
type
:
2
,
type
:
2
,
title
:
'修改账户的有效期'
,
title
:
'修改账户的有效期'
,
area
:
[
'700px'
,
'420px'
],
area
:
[
'700px'
,
'420px'
],
fixed
:
false
,
//不固定
fixed
:
false
,
//不固定
// maxmin: true,
// maxmin: true,
btn
:
[
'确定'
,
'取消'
],
btn
:
[
'确定'
,
'取消'
],
content
:
'validPeriodForm.html?id='
+
row
.
id
+
'&
validPeriod='
+
'365'
,
content
:
'validPeriodForm.html?id='
+
row
.
id
+
'&
effectiveTime='
+
row
.
effectiveTime
,
yes
:
function
(
index
,
layero
)
{
yes
:
function
(
index
,
layero
)
{
// console.log(layero)
// var res = window["layui-layer-iframe" + index].callbackdata()
// console.log(res)
// 获取iframe层的body
var
body
=
layer
.
getChildFrame
(
'body'
,
index
)
var
body
=
layer
.
getChildFrame
(
'body'
,
index
)
body
.
contents
().
find
(
'#isValid'
).
attr
(
'value'
,
'no'
)
helper
.
store
.
set
(
'isRefresh'
,
false
)
body
.
find
(
'#periodVerifyBtn'
).
click
()
body
.
find
(
'#periodVerifyBtn'
).
click
()
if
(
body
.
contents
().
find
(
'#isValid'
).
val
()
===
'yes'
)
{
},
// console.log('+++++++++++')
end
:
function
()
{
layer
.
msg
(
'操作成功'
,
{
var
isRefresh
=
helper
.
store
.
get
(
'isRefresh'
)
if
(
isRefresh
)
{
getTabelList
()
layer
.
msg
(
'修改成功'
,
{
icon
:
1
icon
:
1
})
})
layer
.
close
(
index
)
}
}
},
helper
.
store
.
remove
(
'isRefresh'
)
cancel
:
function
(
index
,
layero
)
{
// layer.close(index)
}
}
})
})
console
.
log
(
layerIdx
)
break
break
}
}
})
})
getVaildPeriod
()
init
()
getTabelList
()
// form.on('handleAdd', function () {
// form.on('handleAdd', function () {
// console.log('00000')
// console.log('00000')
...
@@ -331,6 +285,7 @@
...
@@ -331,6 +285,7 @@
go
(
'merchant'
,
'edit'
,
{
go
(
'merchant'
,
'edit'
,
{
editLevel
:
1
editLevel
:
1
})
})
return
false
})
})
// 搜索绑定事件
// 搜索绑定事件
form
.
on
(
'submit(searchSubmit)'
,
function
()
{
form
.
on
(
'submit(searchSubmit)'
,
function
()
{
...
@@ -363,6 +318,62 @@
...
@@ -363,6 +318,62 @@
var
data
=
res
.
data
var
data
=
res
.
data
$
.
each
(
data
.
data
,
function
(
index
,
item
)
{
$
.
each
(
data
.
data
,
function
(
index
,
item
)
{
item
.
index
=
index
+
1
+
pageSize
*
(
pageNum
-
1
)
item
.
index
=
index
+
1
+
pageSize
*
(
pageNum
-
1
)
item
.
btn
=
{
edit
:
false
,
createSubMerchant
:
false
,
createStaff
:
false
,
editPeriod
:
false
}
/** btn
* check - 查看(无需判断,均有)
* edit - 修改
* createSubMerchant - 创建子商户/门店
* createStaff - 创建员工
* editPeriod - 修改账户有效期
* **/
// status(账户状态 - 列表):1-草稿;2-正常;3-注销;4-过期
// merchantAccountLevel(账户等级 - 列表):1-工厂;2-省代;3-市代;4-门店
// 外部系统
if
(
isDxternal
)
{
// 状态 - 正常
if
(
item
.
status
==
2
)
{
// 本身
if
(
item
.
id
==
user
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
if
(
merchantAccountLevel
!=
4
)
{
item
.
btn
.
createSubMerchant
=
true
}
}
else
{
// 下级商户
console
.
log
(
item
)
item
.
btn
.
edit
=
true
item
.
btn
.
editPeriod
=
true
// 直属门店
if
(
item
.
merchantAccountLevel
==
4
)
{
if
(
item
.
parentId
==
user
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
}
}
else
{
item
.
btn
.
createSubMerchant
=
true
}
}
}
else
if
(
item
.
status
!=
3
)
{
item
.
btn
.
edit
=
true
}
}
else
{
// 超管登陆
if
(
item
.
status
!=
3
)
{
item
.
btn
.
edit
=
true
}
if
((
item
.
status
==
2
))
{
item
.
btn
.
createStaff
=
true
if
(
item
.
merchantAccountLevel
!=
4
)
{
item
.
btn
.
createSubMerchant
=
true
}
}
if
(
item
.
status
!=
1
)
{
item
.
btn
.
editPeriod
=
true
}
}
})
})
var
options
=
{
var
options
=
{
data
:
data
.
data
data
:
data
.
data
...
@@ -376,22 +387,75 @@
...
@@ -376,22 +387,75 @@
})
})
}
}
// 获取
有效期
// 获取
字典数据
function
get
VaildPeriod
(
)
{
function
get
DictData
(
dictType
,
fn
)
{
request
({
request
({
method
:
'cn.com.glsx.merchants.menu.findAllDictData'
,
method
:
'cn.com.glsx.merchants.menu.findAllDictData'
,
dictType
:
'merchant_status'
dictType
:
dictType
},
function
(
res
)
{
},
function
(
res
)
{
if
(
res
.
code
===
'0'
)
{
fn
&&
fn
(
res
)
baseData
.
statusList
=
res
.
data
})
var
searchStatus
=
$
(
"#searchStatus"
)
}
$
.
each
(
baseData
.
statusList
,
function
(
index
,
item
)
{
searchStatus
.
append
(
new
Option
(
item
.
dictLabel
,
item
.
dictValue
))
// 设置option
function
setSelectOption
(
elName
,
listName
,
optionId
,
optionLabel
)
{
var
el
=
$
(
elName
)
$
.
each
(
baseData
[
listName
],
function
(
index
,
item
)
{
el
.
append
(
new
Option
(
item
[
optionLabel
],
item
[
optionId
]))
})
})
form
.
render
(
'select'
)
form
.
render
(
'select'
)
}
}
// 获取有效期
function
getVaildPeriod
()
{
getDictData
(
'merchant_status'
,
function
(
res
)
{
baseData
.
statusList
=
res
.
data
setSelectOption
(
'#searchStatusEl'
,
'statusList'
,
'dictValue'
,
'dictLabel'
)
})
}
// 获取渠道
function
getChannel
()
{
getDictData
(
'channel'
,
function
(
res
)
{
baseData
.
channelList
=
res
.
data
setSelectOption
(
'#channelIdEl'
,
'channelList'
,
'dictValue'
,
'dictLabel'
)
})
}
// 获取账户等级
function
getAccountLevel
()
{
getDictData
(
'account_level'
,
function
(
res
)
{
baseData
.
accountLevelList
=
res
.
data
setSelectOption
(
'#accountLevelEl'
,
'accountLevelList'
,
'dictValue'
,
'dictLabel'
)
})
})
}
}
// 获取账户类型
function
getAccountType
()
{
getDictData
(
'account_type'
,
function
(
res
)
{
baseData
.
accountTypeList
=
res
.
data
setSelectOption
(
'#accountTypeIdEl'
,
'accountTypeList'
,
'dictValue'
,
'dictLabel'
)
})
}
// 功能点按需出现
function
elRemove
()
{
$
(
'#operateEl'
).
remove
()
}
function
init
()
{
// 运营系统
// if (!isDxternal) {
if
(
isDxternal
)
{
getChannel
()
getAccountLevel
()
getAccountType
()
}
else
{
elRemove
()
}
getVaildPeriod
()
getTabelList
()
}
})
})
</script>
</script>
</body>
</body>
...
...
html/merchant/validPeriodForm.html
View file @
b68230a
...
@@ -26,63 +26,49 @@
...
@@ -26,63 +26,49 @@
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-label required"
style=
"width: 120px;"
>
账户有效期:
</div>
<div
class=
"layui-form-label required"
style=
"width: 120px;"
>
账户有效期:
</div>
<div
class=
"layui-input-inline"
style=
"width: auto;"
>
<div
class=
"layui-input-inline"
style=
"width: auto;"
>
<select
name=
"
validPeriod
"
id=
"periodSelect"
required
lay-verify=
"required"
>
<select
name=
"
effectiveTime
"
id=
"periodSelect"
required
lay-verify=
"required"
>
<option
value=
""
>
请选择
</option>
<option
value=
""
>
请选择
</option>
</select>
</select>
<p>
(注:永久有效不超过所属工厂商户的有效期)
</p>
<p>
(注:永久有效不超过所属工厂商户的有效期)
</p>
</div>
</div>
<button
id=
"periodVerifyBtn"
lay-submit
lay-filter=
"periodSubmit"
style=
"display: none;"
></button>
<button
id=
"periodVerifyBtn"
lay-submit
lay-filter=
"periodSubmit"
style=
"display: none;"
></button>
<!-- <div class="layui-form-item" style="padding: 40px 20px;">
<div class="layui-input-inline">
<button class="layui-btn layui-btn-sm" lay-submit lay-filter="validSubmit">立即提交</button>
<button type="reset" class="layui-btn layui-btn-sm layui-btn-primary">重置</button>
</div>
</div> -->
</div>
</div>
</form>
</form>
<input
type=
"text"
id=
"isValid"
name=
"isValid"
value=
"no"
style=
"display: none;"
class=
"layui-input"
>
</main>
</main>
</div>
</div>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"/js/load.js"
></script>
<script
src=
"/js/load.js"
></script>
<script>
<script>
layui
.
use
([
'form'
,
'request'
],
function
()
{
layui
.
use
([
'form'
,
'
helper'
,
'
request'
],
function
()
{
var
form
=
layui
.
form
var
form
=
layui
.
form
var
request
=
layui
.
request
var
request
=
layui
.
request
var
$
=
layui
.
$
var
$
=
layui
.
$
var
helper
=
layui
.
helper
var
currLayerIdx
=
parent
.
layer
.
getFrameIndex
(
window
.
name
)
var
currLayerIdx
=
parent
.
layer
.
getFrameIndex
(
window
.
name
)
var
baseData
=
{}
var
baseData
=
{}
var
vaildData
=
{
var
vaildData
=
{
id
:
getQueryString
(
'id'
),
id
:
getQueryString
(
'id'
),
validPeriod
:
getQueryString
(
'validPeriod
'
)
effectiveTime
:
getQueryString
(
'effectiveTime
'
)
}
}
getVaildPeriod
()
getVaildPeriod
()
// form.on('submit(validSubmit)', function (data) {
// var params = {
// id: vaildData.id,
// validPeriod: data.field.validPeriod
// }
// console.log(params)
// // layer.msg('操作成功', { time: 2000 })
// parent.layer.close(currLayerIdx)
// return false
// })
form
.
on
(
'submit(periodSubmit)'
,
function
(
data
)
{
form
.
on
(
'submit(periodSubmit)'
,
function
(
data
)
{
// console.log(data)
var
params
=
{
// console.log('点击啦---')
method
:
'cn.com.glsx.merchants.merchant.updateValPerByMerId'
,
// 调接口
id
:
vaildData
.
id
,
$
(
'#isValid'
).
attr
(
'value'
,
'yes'
)
effectiveTime
:
data
.
field
.
effectiveTime
}
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
helper
.
store
.
set
(
'isRefresh'
,
true
)
parent
.
layer
.
close
(
currLayerIdx
)
}
})
return
false
return
false
})
})
// function callbackdata() {
// return vaildData
// }
// 获取参数
// 获取参数
function
getQueryString
(
name
)
{
function
getQueryString
(
name
)
{
var
reg
=
new
RegExp
(
'(^|&)'
+
name
+
'=([^&]*)(&|$)'
,
'i'
)
var
reg
=
new
RegExp
(
'(^|&)'
+
name
+
'=([^&]*)(&|$)'
,
'i'
)
...
@@ -100,13 +86,13 @@
...
@@ -100,13 +86,13 @@
dictType
:
'account_validity_period'
dictType
:
'account_validity_period'
},
function
(
res
)
{
},
function
(
res
)
{
if
(
res
.
code
===
'0'
)
{
if
(
res
.
code
===
'0'
)
{
baseData
.
validPeriod
List
=
res
.
data
baseData
.
effectiveTime
List
=
res
.
data
var
periodSelect
=
$
(
'#periodSelect'
)
var
periodSelect
=
$
(
'#periodSelect'
)
$
.
each
(
baseData
.
validPeriod
List
,
function
(
index
,
item
)
{
$
.
each
(
baseData
.
effectiveTime
List
,
function
(
index
,
item
)
{
periodSelect
.
append
(
new
Option
(
item
.
dictLabel
,
item
.
dictValue
))
periodSelect
.
append
(
new
Option
(
item
.
dictLabel
,
item
.
dictValue
))
})
})
form
.
val
(
'periodFilter'
,
{
form
.
val
(
'periodFilter'
,
{
validPeriod
:
vaildData
.
validPeriod
effectiveTime
:
vaildData
.
effectiveTime
})
})
form
.
render
(
'select'
)
form
.
render
(
'select'
)
}
}
...
...
html/role/add.html
View file @
b68230a
...
@@ -10,6 +10,7 @@
...
@@ -10,6 +10,7 @@
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<title>
角色管理
</title>
<title>
角色管理
</title>
</head>
</head>
<body>
<body>
<div
id=
"app"
>
<div
id=
"app"
>
<main
class=
"bg-white"
>
<main
class=
"bg-white"
>
...
@@ -17,35 +18,31 @@
...
@@ -17,35 +18,31 @@
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
角色名称:
</label>
<label
class=
"layui-form-label required"
>
角色名称:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"roleName"
required
lay-verify=
"required"
placeholder=
"请输入角色名称"
autocomplete=
"off
"
class=
"layui-input"
/>
<input
type=
"text"
name=
"roleName"
lay-verify=
"required"
placeholder=
"请输入角色名称
"
class=
"layui-input"
/>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label
required
"
>
角色说明:
</label>
<label
class=
"layui-form-label"
>
角色说明:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<input
type=
"text"
name=
"roleDescription"
required
lay-verify=
"required"
placeholder=
"请输入角色说明"
autocomplete=
"off
"
class=
"layui-input"
/>
<input
type=
"text"
name=
"roleDescription"
placeholder=
"请输入角色说明
"
class=
"layui-input"
/>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
角色权限:
</label>
<label
class=
"layui-form-label required"
>
角色权限:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
id=
"accountType"
>
<input
lay-filter=
"switch"
type=
"checkbox"
name=
"merchantId"
value=
"1"
title=
"引流渠道商"
>
<!-- <input lay-filter="switch" type="checkbox" name="merchantId" value="1" title="引流渠道商" />
<input
lay-filter=
"switch"
type=
"checkbox"
name=
"merchantId"
value=
"2"
title=
"服务商/合作商"
>
<input lay-filter="switch" type="checkbox" name="merchantId" value="2" title="服务商/合作商" /> -->
</div>
</div>
</div>
<div
class=
"layui-tab"
lay-filter=
"roleAuth"
lay-allowClose=
"true"
>
<ul
class=
"layui-tab-title"
>
<li
class=
"layui-this"
>
网站设置
</li>
<li>
用户基本管理
</li>
</ul>
<div
class=
"layui-tab-content"
>
<div
class=
"layui-tab-item layui-show"
>
1
</div>
<div
class=
"layui-tab-item"
>
2
</div>
</div>
</div>
<div
class=
"layui-tab"
lay-filter=
"roleAuth"
>
<ul
class=
"layui-tab-title"
></ul>
<div
class=
"layui-tab-content"
></div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"*"
>
确定
</button>
<button
class=
"layui-btn"
id=
"draft"
>
存草稿
</button>
<button
class=
"layui-btn"
lay-submit
lay-filter=
"roleSubmit"
>
确定
</button>
<button
type=
"reset"
class=
"layui-btn layui-btn-primary"
id=
"return"
>
取消
</button>
</div>
</div>
</div>
</div>
</form>
</form>
...
@@ -54,33 +51,375 @@
...
@@ -54,33 +51,375 @@
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"/js/load.js"
></script>
<script
src=
"/js/load.js"
></script>
<script>
<script>
layui
.
use
([
'form'
,
'element'
],
function
(){
layui
.
use
([
'form'
,
'element'
,
'request'
,
'laytpl'
,
'xmSelect'
,
'gtree'
,
'helper'
],
function
()
{
var
element
=
layui
.
element
;
var
merchantId
=
qs
(
'merchantId'
)
var
roleid
=
qs
(
'id'
)
var
element
=
layui
.
element
var
form
=
layui
.
form
var
form
=
layui
.
form
var
arr_box
=
[];
var
arr_box
=
[]
var
$
=
layui
.
$
;
var
$
=
layui
.
$
var
request
=
layui
.
request
if
(
roleid
)
{
getById
(
roleid
)
}
else
{
findMenuFunTreeByMerId
()
}
// start
var
laytpl
=
layui
.
laytpl
var
xmSelect
=
layui
.
xmSelect
var
tree
=
layui
.
gtree
var
helper
=
layui
.
helper
var
check_arr
=
[]
var
check_arr
=
[]
form
.
on
(
'checkbox(switch)'
,
function
(
data
)
{
var
requestList
=
[]
console
.
log
(
data
)
var
templateData
=
{}
var
selectEl
=
{}
var
treeData
=
{}
var
menuFunTreeData
=
[]
// 商户的菜单权限树数据
var
active
=
{
/**
* 第一级tab添加
* item: {name: 选项卡名称, value: 选项卡值}
* roleAuth: 选项卡过滤器的名称 lay-filter绑定的名字
* content: 一个放置模板的视图容器,用于呈现渲染结果 带有id的div
* id:选项卡标题的lay-id属性值
* 需要引入laytpl 模块
* rolesAuth:模板的id
* view 放置模板的视图容器的dom
* templateData:用于渲染模板的数据
* productList:复选下拉框的list,修改过的数据{name: '', value: ''}
* products:对应的菜单下的产品list,包含了对应的权限树,原始数据,需作为参数传入treeTabAdd中,在实例化tree时传入的数据使用
*/
tabAdd
:
function
(
item
)
{
// 渠道的id,一层选项卡的id
var
id
=
item
.
value
// roleAuth 一层选项卡过滤器的名称
element
.
tabAdd
(
'roleAuth'
,
{
title
:
item
.
title
,
// 放置模板视图的上一级div
content
:
'<div id="role'
+
id
+
'"></div>'
,
// 选项卡标题的lay-id属性值
id
:
id
})
var
getTpl
=
rolesAuth
.
innerHTML
,
// 模板内容
view
=
document
.
getElementById
(
'role'
+
id
)
templateData
.
id
=
id
// 渲染模版的数据
laytpl
(
getTpl
).
render
(
templateData
,
function
(
html
)
{
view
.
innerHTML
=
html
})
var
productList
=
[]
var
products
=
[]
$
.
each
(
menuFunTreeData
,
function
(
index
,
item
)
{
if
(
item
.
accounttypeId
==
id
)
{
products
=
item
.
products
$
.
each
(
item
.
products
,
function
(
idx
,
i
)
{
productList
.
push
({
name
:
i
.
productName
,
value
:
i
.
productId
})
})
}
})
selectEl
[
id
]
=
xmSelect
.
render
({
el
:
'#select'
+
id
,
data
:
productList
,
on
:
function
(
data
)
{
//arr: 当前多选已选中的数据
var
arr
=
data
.
arr
//change, 此次选择变化的数据,数组
var
change
=
data
.
change
//isAdd, 此次操作是新增还是删除
var
isAdd
=
data
.
isAdd
var
filterName
=
'treeTab'
+
id
if
(
isAdd
)
{
active
.
treeTabAdd
(
change
[
0
],
id
,
products
)
}
else
{
var
productId
=
'tab_'
+
id
+
'_'
+
change
[
0
].
value
active
.
tabDelete
(
filterName
,
productId
)
}
if
(
arr
.
length
!=
0
)
{
var
productId
=
'tab_'
+
id
+
'_'
+
arr
[
0
].
value
active
.
tabChange
(
filterName
,
productId
)
}
}
})
console
.
log
(
selectEl
[
id
])
},
// tab删除
tabDelete
:
function
(
name
,
id
)
{
element
.
tabDelete
(
name
,
id
)
},
// tab Change
tabChange
:
function
(
name
,
id
)
{
element
.
tabChange
(
name
,
id
)
},
/**
* 第二级选项卡
* treeTabAdd 产品的权限添加
* item: {name: 选项卡名称, value: 选项卡值}
* id 第一级选项卡的item.value
* filterName: 过滤器的名称 lay-filter绑定的值
* treeData:渲染模板的数据,和用来存放对应树实例的对象,
* products:产品list数组
* defaultList:编辑时传入,默认勾选中的数组。(举例:[1,2,3])
*/
treeTabAdd
:
function
(
item
,
id
,
products
,
defaultList
)
{
console
.
log
(
defaultList
)
var
productId
=
'tab_'
+
id
+
'_'
+
item
.
value
var
filterName
=
'treeTab'
+
id
// 过滤器的名称 lay-filter
element
.
tabAdd
(
filterName
,
{
title
:
item
.
name
,
content
:
'<div id="treeTab'
+
productId
+
'"></div>'
,
// 放置模板视图的div
id
:
productId
})
var
getTreeTpl
=
treeAuth
.
innerHTML
,
// 获取的模板的id的内容
treeView
=
document
.
getElementById
(
'treeTab'
+
productId
)
// 放置模板视图的div
treeData
[
id
]
=
treeData
[
id
]
||
{}
treeData
[
id
][
item
.
value
]
=
treeData
[
id
][
item
.
value
]
||
{}
treeData
[
id
][
item
.
value
].
id
=
productId
// 渲染模版的数据
treeData
[
id
][
item
.
value
].
productId
=
item
.
value
laytpl
(
getTreeTpl
).
render
(
treeData
[
id
][
item
.
value
],
function
(
html
)
{
treeView
.
innerHTML
=
html
})
var
treeListData
=
[]
$
.
each
(
products
,
function
(
index
,
i
)
{
if
(
item
.
value
==
i
.
productId
)
{
treeListData
=
i
.
merchantProTreeResponses
}
})
var
treedom
=
'tree_'
+
productId
if
(
!
roleid
)
{
treeData
[
id
][
item
.
value
].
treeObj
=
tree
.
create
(
treedom
,
treeListData
)
treeData
[
id
][
item
.
value
].
treeObj
.
checkAllNodes
(
true
)
}
else
{
treeData
[
id
][
item
.
value
].
treeObj
=
tree
.
create
(
treedom
,
treeListData
,
{
checkedList
:
defaultList
})
}
}
}
// 复选框的change事件
form
.
on
(
'checkbox(switch)'
,
function
(
data
)
{
if
(
data
.
elem
.
checked
)
{
if
(
data
.
elem
.
checked
)
{
console
.
log
(
'当前选中的'
,
data
.
elem
.
title
,
data
.
elem
.
value
)
var
obj
=
{
title
:
data
.
elem
.
title
,
value
:
data
.
elem
.
value
}
check_arr
.
push
({
title
:
data
.
elem
.
title
,
value
:
data
.
elem
.
value
})
check_arr
.
push
({
accounttypeId
:
data
.
elem
.
value
})
active
.
tabAdd
(
obj
)
}
else
{
}
else
{
// check_arr.
for
(
var
i
in
check_arr
)
{
for
(
var
i
in
check_arr
)
{
if
(
check_arr
[
i
].
value
==
data
.
elem
.
value
)
{
var
id
=
check_arr
[
i
].
accounttypeId
if
(
check_arr
[
i
].
accounttypeId
==
data
.
elem
.
value
)
{
active
.
tabDelete
(
'roleAuth'
,
id
)
check_arr
.
splice
(
i
,
1
)
check_arr
.
splice
(
i
,
1
)
}
}
}
}
}
}
console
.
log
(
check_arr
)
if
(
check_arr
.
length
!=
0
)
{
active
.
tabChange
(
'roleAuth'
,
check_arr
[
0
].
accounttypeId
)
}
})
// end
// 表单提交
form
.
on
(
'submit(roleSubmit)'
,
function
(
data
)
{
if
(
Object
.
keys
(
treeData
).
length
==
0
)
{
layer
.
msg
(
'请选择角色权限'
)
return
false
}
getAuthList
()
insert
(
0
,
data
.
field
)
return
false
})
// 存草稿
$
(
'#draft'
).
on
(
'click'
,
function
()
{
var
formVal
=
form
.
val
(
'roleForm'
)
if
(
formVal
.
roleName
||
formVal
.
roleDescription
||
Object
.
keys
(
treeData
).
length
!=
0
)
{
console
.
log
(
'baocun'
)
insert
(
1
,
formVal
)
}
else
{
layer
.
msg
(
'至少填一项'
)
}
return
false
})
// 返回上个页面
$
(
'#return'
).
on
(
'click'
,
function
()
{
window
.
history
.
back
()
})
// 调用新增接口
function
insert
(
delFlag
,
formVal
)
{
var
otherParams
=
{
merchantId
:
merchantId
,
delFlag
:
delFlag
// requestList: JSON.stringify(requestList)
}
console
.
log
(
requestList
.
length
)
if
(
requestList
.
length
!=
0
)
{
otherParams
.
requestList
=
JSON
.
stringify
(
requestList
)
}
else
{
otherParams
.
requestList
=
JSON
.
stringify
(
''
)
}
if
(
roleid
)
{
otherParams
.
id
=
roleid
otherParams
.
method
=
'org.ore.api.role.update'
}
else
{
otherParams
.
method
=
'org.ore.api.role.insert'
}
var
params
=
helper
.
clone
(
true
,
otherParams
,
formVal
)
delete
params
.
select
console
.
log
(
params
)
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
layer
.
msg
(
'操作成功'
,
{
icon
:
1
})
})
function
tabAdd
()
window
.
history
.
back
()
//一些事件触发
}
element
.
on
(
'tab(roleAuth)'
,
function
(
data
){
})
console
.
log
(
data
);
}
});
});
// 查询商户的菜单权限树
function
findMenuFunTreeByMerId
()
{
var
params
=
{
method
:
'cn.com.glsx.merchants.merchant.findMenuFunTreeByMerId'
,
id
:
merchantId
}
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
// callback(res.data)
menuFunTreeData
=
res
.
data
var
accountType
=
$
(
'#accountType'
)
$
.
each
(
menuFunTreeData
,
function
(
index
,
item
)
{
console
.
log
(
item
)
var
str
=
$
(
'<input lay-filter="switch" type="checkbox" name="accounttypeId" value="'
+
item
.
accounttypeId
+
'" title="'
+
item
.
accounttypeName
+
'" />'
)
accountType
.
append
(
str
)
if
(
roleid
)
{
// 角色权限的check
for
(
var
i
=
0
;
i
<
check_arr
.
length
;
i
++
)
{
if
(
check_arr
[
i
].
accounttypeId
==
item
.
accounttypeId
)
{
var
productData
=
check_arr
[
i
]
str
.
attr
(
"checked"
,
true
)
var
obj
=
{
title
:
item
.
accounttypeName
,
value
:
item
.
accounttypeId
}
active
.
tabAdd
(
obj
)
var
selectArr
=
[]
var
menuData
=
[]
for
(
var
j
=
0
;
j
<
productData
.
productList
.
length
;
j
++
)
{
menuData
=
productData
.
productList
[
j
]
selectArr
.
push
(
menuData
.
productId
)
active
.
treeTabAdd
({
name
:
menuData
.
productId
,
value
:
menuData
.
productId
},
item
.
accounttypeId
,
item
.
products
,
menuData
.
idList
)
}
// // 产品的回显
selectEl
[
item
.
accounttypeId
].
setValue
(
selectArr
)
var
filterName
=
'treeTab'
+
item
.
accounttypeId
var
productId
=
'tab_'
+
item
.
accounttypeId
+
'_'
+
item
.
products
[
0
].
productId
active
.
tabChange
(
filterName
,
productId
)
// 树的回显
}
break
}
if
(
check_arr
.
length
!=
0
)
{
active
.
tabChange
(
'roleAuth'
,
check_arr
[
0
].
accounttypeId
)
}
}
})
form
.
render
(
'checkbox'
)
}
})
}
// 根据id获取角色详情
function
getById
(
id
)
{
var
params
=
{
method
:
'org.ore.api.role.getById'
,
id
:
id
}
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
console
.
log
(
res
.
data
,
'详情'
)
var
accounttypeId
=
''
if
(
res
.
data
.
responseList
.
length
!=
0
)
{
check_arr
=
res
.
data
.
responseList
}
console
.
log
(
check_arr
,
'jklj'
)
findMenuFunTreeByMerId
()
form
.
val
(
'roleForm'
,
{
roleName
:
res
.
data
.
roleName
,
roleDescription
:
res
.
data
.
roleDescription
})
}
})
}
// 获取角色权限数据requestList
function
getAuthList
()
{
for
(
var
key
in
treeData
)
{
var
accountObj
=
treeData
[
key
]
var
productList
=
[]
for
(
var
i
in
accountObj
)
{
var
productObj
=
accountObj
[
i
]
var
menuIdList
=
[]
var
functionIdList
=
[]
var
functionIdLists
=
[]
var
nodes
=
productObj
.
treeObj
.
getCheckedNodes
(
true
)
$
.
each
(
nodes
,
function
(
index
,
item
)
{
if
(
item
.
logo
==
'function'
)
{
functionIdLists
.
push
(
item
)
}
else
{
menuIdList
.
push
(
item
.
id
)
}
})
$
.
each
(
functionIdLists
,
function
(
idx
,
m
)
{
// m.parentId
var
findIdx
=
-
1
$
.
each
(
functionIdList
,
function
(
idn
,
n
)
{
if
(
n
.
id
==
m
.
parentId
)
{
findIdx
=
idn
}
})
if
(
findIdx
!=
-
1
)
{
functionIdList
[
findIdx
].
functionValue
+=
';'
+
m
.
id
+
':'
+
m
.
label
}
else
{
functionIdList
.
push
({
id
:
m
.
parentId
,
menuId
:
m
.
superParentId
,
functionValue
:
m
.
id
+
':'
+
m
.
label
})
}
})
productList
.
push
({
productId
:
productObj
.
productId
,
functionIdList
:
functionIdList
,
menuIdList
:
menuIdList
})
}
requestList
.
push
({
accountTypeId
:
key
,
productList
:
productList
})
}
console
.
log
(
requestList
)
}
})
</script>
<script
type=
"text/html"
id=
"rolesAuth"
>
<
div
id
=
"select{{d.id}}"
><
/div
>
<
div
class
=
"layui-tab"
lay
-
filter
=
"treeTab{{d.id}}"
>
<
ul
class
=
"layui-tab-title"
>
<
/ul
>
<
div
class
=
"layui-tab-content"
>
<
/div
>
<
/div
>
</script>
<script
type=
"text/html"
id=
"treeAuth"
>
<!--
<
button
class
=
"layui-btn"
data
-
type
=
"d.id"
id
=
"checkedAll"
>
全选
<
/button
>
<
button
class
=
"layui-btn"
id
=
"cancelCheckedAll"
>
取消全选
<
/button> --
>
<
ul
id
=
"tree_{{d.id}}"
class
=
"ztree wrapper-tree"
><
/ul
>
</script>
</script>
</body>
</body>
</html>
</html>
html/role/detail.html
View file @
b68230a
...
@@ -16,23 +16,28 @@
...
@@ -16,23 +16,28 @@
<div>
<div>
<h3
class=
"content-title"
>
员工基本信息
</h3>
<h3
class=
"content-title"
>
员工基本信息
</h3>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label
required
"
>
角色名称:
</label>
<label
class=
"layui-form-label"
>
角色名称:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"roleName"
></div>
<div
class=
"layui-form-mid layui-word-aux"
id=
"roleName"
></div>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label
required
"
>
角色号:
</label>
<label
class=
"layui-form-label"
>
角色号:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"id"
></div>
<div
class=
"layui-form-mid layui-word-aux"
id=
"id"
></div>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label
required
"
>
角色说明:
</label>
<label
class=
"layui-form-label"
>
角色说明:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"roleDescription "
></div>
<div
class=
"layui-form-mid layui-word-aux"
id=
"roleDescription "
></div>
</div>
</div>
</div>
</div>
<h3
class=
"content-title"
>
角色权限
</h3>
<div
class=
"layui-tab"
lay-filter=
"roleAuth"
>
<ul
class=
"layui-tab-title"
></ul>
<div
class=
"layui-tab-content"
></div>
</div>
</div>
</div>
</main>
</main>
</div>
</div>
...
...
html/role/index.html
View file @
b68230a
...
@@ -65,9 +65,9 @@
...
@@ -65,9 +65,9 @@
{
field
:
'roleName'
,
title
:
'角色名称'
},
{
field
:
'roleName'
,
title
:
'角色名称'
},
{
field
:
'id'
,
title
:
'角色号'
},
{
field
:
'id'
,
title
:
'角色号'
},
{
field
:
'merchantName'
,
title
:
'所属商户名'
},
{
field
:
'merchantName'
,
title
:
'所属商户名'
},
{
field
:
'
delFlag
'
,
title
:
'状态'
},
{
field
:
'
statusName
'
,
title
:
'状态'
},
{
field
:
'createdTime'
,
title
:
'更新时间'
},
{
field
:
'createdTime'
,
title
:
'更新时间'
},
{
fixed
:
'right'
,
title
:
'操作'
,
width
:
28
0
,
align
:
'center'
,
toolbar
:
'#roleBar'
}
{
fixed
:
'right'
,
title
:
'操作'
,
width
:
16
0
,
align
:
'center'
,
toolbar
:
'#roleBar'
}
]
]
]
]
})
})
...
@@ -77,8 +77,7 @@
...
@@ -77,8 +77,7 @@
var
params
=
helper
.
clone
(
false
,
{
var
params
=
helper
.
clone
(
false
,
{
pageNum
:
table
.
config
.
index
,
pageNum
:
table
.
config
.
index
,
pageSize
:
table
.
config
.
limit
,
pageSize
:
table
.
config
.
limit
,
method
:
'org.ore.api.role.page'
,
method
:
'org.ore.api.role.page'
merchantId
:
31
},
search
)
},
search
)
request
(
params
,
request
(
params
,
function
(
res
)
{
function
(
res
)
{
...
@@ -117,23 +116,36 @@
...
@@ -117,23 +116,36 @@
var
layEvent
=
obj
.
event
var
layEvent
=
obj
.
event
var
tr
=
obj
.
tr
var
tr
=
obj
.
tr
if
(
layEvent
===
'detail'
)
{
if
(
layEvent
===
'detail'
)
{
go
(
'
merchant
'
,
'detail'
,
{
id
:
data
.
id
})
go
(
'
role
'
,
'detail'
,
{
id
:
data
.
id
})
}
else
if
(
layEvent
===
'edit'
)
{
}
else
if
(
layEvent
===
'edit'
)
{
go
(
'role'
,
'add'
,
{
id
:
1
})
var
params
=
{
id
:
data
.
id
,
merchantId
:
data
.
merchantId
}
go
(
'role'
,
'add'
,
params
)
}
else
if
(
layEvent
===
'del'
)
{
}
else
if
(
layEvent
===
'del'
)
{
layer
.
confirm
(
'真的删除行么'
,
function
(
index
)
{
layer
.
confirm
(
'真的删除行么'
,
function
(
index
)
{
// obj.del() //删除对应行(tr)的DOM结构,并更新缓存
// obj.del() //删除对应行(tr)的DOM结构,并更新缓存
var
params
=
{
method
:
'org.ore.api.role.deleteById'
,
id
:
data
.
id
}
request
(
params
,
function
(
res
)
{
if
(
res
.
code
==
'0'
)
{
layer
.
close
(
index
)
layer
.
close
(
index
)
console
.
log
(
'shanchu'
)
console
.
log
(
'shanchu'
)
getTabelList
(
employeeTable
)
getTabelList
(
roleTable
)
//向服务端发送删除指令
}
})
})
})
}
}
})
})
// 新增点击事件
// 新增点击事件
$
(
document
).
on
(
'click'
,
'#addRole'
,
function
()
{
$
(
'#addRole'
).
on
(
'click'
,
function
()
{
console
.
log
(
'创建'
)
var
value
=
merchantName
.
val
()
go
(
'role'
,
'add'
)
var
params
=
{
merchantId
:
value
}
if
(
value
)
{
go
(
'role'
,
'add'
,
params
)
}
else
{
layer
.
msg
(
'请选择商户'
)
}
})
})
// 查询事件
// 查询事件
$
(
document
).
on
(
'click'
,
'#roleSearch'
,
function
()
{
$
(
document
).
on
(
'click'
,
'#roleSearch'
,
function
()
{
...
...
html/role/tree.html
0 → 100644
View file @
b68230a
<!DOCTYPE html>
<html
lang=
"zh"
>
<head>
<meta
charset=
"utf-8"
/>
<meta
content=
"IE=edge"
/>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1.0"
/>
<meta
name=
"description"
content=
"修改有效期"
/>
<meta
name=
"author"
content=
"GLSX Web Team"
/>
<meta
name=
"keywords"
itemprop=
"keywords"
content=
"广联,商户管理"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<style>
.valid-period
{
text-align
:
center
;
padding
:
20px
20px
;
background-color
:
#ffffff
;
}
</style>
<title>
tree
</title>
</head>
<body>
<div
id=
"app"
>
<main>
fdasfda
</main>
</div>
<script
src=
"https://www.layuicdn.com/layui/layui.js"
></script>
<script
src=
"/js/load.js"
></script>
<script>
console
.
log
(
qs
(
'id'
))
</script>
</body>
</html>
js/gtree.js
View file @
b68230a
...
@@ -11,7 +11,7 @@ layui.define(['ztree'], function (exports) {
...
@@ -11,7 +11,7 @@ layui.define(['ztree'], function (exports) {
var
$
=
layui
.
$
var
$
=
layui
.
$
var
tree
=
layui
.
ztree
var
tree
=
layui
.
ztree
function
onNodeCreated
(
event
,
treeId
,
treeNode
)
{
function
onNodeCreated
(
event
,
treeId
,
treeNode
)
{
if
(
treeNode
.
logo
==
'
PR
'
)
{
if
(
treeNode
.
logo
==
'
function
'
)
{
var
tId
=
treeNode
.
getParentNode
().
tId
var
tId
=
treeNode
.
getParentNode
().
tId
var
$parentUl
=
$
(
'#'
+
tId
+
'_ul'
)
var
$parentUl
=
$
(
'#'
+
tId
+
'_ul'
)
if
(
!
$parentUl
.
hasClass
(
'pr-parent-ul'
))
{
if
(
!
$parentUl
.
hasClass
(
'pr-parent-ul'
))
{
...
@@ -21,8 +21,14 @@ layui.define(['ztree'], function (exports) {
...
@@ -21,8 +21,14 @@ layui.define(['ztree'], function (exports) {
$switchs
.
not
(
':eq(0)'
).
addClass
(
'op0'
)
$switchs
.
not
(
':eq(0)'
).
addClass
(
'op0'
)
}
}
}
}
if
(
gtree
.
opt
&&
gtree
.
opt
.
onNodeCreated
)
{
if
(
gtree
.
opt
&&
gtree
.
opt
.
checkedList
)
{
gtree
.
opt
.
onNodeCreated
(
event
,
treeId
,
treeNode
)
var
p
=
gtree
.
opt
.
checkedList
if
(
p
.
indexOf
(
treeNode
.
id
)
!=
-
1
)
{
treeNode
.
checked
=
true
if
(
inst
)
{
inst
.
updateNode
(
treeNode
)
}
}
}
}
}
}
var
setting
=
{
var
setting
=
{
...
@@ -53,6 +59,7 @@ layui.define(['ztree'], function (exports) {
...
@@ -53,6 +59,7 @@ layui.define(['ztree'], function (exports) {
$treeDom
.
addClass
(
'ztree'
)
$treeDom
.
addClass
(
'ztree'
)
if
(
check
==
0
)
setting
.
check
.
enable
=
false
if
(
check
==
0
)
setting
.
check
.
enable
=
false
inst
=
tree
.
init
(
$treeDom
,
setting
,
nodes
)
inst
=
tree
.
init
(
$treeDom
,
setting
,
nodes
)
inst
.
expandAll
(
true
)
return
inst
return
inst
}
}
}
}
...
...
js/helper.js
View file @
b68230a
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
* @Author: limin
* @Author: limin
* @Date: 2021-07-21 17:20:56
* @Date: 2021-07-21 17:20:56
* @LastEditors: limin
* @LastEditors: limin
* @LastEditTime: 2021-0
7-22 16:52:46
* @LastEditTime: 2021-0
8-06 16:47:13
* @FilePath: \account\js\helper.js
* @FilePath: \account\js\helper.js
*/
*/
layui
.
define
([
'store'
],
function
(
exports
)
{
layui
.
define
([
'store'
],
function
(
exports
)
{
...
@@ -39,8 +39,22 @@ layui.define(['store'], function (exports) {
...
@@ -39,8 +39,22 @@ layui.define(['store'], function (exports) {
}
}
return
extended
return
extended
}
}
function
debounce
(
fun
,
delay
)
{
return
function
(
args
)
{
//获取函数的作用域和变量
let
that
=
this
let
_args
=
args
//每次事件被触发,都会清除当前的timeer,然后重写设置超时调用
clearTimeout
(
fun
.
id
)
fun
.
id
=
setTimeout
(
function
()
{
fun
.
call
(
that
,
_args
)
},
delay
)
}
}
exports
(
'helper'
,
{
exports
(
'helper'
,
{
clone
:
clone
,
clone
:
clone
,
store
:
layui
.
store
store
:
layui
.
store
,
debounce
:
debounce
})
})
})
})
js/load.js
View file @
b68230a
...
@@ -27,6 +27,8 @@ function goLogin() {
...
@@ -27,6 +27,8 @@ function goLogin() {
function
loadLayConfig
()
{
function
loadLayConfig
()
{
layui
.
config
({
layui
.
config
({
base
:
'/js/'
base
:
'/js/'
}).
extend
({
xmSelect
:
'xm-select'
})
})
}
}
function
loadHeaderFooter
()
{
function
loadHeaderFooter
()
{
...
@@ -44,6 +46,11 @@ function append() {
...
@@ -44,6 +46,11 @@ function append() {
function
isAppend
()
{
function
isAppend
()
{
var
_href
=
location
.
href
.
split
(
'/'
)
var
_href
=
location
.
href
.
split
(
'/'
)
var
_path
=
_href
.
slice
(
_href
.
length
-
1
,
_href
.
length
).
toString
()
var
_path
=
_href
.
slice
(
_href
.
length
-
1
,
_href
.
length
).
toString
()
layui
.
use
([
'store'
],
function
()
{
var
store
=
layui
.
store
// isDxternal: true - 外部独立系统;false - 运营平台
store
.
set
(
'isDxternal'
,
_path
.
split
(
'?'
)[
0
]
!==
'login.html'
&&
self
==
top
)
})
return
_path
.
split
(
'?'
)[
0
]
!==
'login.html'
&&
self
==
top
return
_path
.
split
(
'?'
)[
0
]
!==
'login.html'
&&
self
==
top
}
}
...
...
js/request.js
View file @
b68230a
...
@@ -52,11 +52,15 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
...
@@ -52,11 +52,15 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
}
}
}
}
function
request
(
params
,
success
,
config
,
noSignAttr
=
[],
isOtherUrl
=
false
)
{
function
request
(
params
,
success
,
config
,
noSignAttr
,
isOtherUrl
)
{
noSignAttr
=
noSignAttr
||
[]
params
=
params
||
{}
params
=
params
||
{}
config
=
config
||
{}
config
=
config
||
{}
var
common
=
store
.
getEx
(
'external'
)
var
common
=
store
.
getEx
(
'external'
)
var
settings
=
helper
.
clone
(
true
,
defaultSettings
)
var
settings
=
helper
.
clone
(
true
,
defaultSettings
)
if
(
isOtherUrl
)
{
delete
settings
.
beforeSend
}
var
data
=
helper
.
clone
(
true
,
{
var
data
=
helper
.
clone
(
true
,
{
timestamp
:
new
Date
().
getTime
()
timestamp
:
new
Date
().
getTime
()
},
common
.
params
,
params
)
},
common
.
params
,
params
)
...
@@ -86,12 +90,15 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
...
@@ -86,12 +90,15 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
return
$
.
ajax
(
settings
)
return
$
.
ajax
(
settings
)
}
}
function
sign
(
params
,
secret
,
noSignAttr
=
[],
isMd5
=
false
)
{
function
sign
(
params
,
secret
,
noSignAttr
,
isMd5
)
{
noSignAttr
=
noSignAttr
||
[]
if
(
!
params
||
$
.
isEmptyObject
(
params
))
{
if
(
!
params
||
$
.
isEmptyObject
(
params
))
{
return
''
return
''
}
}
delete
params
.
sign
delete
params
.
sign
var
arr
=
[]
var
arr
=
[]
var
secretArr
=
[]
for
(
var
key
in
params
)
{
for
(
var
key
in
params
)
{
var
isPush
=
false
var
isPush
=
false
$
.
each
(
noSignAttr
,
function
(
index
,
item
)
{
$
.
each
(
noSignAttr
,
function
(
index
,
item
)
{
...
@@ -100,12 +107,17 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
...
@@ -100,12 +107,17 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
}
}
})
})
if
(
!
isPush
)
{
if
(
!
isPush
)
{
arr
.
push
(
key
+
params
[
key
])
arr
.
push
(
key
)
}
}
}
arr
.
sort
()
for
(
var
key
in
arr
)
{
var
val
=
arr
[
key
]
secretArr
.
push
(
val
+
params
[
val
])
}
}
var
str
=
arr
.
sort
()
.
join
(
''
)
var
str
=
secretArr
.
join
(
''
)
return
isMd5
?
md5
(
secret
+
str
+
secret
).
toUpperCase
()
:
SHA1
(
secret
+
str
+
secret
).
toUpperCase
()
return
isMd5
?
md5
(
secret
+
str
+
secret
).
toUpperCase
()
:
SHA1
(
secret
+
str
+
secret
).
toUpperCase
()
return
SHA1
(
secret
+
str
+
secret
).
toUpperCase
()
//
return SHA1(secret + str + secret).toUpperCase()
}
}
function
msg
(
msg
)
{
function
msg
(
msg
)
{
...
...
js/xm-select.js
0 → 100644
View file @
b68230a
/*!
* @Title: xm-select
* @Version: 1.1.9
* @Description:基于layui的多选解决方案
* @Site: https://gitee.com/maplemei/xm-select
* @Author: maplemei
* @License:Apache License 2.0
*/
!
function
(
e
){
var
t
=
{};
function
n
(
o
){
if
(
t
[
o
])
return
t
[
o
].
exports
;
var
r
=
t
[
o
]
=
{
i
:
o
,
l
:
!
1
,
exports
:{}};
return
e
[
o
].
call
(
r
.
exports
,
r
,
r
.
exports
,
n
),
r
.
l
=!
0
,
r
.
exports
}
n
.
m
=
e
,
n
.
c
=
t
,
n
.
d
=
function
(
e
,
t
,
o
){
n
.
o
(
e
,
t
)
||
Object
.
defineProperty
(
e
,
t
,{
enumerable
:
!
0
,
get
:
o
})},
n
.
r
=
function
(
e
){
"undefined"
!=
typeof
Symbol
&&
Symbol
.
toStringTag
&&
Object
.
defineProperty
(
e
,
Symbol
.
toStringTag
,{
value
:
"Module"
}),
Object
.
defineProperty
(
e
,
"__esModule"
,{
value
:
!
0
})},
n
.
t
=
function
(
e
,
t
){
if
(
1
&
t
&&
(
e
=
n
(
e
)),
8
&
t
)
return
e
;
if
(
4
&
t
&&
"object"
==
typeof
e
&&
e
&&
e
.
__esModule
)
return
e
;
var
o
=
Object
.
create
(
null
);
if
(
n
.
r
(
o
),
Object
.
defineProperty
(
o
,
"default"
,{
enumerable
:
!
0
,
value
:
e
}),
2
&
t
&&
"string"
!=
typeof
e
)
for
(
var
r
in
e
)
n
.
d
(
o
,
r
,
function
(
t
){
return
e
[
t
]}.
bind
(
null
,
r
));
return
o
},
n
.
n
=
function
(
e
){
var
t
=
e
&&
e
.
__esModule
?
function
(){
return
e
.
default
}:
function
(){
return
e
};
return
n
.
d
(
t
,
"a"
,
t
),
t
},
n
.
o
=
function
(
e
,
t
){
return
Object
.
prototype
.
hasOwnProperty
.
call
(
e
,
t
)},
n
.
p
=
"./"
,
n
(
n
.
s
=
213
)}({
105
:
function
(
e
,
t
){
e
.
exports
=
function
(
e
){
var
t
=
"undefined"
!=
typeof
window
&&
window
.
location
;
if
(
!
t
)
throw
new
Error
(
"fixUrls requires window.location"
);
if
(
!
e
||
"string"
!=
typeof
e
)
return
e
;
var
n
=
t
.
protocol
+
"//"
+
t
.
host
,
o
=
n
+
t
.
pathname
.
replace
(
/
\/[^\/]
*$/
,
"/"
);
return
e
.
replace
(
/url
\s
*
\(((?:[^
)(
]
|
\((?:[^
)(
]
+|
\([^
)(
]
*
\))
*
\))
*
)\)
/gi
,(
function
(
e
,
t
){
var
r
,
i
=
t
.
trim
().
replace
(
/^"
(
.*
)
"$/
,(
function
(
e
,
t
){
return
t
})).
replace
(
/^'
(
.*
)
'$/
,(
function
(
e
,
t
){
return
t
}));
return
/^
(
#|data:|http:
\/\/
|https:
\/\/
|file:
\/\/\/
|
\s
*$
)
/i
.
test
(
i
)?
e
:(
r
=
0
===
i
.
indexOf
(
"//"
)?
i
:
0
===
i
.
indexOf
(
"/"
)?
n
+
i
:
o
+
i
.
replace
(
/^
\.\/
/
,
""
),
"url("
+
JSON
.
stringify
(
r
)
+
")"
)}))}},
213
:
function
(
e
,
t
,
n
){
"use strict"
;
n
.
r
(
t
),
function
(
e
){
n
(
215
),
n
(
216
),
n
(
218
);
var
t
=
n
(
65
);
window
.
addEventListener
(
"click"
,(
function
(){
Object
.
keys
(
t
.
b
).
forEach
((
function
(
e
){
var
n
=
t
.
b
[
e
];
n
&&
n
.
closed
&&
n
.
closed
()}))})),
"object"
===
(
"undefined"
==
typeof
exports
?
"undefined"
:
_typeof
(
exports
))?
e
.
exports
=
t
.
c
:
"function"
==
typeof
define
&&
n
(
220
)?
define
(
xmSelect
):
window
.
layui
&&
layui
.
define
&&
layui
.
define
((
function
(
e
){
e
(
"xmSelect"
,
t
.
c
)})),
window
.
xmSelect
=
t
.
c
}.
call
(
this
,
n
(
214
)(
e
))},
214
:
function
(
e
,
t
){
e
.
exports
=
function
(
e
){
if
(
!
e
.
webpackPolyfill
){
var
t
=
Object
.
create
(
e
);
t
.
children
||
(
t
.
children
=
[]),
Object
.
defineProperty
(
t
,
"loaded"
,{
enumerable
:
!
0
,
get
:
function
(){
return
t
.
l
}}),
Object
.
defineProperty
(
t
,
"id"
,{
enumerable
:
!
0
,
get
:
function
(){
return
t
.
i
}}),
Object
.
defineProperty
(
t
,
"exports"
,{
enumerable
:
!
0
}),
t
.
webpackPolyfill
=
1
}
return
t
}},
215
:
function
(
e
,
t
){
Array
.
prototype
.
map
||
(
Array
.
prototype
.
map
=
function
(
e
,
t
){
var
n
,
o
,
r
,
i
=
Object
(
this
),
l
=
i
.
length
>>>
0
;
for
(
t
&&
(
n
=
t
),
o
=
new
Array
(
l
),
r
=
0
;
r
<
l
;){
var
a
,
s
;
r
in
i
&&
(
a
=
i
[
r
],
s
=
e
.
call
(
n
,
a
,
r
,
i
),
o
[
r
]
=
s
),
r
++
}
return
o
}),
Array
.
prototype
.
forEach
||
(
Array
.
prototype
.
forEach
=
function
(
e
,
t
){
var
n
,
o
;
if
(
null
==
this
)
throw
new
TypeError
(
"this is null or not defined"
);
var
r
=
Object
(
this
),
i
=
r
.
length
>>>
0
;
if
(
"function"
!=
typeof
e
)
throw
new
TypeError
(
e
+
" is not a function"
);
for
(
arguments
.
length
>
1
&&
(
n
=
t
),
o
=
0
;
o
<
i
;){
var
l
;
o
in
r
&&
(
l
=
r
[
o
],
e
.
call
(
n
,
l
,
o
,
r
)),
o
++
}}),
Array
.
prototype
.
filter
||
(
Array
.
prototype
.
filter
=
function
(
e
){
if
(
null
==
this
)
throw
new
TypeError
;
var
t
=
Object
(
this
),
n
=
t
.
length
>>>
0
;
if
(
"function"
!=
typeof
e
)
throw
new
TypeError
;
for
(
var
o
=
[],
r
=
arguments
[
1
],
i
=
0
;
i
<
n
;
i
++
)
if
(
i
in
t
){
var
l
=
t
[
i
];
e
.
call
(
r
,
l
,
i
,
t
)
&&
o
.
push
(
l
)}
return
o
}),
Array
.
prototype
.
find
||
(
Array
.
prototype
.
find
=
function
(
e
){
return
e
&&
(
this
.
filter
(
e
)
||
[])[
0
]}),
Array
.
prototype
.
findIndex
||
(
Array
.
prototype
.
findIndex
=
function
(
e
){
for
(
var
t
,
n
=
Object
(
this
),
o
=
n
.
length
>>>
0
,
r
=
arguments
[
1
],
i
=
0
;
i
<
o
;
i
++
)
if
(
t
=
n
[
i
],
e
.
call
(
r
,
t
,
i
,
n
))
return
i
;
return
-
1
})},
216
:
function
(
e
,
t
,
n
){
var
o
=
n
(
217
);
"string"
==
typeof
o
&&
(
o
=
[[
e
.
i
,
o
,
""
]]);
var
r
=
{
hmr
:
!
0
,
transform
:
void
0
,
insertInto
:
void
0
};
n
(
27
)(
o
,
r
);
o
.
locals
&&
(
e
.
exports
=
o
.
locals
)},
217
:
function
(
e
,
t
,
n
){(
t
=
n
(
26
)(
!
1
)).
push
([
e
.
i
,
"@-webkit-keyframes xm-upbit {\n from {\n -webkit-transform: translate3d(0, 30px, 0);\n opacity: 0.3;\n }\n to {\n -webkit-transform: translate3d(0, 0, 0);\n opacity: 1;\n }\n}\n@keyframes xm-upbit {\n from {\n transform: translate3d(0, 30px, 0);\n opacity: 0.3;\n }\n to {\n transform: translate3d(0, 0, 0);\n opacity: 1;\n }\n}\n@-webkit-keyframes loader {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n@keyframes loader {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\nxm-select {\n background-color: #FFF;\n position: relative;\n border: 1px solid #E6E6E6;\n border-radius: 2px;\n display: block;\n width: 100%;\n cursor: pointer;\n outline: none;\n}\nxm-select * {\n margin: 0;\n padding: 0;\n box-sizing: border-box;\n font-size: 14px;\n font-weight: 400;\n text-overflow: ellipsis;\n user-select: none;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n}\nxm-select:hover {\n border-color: #C0C4CC;\n}\nxm-select > .xm-tips {\n color: #999999;\n padding: 0 10px;\n position: absolute;\n display: flex;\n height: 100%;\n align-items: center;\n}\nxm-select > .xm-icon {\n display: inline-block;\n overflow: hidden;\n position: absolute;\n width: 0;\n height: 0;\n right: 10px;\n top: 50%;\n margin-top: -3px;\n cursor: pointer;\n border: 6px dashed transparent;\n border-top-color: #C2C2C2;\n border-top-style: solid;\n transition: all 0.3s;\n -webkit-transition: all 0.3s;\n}\nxm-select > .xm-icon-expand {\n margin-top: -9px;\n transform: rotate(180deg);\n}\nxm-select > .xm-label.single-row {\n position: absolute;\n top: 0;\n bottom: 0px;\n left: 0px;\n right: 30px;\n overflow: auto hidden;\n}\nxm-select > .xm-label.single-row .scroll {\n overflow-y: hidden;\n}\nxm-select > .xm-label.single-row .label-content {\n flex-wrap: nowrap;\n}\nxm-select > .xm-label.auto-row .label-content {\n flex-wrap: wrap;\n}\nxm-select > .xm-label.auto-row .xm-label-block > span {\n white-space: unset;\n height: 100%;\n}\nxm-select > .xm-label .scroll .label-content {\n display: flex;\n padding: 3px 30px 3px 10px;\n}\nxm-select > .xm-label .xm-label-block {\n display: flex;\n position: relative;\n padding: 0px 5px;\n margin: 2px 5px 2px 0;\n border-radius: 3px;\n align-items: baseline;\n color: #FFF;\n}\nxm-select > .xm-label .xm-label-block > span {\n display: flex;\n color: #FFF;\n white-space: nowrap;\n}\nxm-select > .xm-label .xm-label-block > i {\n color: #FFF;\n margin-left: 8px;\n font-size: 12px;\n cursor: pointer;\n display: flex;\n}\nxm-select > .xm-label .xm-label-block.disabled {\n background-color: #C2C2C2 !important;\n cursor: no-drop !important;\n}\nxm-select > .xm-label .xm-label-block.disabled > i {\n cursor: no-drop !important;\n}\nxm-select > .xm-body {\n position: absolute;\n left: 0;\n top: 42px;\n padding: 5px 0;\n z-index: 999;\n width: 100%;\n min-width: fit-content;\n border: 1px solid #E6E6E6;\n background-color: #fff;\n border-radius: 2px;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12);\n animation-name: xm-upbit;\n animation-duration: 0.3s;\n animation-fill-mode: both;\n}\nxm-select > .xm-body .scroll-body {\n overflow-x: hidden;\n overflow-y: auto;\n}\nxm-select > .xm-body .scroll-body::-webkit-scrollbar {\n width: 8px;\n}\nxm-select > .xm-body .scroll-body::-webkit-scrollbar-track {\n -webkit-border-radius: 2em;\n -moz-border-radius: 2em;\n -ms-border-radius: 2em;\n border-radius: 2em;\n background-color: #FFF;\n}\nxm-select > .xm-body .scroll-body::-webkit-scrollbar-thumb {\n -webkit-border-radius: 2em;\n -moz-border-radius: 2em;\n -ms-border-radius: 2em;\n border-radius: 2em;\n background-color: #C2C2C2;\n}\nxm-select > .xm-body.up {\n top: auto;\n bottom: 42px;\n}\nxm-select > .xm-body.relative {\n position: relative;\n display: block !important;\n top: 0;\n box-shadow: none;\n border: none;\n animation-name: none;\n animation-duration: 0;\n min-width: 100%;\n}\nxm-select > .xm-body .xm-group {\n cursor: default;\n}\nxm-select > .xm-body .xm-group-item {\n display: inline-block;\n cursor: pointer;\n padding: 0 10px;\n color: #999;\n font-size: 12px;\n}\nxm-select > .xm-body .xm-option {\n display: flex;\n align-items: center;\n position: relative;\n padding: 0 10px;\n cursor: pointer;\n}\nxm-select > .xm-body .xm-option-icon {\n color: transparent;\n display: flex;\n border: 1px solid #E6E6E6;\n border-radius: 3px;\n justify-content: center;\n align-items: center;\n}\nxm-select > .xm-body .xm-option-icon.xm-icon-danx {\n border-radius: 100%;\n}\nxm-select > .xm-body .xm-option-content {\n display: flex;\n position: relative;\n padding-left: 15px;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n color: #666;\n width: calc(100% - 20px);\n}\nxm-select > .xm-body .xm-option.hide-icon .xm-option-content {\n padding-left: 0;\n}\nxm-select > .xm-body .xm-option.selected.hide-icon .xm-option-content {\n color: #FFF !important;\n}\nxm-select > .xm-body .xm-option .loader {\n width: 0.8em;\n height: 0.8em;\n margin-right: 6px;\n color: #C2C2C2;\n}\nxm-select > .xm-body .xm-select-empty {\n text-align: center;\n color: #999;\n}\nxm-select > .xm-body .disabled {\n cursor: no-drop;\n}\nxm-select > .xm-body .disabled:hover {\n background-color: #FFF;\n}\nxm-select > .xm-body .disabled .xm-option-icon {\n border-color: #C2C2C2 !important;\n}\nxm-select > .xm-body .disabled .xm-option-content {\n color: #C2C2C2 !important;\n}\nxm-select > .xm-body .disabled.selected > .xm-option-icon {\n color: #C2C2C2 !important;\n}\nxm-select > .xm-body .xm-search {\n background-color: #FFF !important;\n position: relative;\n padding: 0 10px;\n margin-bottom: 5px;\n cursor: pointer;\n}\nxm-select > .xm-body .xm-search > i {\n position: absolute;\n color: #666;\n}\nxm-select > .xm-body .xm-search-input {\n border: none;\n border-bottom: 1px solid #E6E6E6;\n padding-left: 27px;\n cursor: text;\n}\nxm-select > .xm-body .xm-paging {\n padding: 0 10px;\n display: flex;\n margin-top: 5px;\n}\nxm-select > .xm-body .xm-paging > span:first-child {\n border-radius: 2px 0 0 2px;\n}\nxm-select > .xm-body .xm-paging > span:last-child {\n border-radius: 0 2px 2px 0;\n}\nxm-select > .xm-body .xm-paging > span {\n display: flex;\n flex: auto;\n justify-content: center;\n vertical-align: middle;\n margin: 0 -1px 0 0;\n background-color: #fff;\n color: #333;\n font-size: 12px;\n border: 1px solid #e2e2e2;\n flex-wrap: nowrap;\n width: 100%;\n overflow: hidden;\n min-width: 50px;\n}\nxm-select > .xm-body .xm-toolbar {\n padding: 0 10px;\n display: flex;\n margin: -3px 0;\n cursor: default;\n}\nxm-select > .xm-body .xm-toolbar .toolbar-tag {\n cursor: pointer;\n display: flex;\n margin-right: 20px;\n color: #666;\n align-items: baseline;\n}\nxm-select > .xm-body .xm-toolbar .toolbar-tag:hover {\n opacity: 0.8;\n}\nxm-select > .xm-body .xm-toolbar .toolbar-tag:active {\n opacity: 1;\n}\nxm-select > .xm-body .xm-toolbar .toolbar-tag > i {\n margin-right: 2px;\n font-size: 14px;\n}\nxm-select > .xm-body .xm-toolbar .toolbar-tag:last-child {\n margin-right: 0;\n}\nxm-select > .xm-body .xm-body-custom {\n line-height: initial;\n cursor: default;\n}\nxm-select > .xm-body .xm-body-custom * {\n box-sizing: initial;\n}\nxm-select > .xm-body .xm-tree {\n position: relative;\n}\nxm-select > .xm-body .xm-tree-icon {\n display: inline-block;\n margin-right: 3px;\n cursor: pointer;\n border: 6px dashed transparent;\n border-left-color: #C2C2C2;\n border-left-style: solid;\n transition: all 0.3s;\n -webkit-transition: all 0.3s;\n z-index: 2;\n visibility: hidden;\n}\nxm-select > .xm-body .xm-tree-icon.expand {\n margin-top: 3px;\n margin-right: 5px;\n margin-left: -2px;\n transform: rotate(90deg);\n}\nxm-select > .xm-body .xm-tree-icon.xm-visible {\n visibility: visible;\n}\nxm-select > .xm-body .xm-tree .left-line {\n position: absolute;\n left: 13px;\n width: 0;\n z-index: 1;\n border-left: 1px dotted #c0c4cc !important;\n}\nxm-select > .xm-body .xm-tree .top-line {\n position: absolute;\n left: 13px;\n height: 0;\n z-index: 1;\n border-top: 1px dotted #c0c4cc !important;\n}\nxm-select > .xm-body .xm-tree .xm-tree-icon + .top-line {\n margin-left: 1px;\n}\nxm-select > .xm-body .scroll-body > .xm-tree > .xm-option > .top-line,\nxm-select > .xm-body .scroll-body > .xm-option > .top-line {\n width: 0 !important;\n}\nxm-select > .xm-body .xm-cascader-box {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n padding: 5px 0;\n border: 1px solid #E6E6E6;\n background-color: #fff;\n border-radius: 2px;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12);\n margin: -1px;\n}\nxm-select > .xm-body .xm-cascader-box::before {\n content: ' ';\n position: absolute;\n width: 0;\n height: 0;\n border: 6px solid transparent;\n border-right-color: #E6E6E6;\n top: 10px;\n left: -12px;\n}\nxm-select > .xm-body .xm-cascader-box::after {\n content: ' ';\n position: absolute;\n width: 0;\n height: 0;\n border: 6px solid transparent;\n border-right-color: #fff;\n top: 10px;\n left: -11px;\n}\nxm-select > .xm-body .xm-cascader-scroll {\n height: 100%;\n overflow-x: hidden;\n overflow-y: auto;\n}\nxm-select > .xm-body.cascader {\n width: unset;\n min-width: unset;\n}\nxm-select > .xm-body.cascader .xm-option-content {\n padding-left: 8px;\n}\nxm-select > .xm-body.cascader .disabled .xm-right-arrow {\n color: #C2C2C2 !important;\n}\nxm-select .xm-input {\n cursor: pointer;\n border-radius: 2px;\n border-width: 1px;\n border-style: solid;\n border-color: #E6E6E6;\n display: block;\n width: 100%;\n box-sizing: border-box;\n background-color: #FFF;\n line-height: 1.3;\n padding-left: 10px;\n outline: 0;\n user-select: text;\n -ms-user-select: text;\n -moz-user-select: text;\n -webkit-user-select: text;\n}\nxm-select .dis {\n display: none;\n}\nxm-select .loading {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: rgba(255, 255, 255, 0.6);\n display: flex;\n align-items: center;\n justify-content: center;\n}\nxm-select .loader {\n border: 0.2em dotted currentcolor;\n border-radius: 50%;\n -webkit-animation: 1s loader linear infinite;\n animation: 1s loader linear infinite;\n display: inline-block;\n width: 1em;\n height: 1em;\n color: inherit;\n vertical-align: middle;\n pointer-events: none;\n}\nxm-select .xm-select-default {\n position: absolute;\n width: 100%;\n height: 100%;\n border: none;\n visibility: hidden;\n}\nxm-select .xm-select-disabled {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n cursor: no-drop;\n z-index: 2;\n opacity: 0.3;\n background-color: #FFF;\n}\nxm-select .item--divided {\n border-top: 1px solid #ebeef5;\n width: calc(100% - 20px);\n cursor: initial;\n}\nxm-select .xm-right-arrow {\n position: absolute;\n color: #666;\n right: 5px;\n top: -1px;\n font-weight: 700;\n transform: scale(0.6, 1);\n}\nxm-select .xm-right-arrow::after {\n content: '>';\n}\nxm-select[size='large'] {\n min-height: 40px;\n line-height: 40px;\n}\nxm-select[size='large'] .xm-input {\n height: 40px;\n}\nxm-select[size='large'] .xm-label .scroll .label-content {\n line-height: 34px;\n}\nxm-select[size='large'] .xm-label .xm-label-block {\n height: 30px;\n line-height: 30px;\n}\nxm-select[size='large'] .xm-body .xm-option .xm-option-icon {\n height: 20px;\n width: 20px;\n font-size: 20px;\n}\nxm-select[size='large'] .xm-paging > span {\n height: 34px;\n line-height: 34px;\n}\nxm-select[size='large'] .xm-tree .left-line {\n height: 100%;\n bottom: 20px;\n}\nxm-select[size='large'] .xm-tree .left-line-group {\n height: calc(100% - 40px);\n}\nxm-select[size='large'] .xm-tree .xm-tree-icon.xm-hidden + .top-line {\n top: 19px;\n}\nxm-select[size='large'] .item--divided {\n margin: 10px;\n}\nxm-select {\n min-height: 36px;\n line-height: 36px;\n}\nxm-select .xm-input {\n height: 36px;\n}\nxm-select .xm-label .scroll .label-content {\n line-height: 30px;\n}\nxm-select .xm-label .xm-label-block {\n height: 26px;\n line-height: 26px;\n}\nxm-select .xm-body .xm-option .xm-option-icon {\n height: 18px;\n width: 18px;\n font-size: 18px;\n}\nxm-select .xm-paging > span {\n height: 30px;\n line-height: 30px;\n}\nxm-select .xm-tree .left-line {\n height: 100%;\n bottom: 18px;\n}\nxm-select .xm-tree .left-line-group {\n height: calc(100% - 36px);\n}\nxm-select .xm-tree .xm-tree-icon.xm-hidden + .top-line {\n top: 17px;\n}\nxm-select .item--divided {\n margin: 9px;\n}\nxm-select[size='small'] {\n min-height: 32px;\n line-height: 32px;\n}\nxm-select[size='small'] .xm-input {\n height: 32px;\n}\nxm-select[size='small'] .xm-label .scroll .label-content {\n line-height: 26px;\n}\nxm-select[size='small'] .xm-label .xm-label-block {\n height: 22px;\n line-height: 22px;\n}\nxm-select[size='small'] .xm-body .xm-option .xm-option-icon {\n height: 16px;\n width: 16px;\n font-size: 16px;\n}\nxm-select[size='small'] .xm-paging > span {\n height: 26px;\n line-height: 26px;\n}\nxm-select[size='small'] .xm-tree .left-line {\n height: 100%;\n bottom: 16px;\n}\nxm-select[size='small'] .xm-tree .left-line-group {\n height: calc(100% - 32px);\n}\nxm-select[size='small'] .xm-tree .xm-tree-icon.xm-hidden + .top-line {\n top: 15px;\n}\nxm-select[size='small'] .item--divided {\n margin: 8px;\n}\nxm-select[size='mini'] {\n min-height: 28px;\n line-height: 28px;\n}\nxm-select[size='mini'] .xm-input {\n height: 28px;\n}\nxm-select[size='mini'] .xm-label .scroll .label-content {\n line-height: 22px;\n}\nxm-select[size='mini'] .xm-label .xm-label-block {\n height: 18px;\n line-height: 18px;\n}\nxm-select[size='mini'] .xm-body .xm-option .xm-option-icon {\n height: 14px;\n width: 14px;\n font-size: 14px;\n}\nxm-select[size='mini'] .xm-paging > span {\n height: 22px;\n line-height: 22px;\n}\nxm-select[size='mini'] .xm-tree .left-line {\n height: 100%;\n bottom: 14px;\n}\nxm-select[size='mini'] .xm-tree .left-line-group {\n height: calc(100% - 28px);\n}\nxm-select[size='mini'] .xm-tree .xm-tree-icon.xm-hidden + .top-line {\n top: 13px;\n}\nxm-select[size='mini'] .item--divided {\n margin: 7px;\n}\n.layui-form-pane xm-select {\n margin: -1px -1px -1px 0;\n}\n"
,
""
]),
e
.
exports
=
t
},
218
:
function
(
e
,
t
,
n
){
var
o
=
n
(
219
);
"string"
==
typeof
o
&&
(
o
=
[[
e
.
i
,
o
,
""
]]);
var
r
=
{
hmr
:
!
0
,
transform
:
void
0
,
insertInto
:
void
0
};
n
(
27
)(
o
,
r
);
o
.
locals
&&
(
e
.
exports
=
o
.
locals
)},
219
:
function
(
e
,
t
,
n
){(
t
=
n
(
26
)(
!
1
)).
push
([
e
.
i
,
'@font-face {\n font-family: "xm-iconfont";\n src: url(\'//at.alicdn.com/t/font_792691_ptvyboo0bno.eot?t=1574048839056\');\n /* IE9 */\n src: url(\'//at.alicdn.com/t/font_792691_ptvyboo0bno.eot?t=1574048839056#iefix\') format(\'embedded-opentype\'), /* IE6-IE8 */ url(\'data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAksAAsAAAAAEYAAAAjeAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCEUgqTXI8lATYCJAM0CxwABCAFhG0HgTwbZQ4jEbaCkVIj+4sD3sS6BFAp9ka91ulVG4leTC/+h+3V+zyRYCTyREKkcZ+D5/u137lPdveLGJBMunoiNPOQPBMq0/FQtEKIkMRDZng69d+hOiQumAr7bJdBOEzMTU77s78mhbI58aCg7ebCs4LBTgCk+cD/4ZqWUHebipp7al3tyKOjwCV/hVyw9PdzaktxI7IMQs26/1N8gV4DI0bVut3UhCaflGGgwM3oTXg1IfRMbCsmrEnriJVeYM2eXHII4KdMMzL4OoACHgZBCTasITcReDUBE8kWPLMTCGoQaDV+eKpUPQI49r8vP6BTPIDCaiBSml3oOQX0voNPebv/u2P0AUfP1w0s5EADzYBZsNdByylo2eVq/NtRdgFpovQR5x2CIwmIZeik6/u0T/m/A7RJP00sCmmyksj/kwc+LC5BFBqDEMDDjwPiANDB9MpJTXwHmsO3YyBwWDA4OFwwJLRcRgAOBUYMDg0mHRwGTAYozsV0AgWYruDwwExDHfzwKWf4OurQ9jzQDtoF+wpistfBfluQ5bQiiJa4ZQoKhShLiMayBbyg05AIkYBoIBJEEApQy/FwYv4HchADIUBXl61dW6mpwIgyp7p8PrHddieSjhY9oqTxyPB/FGNYDklpfYh8VtaoqSgb0bKoGB17CuVUp9Ll2nS2UpNGMSw9hyirA7C6+QLyByIQS0sSSmxvArC5odZmYZMxZSiBR5OkQl0uiufxMH5eL8t3u0d4XKyuq6EMdcpNe2+oXA8p9yPa+4T1PM7+A54tc7tpl2vcAHAftnhZj2chy1CyaCRFsyMqQ5nkNnskEt2yxxZinPsOZjFm4+XWvKqLkfCGS1k4MNP82isxSMf7ZsGYvQVCNAeSSVtzWCxRdXGxyZlA2CvCEevuO7y9M2z2NWH8icydzq/qAJSp1lGvDWFp6Nw3xChJowPD+76nU+upQk6Kw9jI0Rgym9Ct8VlxMI3CSIaDCZja5tDYt0/EYra4tn0Kp3v8Rdezk8svcy1mKhoSvNcZz3LKlUe777Gmval0s7bzAc0k13LGk896V9DuvNn34N0ebKgItkQgOomuJtgQPChNI4cwa7CEWCvfk5QjJFlem6i3SfVShWi5LTFRG+JwdCNpSqbpRFwrtb1TbcRkJi/AbJJQOmfCdnswLNGVM7qqSRO1zO0Q0j5Vr3cYQ07HB0MX6KoIZhx+D9Djs2C5bXtVwvbgJHtSCIL7hjFJme4sZDdS5IlJdKUO1Qt8opn0trBafz3AX933kmCRgyMEWGZjMAkRKhwmIHJGR4ruwFCdWKYzrap2R/mvd2UKajzRAZu88pGAD90Y+02kTFCKrBSXwGGJ3wRcPCdIppTxSmHOfESRwIli0S5J/8AYDCxTGh4XZua4xvfvGx320rDK2qA8g5FlS7pWNLx71+BwgA/KZ5I0aeKmNeCNoNPl8qNHu8uHHzqaKc86fHi4vPuRI4ny+I/vjxw+clh4HXVCFvVnVFx07EHZwVhSRliTTMWSEi0h6YuS6DxCRmiin0B3L4ry6cvR0ijYexFdBL3wGQM0YOrUAZCBkLOBBtQ+xdk7omfgUv+u++admyUeXduyxLM+r/+49rPfhgEZor6GymToNYksNsZyC7ntwAH0928UpgMpxpF0ydNlsMMBw7QsxTCmu0Hf3F+/+vb99Yumhb+e9R0LBNm+4O+hu7lQ5bGjI9j5G88qQ5SLFyuEC7cwd25xoYo2j4eA4bhpM7TZhPtmc+uhVEVSMYXLWh0bfjI8dvUpvDUocPZmU4kwwOfc83wB5wPehrpD3waApbwW+fgRrZXcxw+mB/3woZT+8JFMYwRMIy2k/18qhqcKpjYeYSnIACaUoRDu0e3kQFh98R5fiI8oJqwwGZSJDSbehLzZs7zIeWTQ4UGOIs2c4j2/Q/tn7n7j9juO33On6WhURCT/wO6Y3QdmWFY0Ef6JUeGRggO7ZbtaZlh5RYKWXbLPBLc3l/5h4A0mu3ZXTZ+u6t6VHMAzZhxak50T+24NnRuaOmehRkXlqVR5lIpuwezUUDUdCuJysv8Z/0/8uNE1s7jIJIubFWnI/x7g4nAZx79yYpFoAOU3a9iwT1O/GxUxPY0ljVPv9EukI3qNrl/So2YfzasqHCroNjS0+w0tlPlsYfC6v/01ixquizJH1Kd/VK+OS3iS3rTJWmqsMPdU3B3oFyC9RSumWE/0gG36IjTysfH51IJ/5oOgNYu6p4yb5Fdufhr/Kjtu0oSyYP/WJQrz35aNFnMhtFcwb55NlNnH8Wdu1b+XZA9zqlZrhdPo/V3uBhiUlQ66h0LhbAmFYIncdFOpVMh6Fl7peqy5Z2ZdQBITO2x1Asj1dRFjIBMC3hbuUh8Ooc4W03EjAdo8UL/t0oUfyU8630bmMcw/vqDNAsC9BQD4OqCgH+ljy0UhJB8AAJA+8EmArxk5gnRLik90AElf8rBm+IMvBTWnucb3+0o0ARk+r0ZBv8sU01nnSmP45/H8Dp8C8X+iE9e+ZvXymK/sQJ5/DuqhYKebPnKmPqLYuDcIMWS2/Rjxp2s8Do821LVn6A/xMK1RKvBLK5gyDsZ5uQ6bYusmx2yqLFe4lECHDPcFhojmckuAbnCI6Cn308RI6AAJdtCICQLQyBHKhSgX5YowN6BBPIEB8VxuSfNncpAuutzPnCSiDHDEo+DsKQBPoJi4MpRktepIs2zjO5h84IEMM3ffECKSZU1ZHxfewEI4h494MuuUNNOBjuw18QKHAzEXaAcylS3m3baq9MpnKenYmfEUgCdbXTHEtTVKsvruNGv9/DuYfOAhcuKu9TeEiA9nNJTUDOUbbVkn3sv2eDJrEnVrpvcHOjJeqRsOcpYYLuxoBzKVtCOm3ZaKbtJcurw+e/zN6c7Pd6r4gqUo0WLEiiOueOITvwQkKCEJM9nO3F60y5HkqLhdqUyXZtK3lqwReQ+G40O92UhOt0x/KmKM+u7LTPMzoEBOCYtiUPfSjODiuFXjSDm2idzAoc4Tj9bs2eJYDOU7HQA=\') format(\'woff2\'), url(\'//at.alicdn.com/t/font_792691_ptvyboo0bno.woff?t=1574048839056\') format(\'woff\'), url(\'//at.alicdn.com/t/font_792691_ptvyboo0bno.ttf?t=1574048839056\') format(\'truetype\'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */ url(\'//at.alicdn.com/t/font_792691_ptvyboo0bno.svg?t=1574048839056#iconfont\') format(\'svg\');\n /* iOS 4.1- */\n}\n.xm-iconfont {\n font-family: "xm-iconfont" !important;\n font-size: 16px;\n font-style: normal;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n.xm-icon-quanxuan:before {\n content: "\\e62c";\n}\n.xm-icon-caidan:before {\n content: "\\e610";\n}\n.xm-icon-fanxuan:before {\n content: "\\e837";\n}\n.xm-icon-pifu:before {\n content: "\\e668";\n}\n.xm-icon-qingkong:before {\n content: "\\e63e";\n}\n.xm-icon-sousuo:before {\n content: "\\e600";\n}\n.xm-icon-danx:before {\n content: "\\e62b";\n}\n.xm-icon-duox:before {\n content: "\\e613";\n}\n.xm-icon-close:before {\n content: "\\e601";\n}\n.xm-icon-expand:before {\n content: "\\e641";\n}\n.xm-icon-banxuan:before {\n content: "\\e60d";\n}\n'
,
""
]),
e
.
exports
=
t
},
220
:
function
(
e
,
t
){(
function
(
t
){
e
.
exports
=
t
}).
call
(
this
,{})},
26
:
function
(
e
,
t
,
n
){
"use strict"
;
e
.
exports
=
function
(
e
){
var
t
=
[];
return
t
.
toString
=
function
(){
return
this
.
map
((
function
(
t
){
var
n
=
function
(
e
,
t
){
var
n
=
e
[
1
]
||
""
,
o
=
e
[
3
];
if
(
!
o
)
return
n
;
if
(
t
&&
"function"
==
typeof
btoa
){
var
r
=
function
(
e
){
var
t
=
btoa
(
unescape
(
encodeURIComponent
(
JSON
.
stringify
(
e
)))),
n
=
"sourceMappingURL=data:application/json;charset=utf-8;base64,"
.
concat
(
t
);
return
"/*# "
.
concat
(
n
,
" */"
)}(
o
),
i
=
o
.
sources
.
map
((
function
(
e
){
return
"/*# sourceURL="
.
concat
(
o
.
sourceRoot
||
""
).
concat
(
e
,
" */"
)}));
return
[
n
].
concat
(
i
).
concat
([
r
]).
join
(
"\n"
)}
return
[
n
].
join
(
"\n"
)}(
t
,
e
);
return
t
[
2
]?
"@media "
.
concat
(
t
[
2
],
" {"
).
concat
(
n
,
"}"
):
n
})).
join
(
""
)},
t
.
i
=
function
(
e
,
n
,
o
){
"string"
==
typeof
e
&&
(
e
=
[[
null
,
e
,
""
]]);
var
r
=
{};
if
(
o
)
for
(
var
i
=
0
;
i
<
this
.
length
;
i
++
){
var
l
=
this
[
i
][
0
];
null
!=
l
&&
(
r
[
l
]
=!
0
)}
for
(
var
a
=
0
;
a
<
e
.
length
;
a
++
){
var
s
=
[].
concat
(
e
[
a
]);
o
&&
r
[
s
[
0
]]
||
(
n
&&
(
s
[
2
]?
s
[
2
]
=
""
.
concat
(
n
,
" and "
).
concat
(
s
[
2
]):
s
[
2
]
=
n
),
t
.
push
(
s
))}},
t
}},
27
:
function
(
e
,
t
,
n
){
var
o
,
r
,
i
=
{},
l
=
(
o
=
function
(){
return
window
&&
document
&&
document
.
all
&&!
window
.
atob
},
function
(){
return
void
0
===
r
&&
(
r
=
o
.
apply
(
this
,
arguments
)),
r
}),
a
=
function
(
e
,
t
){
return
t
?
t
.
querySelector
(
e
):
document
.
querySelector
(
e
)},
s
=
function
(
e
){
var
t
=
{};
return
function
(
e
,
n
){
if
(
"function"
==
typeof
e
)
return
e
();
if
(
void
0
===
t
[
e
]){
var
o
=
a
.
call
(
this
,
e
,
n
);
if
(
window
.
HTMLIFrameElement
&&
o
instanceof
window
.
HTMLIFrameElement
)
try
{
o
=
o
.
contentDocument
.
head
}
catch
(
e
){
o
=
null
}
t
[
e
]
=
o
}
return
t
[
e
]}}(),
c
=
null
,
u
=
0
,
p
=
[],
f
=
n
(
105
);
function
d
(
e
,
t
){
for
(
var
n
=
0
;
n
<
e
.
length
;
n
++
){
var
o
=
e
[
n
],
r
=
i
[
o
.
id
];
if
(
r
){
r
.
refs
++
;
for
(
var
l
=
0
;
l
<
r
.
parts
.
length
;
l
++
)
r
.
parts
[
l
](
o
.
parts
[
l
]);
for
(;
l
<
o
.
parts
.
length
;
l
++
)
r
.
parts
.
push
(
v
(
o
.
parts
[
l
],
t
))}
else
{
var
a
=
[];
for
(
l
=
0
;
l
<
o
.
parts
.
length
;
l
++
)
a
.
push
(
v
(
o
.
parts
[
l
],
t
));
i
[
o
.
id
]
=
{
id
:
o
.
id
,
refs
:
1
,
parts
:
a
}}}}
function
h
(
e
,
t
){
for
(
var
n
=
[],
o
=
{},
r
=
0
;
r
<
e
.
length
;
r
++
){
var
i
=
e
[
r
],
l
=
t
.
base
?
i
[
0
]
+
t
.
base
:
i
[
0
],
a
=
{
css
:
i
[
1
],
media
:
i
[
2
],
sourceMap
:
i
[
3
]};
o
[
l
]?
o
[
l
].
parts
.
push
(
a
):
n
.
push
(
o
[
l
]
=
{
id
:
l
,
parts
:[
a
]})}
return
n
}
function
m
(
e
,
t
){
var
n
=
s
(
e
.
insertInto
);
if
(
!
n
)
throw
new
Error
(
"Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."
);
var
o
=
p
[
p
.
length
-
1
];
if
(
"top"
===
e
.
insertAt
)
o
?
o
.
nextSibling
?
n
.
insertBefore
(
t
,
o
.
nextSibling
):
n
.
appendChild
(
t
):
n
.
insertBefore
(
t
,
n
.
firstChild
),
p
.
push
(
t
);
else
if
(
"bottom"
===
e
.
insertAt
)
n
.
appendChild
(
t
);
else
{
if
(
"object"
!=
typeof
e
.
insertAt
||!
e
.
insertAt
.
before
)
throw
new
Error
(
"[Style Loader]\n\n Invalid value for parameter 'insertAt' ('options.insertAt') found.\n Must be 'top', 'bottom', or Object.\n (https://github.com/webpack-contrib/style-loader#insertat)\n"
);
var
r
=
s
(
e
.
insertAt
.
before
,
n
);
n
.
insertBefore
(
t
,
r
)}}
function
b
(
e
){
if
(
null
===
e
.
parentNode
)
return
!
1
;
e
.
parentNode
.
removeChild
(
e
);
var
t
=
p
.
indexOf
(
e
);
t
>=
0
&&
p
.
splice
(
t
,
1
)}
function
y
(
e
){
var
t
=
document
.
createElement
(
"style"
);
if
(
void
0
===
e
.
attrs
.
type
&&
(
e
.
attrs
.
type
=
"text/css"
),
void
0
===
e
.
attrs
.
nonce
){
var
o
=
function
(){
0
;
return
n
.
nc
}();
o
&&
(
e
.
attrs
.
nonce
=
o
)}
return
x
(
t
,
e
.
attrs
),
m
(
e
,
t
),
t
}
function
x
(
e
,
t
){
Object
.
keys
(
t
).
forEach
((
function
(
n
){
e
.
setAttribute
(
n
,
t
[
n
])}))}
function
v
(
e
,
t
){
var
n
,
o
,
r
,
i
;
if
(
t
.
transform
&&
e
.
css
){
if
(
!
(
i
=
"function"
==
typeof
t
.
transform
?
t
.
transform
(
e
.
css
):
t
.
transform
.
default
(
e
.
css
)))
return
function
(){};
e
.
css
=
i
}
if
(
t
.
singleton
){
var
l
=
u
++
;
n
=
c
||
(
c
=
y
(
t
)),
o
=
w
.
bind
(
null
,
n
,
l
,
!
1
),
r
=
w
.
bind
(
null
,
n
,
l
,
!
0
)}
else
e
.
sourceMap
&&
"function"
==
typeof
URL
&&
"function"
==
typeof
URL
.
createObjectURL
&&
"function"
==
typeof
URL
.
revokeObjectURL
&&
"function"
==
typeof
Blob
&&
"function"
==
typeof
btoa
?(
n
=
function
(
e
){
var
t
=
document
.
createElement
(
"link"
);
return
void
0
===
e
.
attrs
.
type
&&
(
e
.
attrs
.
type
=
"text/css"
),
e
.
attrs
.
rel
=
"stylesheet"
,
x
(
t
,
e
.
attrs
),
m
(
e
,
t
),
t
}(
t
),
o
=
C
.
bind
(
null
,
n
,
t
),
r
=
function
(){
b
(
n
),
n
.
href
&&
URL
.
revokeObjectURL
(
n
.
href
)}):(
n
=
y
(
t
),
o
=
k
.
bind
(
null
,
n
),
r
=
function
(){
b
(
n
)});
return
o
(
e
),
function
(
t
){
if
(
t
){
if
(
t
.
css
===
e
.
css
&&
t
.
media
===
e
.
media
&&
t
.
sourceMap
===
e
.
sourceMap
)
return
;
o
(
e
=
t
)}
else
r
()}}
e
.
exports
=
function
(
e
,
t
){
if
(
"undefined"
!=
typeof
DEBUG
&&
DEBUG
&&
"object"
!=
typeof
document
)
throw
new
Error
(
"The style-loader cannot be used in a non-browser environment"
);(
t
=
t
||
{}).
attrs
=
"object"
==
typeof
t
.
attrs
?
t
.
attrs
:{},
t
.
singleton
||
"boolean"
==
typeof
t
.
singleton
||
(
t
.
singleton
=
l
()),
t
.
insertInto
||
(
t
.
insertInto
=
"head"
),
t
.
insertAt
||
(
t
.
insertAt
=
"bottom"
);
var
n
=
h
(
e
,
t
);
return
d
(
n
,
t
),
function
(
e
){
for
(
var
o
=
[],
r
=
0
;
r
<
n
.
length
;
r
++
){
var
l
=
n
[
r
];(
a
=
i
[
l
.
id
]).
refs
--
,
o
.
push
(
a
)}
e
&&
d
(
h
(
e
,
t
),
t
);
for
(
r
=
0
;
r
<
o
.
length
;
r
++
){
var
a
;
if
(
0
===
(
a
=
o
[
r
]).
refs
){
for
(
var
s
=
0
;
s
<
a
.
parts
.
length
;
s
++
)
a
.
parts
[
s
]();
delete
i
[
a
.
id
]}}}};
var
g
,
_
=
(
g
=
[],
function
(
e
,
t
){
return
g
[
e
]
=
t
,
g
.
filter
(
Boolean
).
join
(
"\n"
)});
function
w
(
e
,
t
,
n
,
o
){
var
r
=
n
?
""
:
o
.
css
;
if
(
e
.
styleSheet
)
e
.
styleSheet
.
cssText
=
_
(
t
,
r
);
else
{
var
i
=
document
.
createTextNode
(
r
),
l
=
e
.
childNodes
;
l
[
t
]
&&
e
.
removeChild
(
l
[
t
]),
l
.
length
?
e
.
insertBefore
(
i
,
l
[
t
]):
e
.
appendChild
(
i
)}}
function
k
(
e
,
t
){
var
n
=
t
.
css
,
o
=
t
.
media
;
if
(
o
&&
e
.
setAttribute
(
"media"
,
o
),
e
.
styleSheet
)
e
.
styleSheet
.
cssText
=
n
;
else
{
for
(;
e
.
firstChild
;)
e
.
removeChild
(
e
.
firstChild
);
e
.
appendChild
(
document
.
createTextNode
(
n
))}}
function
C
(
e
,
t
,
n
){
var
o
=
n
.
css
,
r
=
n
.
sourceMap
,
i
=
void
0
===
t
.
convertToAbsoluteUrls
&&
r
;(
t
.
convertToAbsoluteUrls
||
i
)
&&
(
o
=
f
(
o
)),
r
&&
(
o
+=
"\n/*# sourceMappingURL=data:application/json;base64,"
+
btoa
(
unescape
(
encodeURIComponent
(
JSON
.
stringify
(
r
))))
+
" */"
);
var
l
=
new
Blob
([
o
],{
type
:
"text/css"
}),
a
=
e
.
href
;
e
.
href
=
URL
.
createObjectURL
(
l
),
a
&&
URL
.
revokeObjectURL
(
a
)}},
40
:
function
(
e
){
e
.
exports
=
JSON
.
parse
(
'{"a":"xm-select","b":"1.1.9"}'
)},
65
:
function
(
e
,
t
,
n
){
"use strict"
;
n
.
d
(
t
,
"b"
,(
function
(){
return
nt
})),
n
.
d
(
t
,
"d"
,(
function
(){
return
ot
})),
n
.
d
(
t
,
"a"
,(
function
(){
return
rt
}));
var
o
=
n
(
40
);
function
r
(
e
,
t
){
var
n
=
Object
.
keys
(
e
);
if
(
Object
.
getOwnPropertySymbols
){
var
o
=
Object
.
getOwnPropertySymbols
(
e
);
t
&&
(
o
=
o
.
filter
((
function
(
t
){
return
Object
.
getOwnPropertyDescriptor
(
e
,
t
).
enumerable
}))),
n
.
push
.
apply
(
n
,
o
)}
return
n
}
function
i
(
e
,
t
,
n
){
return
t
in
e
?
Object
.
defineProperty
(
e
,
t
,{
value
:
n
,
enumerable
:
!
0
,
configurable
:
!
0
,
writable
:
!
0
}):
e
[
t
]
=
n
,
e
}
function
l
(
e
){
return
function
(
e
){
if
(
Array
.
isArray
(
e
))
return
a
(
e
)}(
e
)
||
function
(
e
){
if
(
"undefined"
!=
typeof
Symbol
&&
Symbol
.
iterator
in
Object
(
e
))
return
Array
.
from
(
e
)}(
e
)
||
function
(
e
,
t
){
if
(
!
e
)
return
;
if
(
"string"
==
typeof
e
)
return
a
(
e
,
t
);
var
n
=
Object
.
prototype
.
toString
.
call
(
e
).
slice
(
8
,
-
1
);
"Object"
===
n
&&
e
.
constructor
&&
(
n
=
e
.
constructor
.
name
);
if
(
"Map"
===
n
||
"Set"
===
n
)
return
Array
.
from
(
e
);
if
(
"Arguments"
===
n
||
/^
(?:
Ui|I
)
nt
(?:
8|16|32
)(?:
Clamped
)?
Array$/
.
test
(
n
))
return
a
(
e
,
t
)}(
e
)
||
function
(){
throw
new
TypeError
(
"Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
)}()}
function
a
(
e
,
t
){(
null
==
t
||
t
>
e
.
length
)
&&
(
t
=
e
.
length
);
for
(
var
n
=
0
,
o
=
new
Array
(
t
);
n
<
t
;
n
++
)
o
[
n
]
=
e
[
n
];
return
o
}
function
s
(
e
){
return
e
.
nodeType
?
e
:
document
.
querySelector
(
e
)}
function
c
(){
for
(
var
e
=
[],
t
=
0
;
t
<
arguments
.
length
;
t
++
)
e
.
push
(
""
.
concat
(
t
+
1
,
". "
).
concat
(
arguments
[
t
]));
console
.
warn
(
e
.
join
(
"\n"
))}
function
u
(
e
){
return
"[object Array]"
==
Object
.
prototype
.
toString
.
call
(
e
)}
function
p
(
e
){
return
"[object Function]"
==
Object
.
prototype
.
toString
.
call
(
e
)}
function
f
(
e
,
t
){
var
n
;
for
(
n
in
t
)
e
[
n
]
=
e
[
n
]
&&
"[object Object]"
===
e
[
n
].
toString
()
&&
t
[
n
]
&&
"[object Object]"
===
t
[
n
].
toString
()?
f
(
e
[
n
],
t
[
n
]):
e
[
n
]
=
t
[
n
];
return
e
}
function
d
(
e
,
t
,
n
){
for
(
var
o
=
n
.
value
,
r
=
l
(
t
),
i
=
function
(
n
){
var
i
=
e
[
n
];
t
.
find
((
function
(
e
){
return
e
[
o
]
==
i
[
o
]}))
||
r
.
push
(
i
)},
a
=
0
;
a
<
e
.
length
;
a
++
)
i
(
a
);
return
r
}
function
h
(
e
,
t
,
n
,
o
){
if
(
e
&&
u
(
e
)){
var
r
=
o
.
children
,
i
=
o
.
selected
,
l
=
o
.
value
;
e
.
forEach
((
function
(
e
){
e
.
__node
[
i
]
||
t
.
find
((
function
(
t
){
return
t
[
l
]
===
e
[
l
]}))?
n
.
push
(
e
):
h
(
e
[
r
],
t
,
n
,
o
)}))}}
function
m
(
e
,
t
,
n
){
if
(
e
&&
u
(
e
))
return
e
.
map
((
function
(
e
){
return
e
=
function
(
e
){
for
(
var
t
=
1
;
t
<
arguments
.
length
;
t
++
){
var
n
=
null
!=
arguments
[
t
]?
arguments
[
t
]:{};
t
%
2
?
r
(
Object
(
n
),
!
0
).
forEach
((
function
(
t
){
i
(
e
,
t
,
n
[
t
])})):
Object
.
getOwnPropertyDescriptors
?
Object
.
defineProperties
(
e
,
Object
.
getOwnPropertyDescriptors
(
n
)):
r
(
Object
(
n
)).
forEach
((
function
(
t
){
Object
.
defineProperty
(
e
,
t
,
Object
.
getOwnPropertyDescriptor
(
n
,
t
))}))}
return
e
}({},
e
),
n
.
forEach
((
function
(
t
){
return
delete
e
[
t
]})),
e
[
t
]
=
m
(
e
[
t
],
t
,
n
),
e
}))}
var
b
,
y
,
x
,
v
,
g
,
_
=
{},
w
=
[],
k
=
/acit|ex
(?:
s|g|n|p|$
)
|rph|grid|ows|mnc|ntw|ine
[
ch
]
|zoo|^ord|itera/i
;
function
C
(
e
,
t
){
for
(
var
n
in
t
)
e
[
n
]
=
t
[
n
];
return
e
}
function
S
(
e
){
var
t
=
e
.
parentNode
;
t
&&
t
.
removeChild
(
e
)}
function
O
(
e
,
t
,
n
){
var
o
,
r
=
arguments
,
i
=
{};
for
(
o
in
t
)
"key"
!==
o
&&
"ref"
!==
o
&&
(
i
[
o
]
=
t
[
o
]);
if
(
arguments
.
length
>
3
)
for
(
n
=
[
n
],
o
=
3
;
o
<
arguments
.
length
;
o
++
)
n
.
push
(
r
[
o
]);
if
(
null
!=
n
&&
(
i
.
children
=
n
),
"function"
==
typeof
e
&&
null
!=
e
.
defaultProps
)
for
(
o
in
e
.
defaultProps
)
void
0
===
i
[
o
]
&&
(
i
[
o
]
=
e
.
defaultProps
[
o
]);
return
j
(
e
,
i
,
t
&&
t
.
key
,
t
&&
t
.
ref
,
null
)}
function
j
(
e
,
t
,
n
,
o
,
r
){
var
i
=
{
type
:
e
,
props
:
t
,
key
:
n
,
ref
:
o
,
__k
:
null
,
__
:
null
,
__b
:
0
,
__e
:
null
,
__d
:
void
0
,
__c
:
null
,
constructor
:
void
0
,
__v
:
r
};
return
null
==
r
&&
(
i
.
__v
=
i
),
b
.
vnode
&&
b
.
vnode
(
i
),
i
}
function
A
(
e
){
return
e
.
children
}
function
E
(
e
,
t
){
this
.
props
=
e
,
this
.
context
=
t
}
function
R
(
e
,
t
){
if
(
null
==
t
)
return
e
.
__
?
R
(
e
.
__
,
e
.
__
.
__k
.
indexOf
(
e
)
+
1
):
null
;
for
(
var
n
;
t
<
e
.
__k
.
length
;
t
++
)
if
(
null
!=
(
n
=
e
.
__k
[
t
])
&&
null
!=
n
.
__e
)
return
n
.
__e
;
return
"function"
==
typeof
e
.
type
?
R
(
e
):
null
}
function
P
(
e
){
var
t
,
n
;
if
(
null
!=
(
e
=
e
.
__
)
&&
null
!=
e
.
__c
){
for
(
e
.
__e
=
e
.
__c
.
base
=
null
,
t
=
0
;
t
<
e
.
__k
.
length
;
t
++
)
if
(
null
!=
(
n
=
e
.
__k
[
t
])
&&
null
!=
n
.
__e
){
e
.
__e
=
e
.
__c
.
base
=
n
.
__e
;
break
}
return
P
(
e
)}}
function
I
(
e
){(
!
e
.
__d
&&
(
e
.
__d
=!
0
)
&&
y
.
push
(
e
)
&&!
D
.
__r
++||
v
!==
b
.
debounceRendering
)
&&
((
v
=
b
.
debounceRendering
)
||
x
)(
D
)}
function
D
(){
for
(
var
e
;
D
.
__r
=
y
.
length
;)
e
=
y
.
sort
((
function
(
e
,
t
){
return
e
.
__v
.
__b
-
t
.
__v
.
__b
})),
y
=
[],
e
.
some
((
function
(
e
){
var
t
,
n
,
o
,
r
,
i
,
l
,
a
;
e
.
__d
&&
(
l
=
(
i
=
(
t
=
e
).
__v
).
__e
,(
a
=
t
.
__P
)
&&
(
n
=
[],(
o
=
C
({},
i
)).
__v
=
o
,
r
=
F
(
a
,
i
,
o
,
t
.
__n
,
void
0
!==
a
.
ownerSVGElement
,
null
,
n
,
null
==
l
?
R
(
i
):
l
),
B
(
n
,
i
),
r
!=
l
&&
P
(
i
)))}))}
function
M
(
e
,
t
,
n
,
o
,
r
,
i
,
l
,
a
,
s
,
c
){
var
u
,
p
,
f
,
d
,
h
,
m
,
b
,
y
=
o
&&
o
.
__k
||
w
,
x
=
y
.
length
;
for
(
s
==
_
&&
(
s
=
null
!=
l
?
l
[
0
]:
x
?
R
(
o
,
0
):
null
),
n
.
__k
=
[],
u
=
0
;
u
<
t
.
length
;
u
++
)
if
(
null
!=
(
d
=
n
.
__k
[
u
]
=
null
==
(
d
=
t
[
u
])
||
"boolean"
==
typeof
d
?
null
:
"string"
==
typeof
d
||
"number"
==
typeof
d
?
j
(
null
,
d
,
null
,
null
,
d
):
Array
.
isArray
(
d
)?
j
(
A
,{
children
:
d
},
null
,
null
,
null
):
null
!=
d
.
__e
||
null
!=
d
.
__c
?
j
(
d
.
type
,
d
.
props
,
d
.
key
,
null
,
d
.
__v
):
d
)){
if
(
d
.
__
=
n
,
d
.
__b
=
n
.
__b
+
1
,
null
===
(
f
=
y
[
u
])
||
f
&&
d
.
key
==
f
.
key
&&
d
.
type
===
f
.
type
)
y
[
u
]
=
void
0
;
else
for
(
p
=
0
;
p
<
x
;
p
++
){
if
((
f
=
y
[
p
])
&&
d
.
key
==
f
.
key
&&
d
.
type
===
f
.
type
){
y
[
p
]
=
void
0
;
break
}
f
=
null
}
h
=
F
(
e
,
d
,
f
=
f
||
_
,
r
,
i
,
l
,
a
,
s
,
c
),(
p
=
d
.
ref
)
&&
f
.
ref
!=
p
&&
(
b
||
(
b
=
[]),
f
.
ref
&&
b
.
push
(
f
.
ref
,
null
,
d
),
b
.
push
(
p
,
d
.
__c
||
h
,
d
)),
null
!=
h
?(
null
==
m
&&
(
m
=
h
),
s
=
T
(
e
,
d
,
f
,
y
,
l
,
h
,
s
),
"option"
==
n
.
type
?
e
.
value
=
""
:
"function"
==
typeof
n
.
type
&&
(
n
.
__d
=
s
)):
s
&&
f
.
__e
==
s
&&
s
.
parentNode
!=
e
&&
(
s
=
R
(
f
))}
if
(
n
.
__e
=
m
,
null
!=
l
&&
"function"
!=
typeof
n
.
type
)
for
(
u
=
l
.
length
;
u
--
;)
null
!=
l
[
u
]
&&
S
(
l
[
u
]);
for
(
u
=
x
;
u
--
;)
null
!=
y
[
u
]
&&
K
(
y
[
u
],
y
[
u
]);
if
(
b
)
for
(
u
=
0
;
u
<
b
.
length
;
u
++
)
H
(
b
[
u
],
b
[
++
u
],
b
[
++
u
])}
function
T
(
e
,
t
,
n
,
o
,
r
,
i
,
l
){
var
a
,
s
,
c
;
if
(
void
0
!==
t
.
__d
)
a
=
t
.
__d
,
t
.
__d
=
void
0
;
else
if
(
r
==
n
||
i
!=
l
||
null
==
i
.
parentNode
)
e
:
if
(
null
==
l
||
l
.
parentNode
!==
e
)
e
.
appendChild
(
i
),
a
=
null
;
else
{
for
(
s
=
l
,
c
=
0
;(
s
=
s
.
nextSibling
)
&&
c
<
o
.
length
;
c
+=
2
)
if
(
s
==
i
)
break
e
;
e
.
insertBefore
(
i
,
l
),
a
=
l
}
return
void
0
!==
a
?
a
:
i
.
nextSibling
}
function
z
(
e
,
t
,
n
){
"-"
===
t
[
0
]?
e
.
setProperty
(
t
,
n
):
e
[
t
]
=
"number"
==
typeof
n
&&!
1
===
k
.
test
(
t
)?
n
+
"px"
:
null
==
n
?
""
:
n
}
function
L
(
e
,
t
,
n
,
o
,
r
){
var
i
,
l
,
a
,
s
,
c
;
if
(
r
?
"className"
===
t
&&
(
t
=
"class"
):
"class"
===
t
&&
(
t
=
"className"
),
"style"
===
t
)
if
(
i
=
e
.
style
,
"string"
==
typeof
n
)
i
.
cssText
=
n
;
else
{
if
(
"string"
==
typeof
o
&&
(
i
.
cssText
=
""
,
o
=
null
),
o
)
for
(
s
in
o
)
n
&&
s
in
n
||
z
(
i
,
s
,
""
);
if
(
n
)
for
(
c
in
n
)
o
&&
n
[
c
]
===
o
[
c
]
||
z
(
i
,
c
,
n
[
c
])}
else
"o"
===
t
[
0
]
&&
"n"
===
t
[
1
]?(
l
=
t
!==
(
t
=
t
.
replace
(
/Capture$/
,
""
)),
a
=
t
.
toLowerCase
(),
t
=
(
a
in
e
?
a
:
t
).
slice
(
2
),
n
?(
o
||
e
.
addEventListener
(
t
,
V
,
l
),(
e
.
l
||
(
e
.
l
=
{}))[
t
]
=
n
):
e
.
removeEventListener
(
t
,
V
,
l
)):
"list"
!==
t
&&
"tagName"
!==
t
&&
"form"
!==
t
&&
"type"
!==
t
&&
"size"
!==
t
&&!
r
&&
t
in
e
?
e
[
t
]
=
null
==
n
?
""
:
n
:
"function"
!=
typeof
n
&&
"dangerouslySetInnerHTML"
!==
t
&&
(
t
!==
(
t
=
t
.
replace
(
/^xlink:
?
/
,
""
))?
null
==
n
||!
1
===
n
?
e
.
removeAttributeNS
(
"http://www.w3.org/1999/xlink"
,
t
.
toLowerCase
()):
e
.
setAttributeNS
(
"http://www.w3.org/1999/xlink"
,
t
.
toLowerCase
(),
n
):
null
==
n
||!
1
===
n
&&!
/^ar/
.
test
(
t
)?
e
.
removeAttribute
(
t
):
e
.
setAttribute
(
t
,
n
))}
function
V
(
e
){
this
.
l
[
e
.
type
](
b
.
event
?
b
.
event
(
e
):
e
)}
function
U
(
e
,
t
,
n
){
var
o
,
r
;
for
(
o
=
0
;
o
<
e
.
__k
.
length
;
o
++
)(
r
=
e
.
__k
[
o
])
&&
(
r
.
__
=
e
,
r
.
__e
&&
(
"function"
==
typeof
r
.
type
&&
r
.
__k
.
length
>
1
&&
U
(
r
,
t
,
n
),
t
=
T
(
n
,
r
,
r
,
e
.
__k
,
null
,
r
.
__e
,
t
),
"function"
==
typeof
e
.
type
&&
(
e
.
__d
=
t
)))}
function
F
(
e
,
t
,
n
,
o
,
r
,
i
,
l
,
a
,
s
){
var
c
,
u
,
p
,
f
,
d
,
h
,
m
,
y
,
x
,
v
,
g
,
_
=
t
.
type
;
if
(
void
0
!==
t
.
constructor
)
return
null
;(
c
=
b
.
__b
)
&&
c
(
t
);
try
{
e
:
if
(
"function"
==
typeof
_
){
if
(
y
=
t
.
props
,
x
=
(
c
=
_
.
contextType
)
&&
o
[
c
.
__c
],
v
=
c
?
x
?
x
.
props
.
value
:
c
.
__
:
o
,
n
.
__c
?
m
=
(
u
=
t
.
__c
=
n
.
__c
).
__
=
u
.
__E
:(
"prototype"
in
_
&&
_
.
prototype
.
render
?
t
.
__c
=
u
=
new
_
(
y
,
v
):(
t
.
__c
=
u
=
new
E
(
y
,
v
),
u
.
constructor
=
_
,
u
.
render
=
q
),
x
&&
x
.
sub
(
u
),
u
.
props
=
y
,
u
.
state
||
(
u
.
state
=
{}),
u
.
context
=
v
,
u
.
__n
=
o
,
p
=
u
.
__d
=!
0
,
u
.
__h
=
[]),
null
==
u
.
__s
&&
(
u
.
__s
=
u
.
state
),
null
!=
_
.
getDerivedStateFromProps
&&
(
u
.
__s
==
u
.
state
&&
(
u
.
__s
=
C
({},
u
.
__s
)),
C
(
u
.
__s
,
_
.
getDerivedStateFromProps
(
y
,
u
.
__s
))),
f
=
u
.
props
,
d
=
u
.
state
,
p
)
null
==
_
.
getDerivedStateFromProps
&&
null
!=
u
.
componentWillMount
&&
u
.
componentWillMount
(),
null
!=
u
.
componentDidMount
&&
u
.
__h
.
push
(
u
.
componentDidMount
);
else
{
if
(
null
==
_
.
getDerivedStateFromProps
&&
y
!==
f
&&
null
!=
u
.
componentWillReceiveProps
&&
u
.
componentWillReceiveProps
(
y
,
v
),
!
u
.
__e
&&
null
!=
u
.
shouldComponentUpdate
&&!
1
===
u
.
shouldComponentUpdate
(
y
,
u
.
__s
,
v
)
||
t
.
__v
===
n
.
__v
){
u
.
props
=
y
,
u
.
state
=
u
.
__s
,
t
.
__v
!==
n
.
__v
&&
(
u
.
__d
=!
1
),
u
.
__v
=
t
,
t
.
__e
=
n
.
__e
,
t
.
__k
=
n
.
__k
,
u
.
__h
.
length
&&
l
.
push
(
u
),
U
(
t
,
a
,
e
);
break
e
}
null
!=
u
.
componentWillUpdate
&&
u
.
componentWillUpdate
(
y
,
u
.
__s
,
v
),
null
!=
u
.
componentDidUpdate
&&
u
.
__h
.
push
((
function
(){
u
.
componentDidUpdate
(
f
,
d
,
h
)}))}
u
.
context
=
v
,
u
.
props
=
y
,
u
.
state
=
u
.
__s
,(
c
=
b
.
__r
)
&&
c
(
t
),
u
.
__d
=!
1
,
u
.
__v
=
t
,
u
.
__P
=
e
,
c
=
u
.
render
(
u
.
props
,
u
.
state
,
u
.
context
),
u
.
state
=
u
.
__s
,
null
!=
u
.
getChildContext
&&
(
o
=
C
(
C
({},
o
),
u
.
getChildContext
())),
p
||
null
==
u
.
getSnapshotBeforeUpdate
||
(
h
=
u
.
getSnapshotBeforeUpdate
(
f
,
d
)),
g
=
null
!=
c
&&
c
.
type
==
A
&&
null
==
c
.
key
?
c
.
props
.
children
:
c
,
M
(
e
,
Array
.
isArray
(
g
)?
g
:[
g
],
t
,
n
,
o
,
r
,
i
,
l
,
a
,
s
),
u
.
base
=
t
.
__e
,
u
.
__h
.
length
&&
l
.
push
(
u
),
m
&&
(
u
.
__E
=
u
.
__
=
null
),
u
.
__e
=!
1
}
else
null
==
i
&&
t
.
__v
===
n
.
__v
?(
t
.
__k
=
n
.
__k
,
t
.
__e
=
n
.
__e
):
t
.
__e
=
N
(
n
.
__e
,
t
,
n
,
o
,
r
,
i
,
l
,
s
);(
c
=
b
.
diffed
)
&&
c
(
t
)}
catch
(
e
){
t
.
__v
=
null
,
b
.
__e
(
e
,
t
,
n
)}
return
t
.
__e
}
function
B
(
e
,
t
){
b
.
__c
&&
b
.
__c
(
t
,
e
),
e
.
some
((
function
(
t
){
try
{
e
=
t
.
__h
,
t
.
__h
=
[],
e
.
some
((
function
(
e
){
e
.
call
(
t
)}))}
catch
(
e
){
b
.
__e
(
e
,
t
.
__v
)}}))}
function
N
(
e
,
t
,
n
,
o
,
r
,
i
,
l
,
a
){
var
s
,
c
,
u
,
p
,
f
,
d
=
n
.
props
,
h
=
t
.
props
;
if
(
r
=
"svg"
===
t
.
type
||
r
,
null
!=
i
)
for
(
s
=
0
;
s
<
i
.
length
;
s
++
)
if
(
null
!=
(
c
=
i
[
s
])
&&
((
null
===
t
.
type
?
3
===
c
.
nodeType
:
c
.
localName
===
t
.
type
)
||
e
==
c
)){
e
=
c
,
i
[
s
]
=
null
;
break
}
if
(
null
==
e
){
if
(
null
===
t
.
type
)
return
document
.
createTextNode
(
h
);
e
=
r
?
document
.
createElementNS
(
"http://www.w3.org/2000/svg"
,
t
.
type
):
document
.
createElement
(
t
.
type
,
h
.
is
&&
{
is
:
h
.
is
}),
i
=
null
,
a
=!
1
}
if
(
null
===
t
.
type
)
d
!==
h
&&
e
.
data
!=
h
&&
(
e
.
data
=
h
);
else
{
if
(
null
!=
i
&&
(
i
=
w
.
slice
.
call
(
e
.
childNodes
)),
u
=
(
d
=
n
.
props
||
_
).
dangerouslySetInnerHTML
,
p
=
h
.
dangerouslySetInnerHTML
,
!
a
){
if
(
null
!=
i
)
for
(
d
=
{},
f
=
0
;
f
<
e
.
attributes
.
length
;
f
++
)
d
[
e
.
attributes
[
f
].
name
]
=
e
.
attributes
[
f
].
value
;(
p
||
u
)
&&
(
p
&&
u
&&
p
.
__html
==
u
.
__html
||
(
e
.
innerHTML
=
p
&&
p
.
__html
||
""
))}(
function
(
e
,
t
,
n
,
o
,
r
){
var
i
;
for
(
i
in
n
)
"children"
===
i
||
"key"
===
i
||
i
in
t
||
L
(
e
,
i
,
null
,
n
[
i
],
o
);
for
(
i
in
t
)
r
&&
"function"
!=
typeof
t
[
i
]
||
"children"
===
i
||
"key"
===
i
||
"value"
===
i
||
"checked"
===
i
||
n
[
i
]
===
t
[
i
]
||
L
(
e
,
i
,
t
[
i
],
n
[
i
],
o
)})(
e
,
h
,
d
,
r
,
a
),
p
?
t
.
__k
=
[]:(
s
=
t
.
props
.
children
,
M
(
e
,
Array
.
isArray
(
s
)?
s
:[
s
],
t
,
n
,
o
,
"foreignObject"
!==
t
.
type
&&
r
,
i
,
l
,
_
,
a
)),
a
||
(
"value"
in
h
&&
void
0
!==
(
s
=
h
.
value
)
&&
s
!==
e
.
value
&&
L
(
e
,
"value"
,
s
,
d
.
value
,
!
1
),
"checked"
in
h
&&
void
0
!==
(
s
=
h
.
checked
)
&&
s
!==
e
.
checked
&&
L
(
e
,
"checked"
,
s
,
d
.
checked
,
!
1
))}
return
e
}
function
H
(
e
,
t
,
n
){
try
{
"function"
==
typeof
e
?
e
(
t
):
e
.
current
=
t
}
catch
(
e
){
b
.
__e
(
e
,
n
)}}
function
K
(
e
,
t
,
n
){
var
o
,
r
,
i
;
if
(
b
.
unmount
&&
b
.
unmount
(
e
),(
o
=
e
.
ref
)
&&
(
o
.
current
&&
o
.
current
!==
e
.
__e
||
H
(
o
,
null
,
t
)),
n
||
"function"
==
typeof
e
.
type
||
(
n
=
null
!=
(
r
=
e
.
__e
)),
e
.
__e
=
e
.
__d
=
void
0
,
null
!=
(
o
=
e
.
__c
)){
if
(
o
.
componentWillUnmount
)
try
{
o
.
componentWillUnmount
()}
catch
(
e
){
b
.
__e
(
e
,
t
)}
o
.
base
=
o
.
__P
=
null
}
if
(
o
=
e
.
__k
)
for
(
i
=
0
;
i
<
o
.
length
;
i
++
)
o
[
i
]
&&
K
(
o
[
i
],
t
,
n
);
null
!=
r
&&
S
(
r
)}
function
q
(
e
,
t
,
n
){
return
this
.
constructor
(
e
,
n
)}
function
Y
(
e
,
t
,
n
){
var
o
,
r
,
i
;
b
.
__
&&
b
.
__
(
e
,
t
),
r
=
(
o
=
n
===
g
)?
null
:
n
&&
n
.
__k
||
t
.
__k
,
e
=
O
(
A
,
null
,[
e
]),
i
=
[],
F
(
t
,(
o
?
t
:
n
||
t
).
__k
=
e
,
r
||
_
,
_
,
void
0
!==
t
.
ownerSVGElement
,
n
&&!
o
?[
n
]:
r
?
null
:
t
.
childNodes
.
length
?
w
.
slice
.
call
(
t
.
childNodes
):
null
,
i
,
n
||
_
,
o
),
B
(
i
,
e
)}
function
Z
(
e
){
return
(
Z
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
Q
(
e
){
return
function
(
e
){
if
(
Array
.
isArray
(
e
))
return
J
(
e
)}(
e
)
||
function
(
e
){
if
(
"undefined"
!=
typeof
Symbol
&&
Symbol
.
iterator
in
Object
(
e
))
return
Array
.
from
(
e
)}(
e
)
||
function
(
e
,
t
){
if
(
!
e
)
return
;
if
(
"string"
==
typeof
e
)
return
J
(
e
,
t
);
var
n
=
Object
.
prototype
.
toString
.
call
(
e
).
slice
(
8
,
-
1
);
"Object"
===
n
&&
e
.
constructor
&&
(
n
=
e
.
constructor
.
name
);
if
(
"Map"
===
n
||
"Set"
===
n
)
return
Array
.
from
(
e
);
if
(
"Arguments"
===
n
||
/^
(?:
Ui|I
)
nt
(?:
8|16|32
)(?:
Clamped
)?
Array$/
.
test
(
n
))
return
J
(
e
,
t
)}(
e
)
||
function
(){
throw
new
TypeError
(
"Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
)}()}
function
J
(
e
,
t
){(
null
==
t
||
t
>
e
.
length
)
&&
(
t
=
e
.
length
);
for
(
var
n
=
0
,
o
=
new
Array
(
t
);
n
<
t
;
n
++
)
o
[
n
]
=
e
[
n
];
return
o
}
function
W
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
G
(
e
,
t
){
return
(
G
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
X
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
ee
(
e
);
if
(
t
){
var
r
=
ee
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
$
(
this
,
n
)}}
function
$
(
e
,
t
){
return
!
t
||
"object"
!==
Z
(
t
)
&&
"function"
!=
typeof
t
?
function
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}(
e
):
t
}
function
ee
(
e
){
return
(
ee
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
b
=
{
__e
:
function
(
e
,
t
){
for
(
var
n
,
o
;
t
=
t
.
__
;)
if
((
n
=
t
.
__c
)
&&!
n
.
__
)
try
{
if
(
n
.
constructor
&&
null
!=
n
.
constructor
.
getDerivedStateFromError
&&
(
o
=!
0
,
n
.
setState
(
n
.
constructor
.
getDerivedStateFromError
(
e
))),
null
!=
n
.
componentDidCatch
&&
(
o
=!
0
,
n
.
componentDidCatch
(
e
)),
o
)
return
I
(
n
.
__E
=
n
)}
catch
(
t
){
e
=
t
}
throw
e
}},
E
.
prototype
.
setState
=
function
(
e
,
t
){
var
n
;
n
=
this
.
__s
!==
this
.
state
?
this
.
__s
:
this
.
__s
=
C
({},
this
.
state
),
"function"
==
typeof
e
&&
(
e
=
e
(
n
,
this
.
props
)),
e
&&
C
(
n
,
e
),
null
!=
e
&&
this
.
__v
&&
(
t
&&
this
.
__h
.
push
(
t
),
I
(
this
))},
E
.
prototype
.
forceUpdate
=
function
(
e
){
this
.
__v
&&
(
this
.
__e
=!
0
,
e
&&
this
.
__h
.
push
(
e
),
I
(
this
))},
E
.
prototype
.
render
=
A
,
y
=
[],
x
=
"function"
==
typeof
Promise
?
Promise
.
prototype
.
then
.
bind
(
Promise
.
resolve
()):
setTimeout
,
D
.
__r
=
0
,
g
=
_
;
var
te
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
G
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
X
(
i
);
function
i
(
e
){
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),
r
.
call
(
this
,
e
)}
return
t
=
i
,(
n
=
[{
key
:
"iconClick"
,
value
:
function
(
e
,
t
,
n
,
o
){
this
.
props
.
ck
(
e
,
t
,
n
,
!
0
),
o
.
stopPropagation
()}},{
key
:
"scrollFunc"
,
value
:
function
(
e
){
if
(
0
==
e
.
wheelDeltaX
){
for
(
var
t
=
this
.
labelRef
.
getElementsByClassName
(
"xm-label-block"
),
n
=
10
,
o
=
0
;
o
<
t
.
length
;
o
++
)
n
+=
t
[
o
].
getBoundingClientRect
().
width
+
5
;
var
r
=
this
.
labelRef
.
getBoundingClientRect
().
width
,
i
=
n
>
r
?
n
-
r
:
r
,
l
=
this
.
labelRef
.
scrollLeft
+
e
.
deltaY
;
l
<
0
&&
(
l
=
0
),
l
>
i
&&
(
l
=
i
),
this
.
labelRef
.
scrollLeft
=
l
}}},{
key
:
"componentDidMount"
,
value
:
function
(){
this
.
labelRef
.
addEventListener
&&
this
.
labelRef
.
addEventListener
(
"DOMMouseScroll"
,
this
.
scrollFunc
.
bind
(
this
),
!
1
),
this
.
labelRef
.
attachEvent
&&
this
.
labelRef
.
attachEvent
(
"onmousewheel"
,
this
.
scrollFunc
.
bind
(
this
)),
this
.
labelRef
.
onmousewheel
=
this
.
scrollFunc
.
bind
(
this
)}},{
key
:
"render"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
e
.
data
,
o
=
e
.
prop
,
r
=
e
.
theme
,
i
=
e
.
model
,
l
=
e
.
sels
,
a
=
e
.
autoRow
,
s
=
e
.
tree
,
c
=
o
.
name
,
u
=
o
.
disabled
,
f
=
i
.
label
,
d
=
f
.
type
,
m
=
f
[
d
],
b
=
l
;
s
.
show
&&
s
.
strict
&&
s
.
simple
&&
h
(
n
,
l
,
b
=
[],
o
);
var
y
=
""
,
x
=!
0
,
v
=
b
.
map
((
function
(
e
){
return
e
[
c
]})).
join
(
","
);
if
(
"text"
===
d
)
y
=
b
.
map
((
function
(
e
){
return
""
.
concat
(
m
.
left
).
concat
(
e
[
c
]).
concat
(
m
.
right
)})).
join
(
m
.
separator
);
else
if
(
"block"
===
d
){
x
=!
1
;
var
g
=
Q
(
b
),
_
=
{
backgroundColor
:
r
.
color
},
w
=
m
.
showCount
<=
0
?
g
.
length
:
m
.
showCount
;
y
=
g
.
splice
(
0
,
w
).
map
((
function
(
e
){
var
n
=
{
width
:
m
.
showIcon
?
"calc(100% - 20px)"
:
"100%"
};
return
O
(
"div"
,{
class
:[
"xm-label-block"
,
e
[
u
]?
"disabled"
:
""
].
join
(
" "
),
style
:
_
},
m
.
template
&&
p
(
m
.
template
)?
O
(
"span"
,{
style
:
n
,
dangerouslySetInnerHTML
:{
__html
:
m
.
template
(
e
,
g
)}}):
O
(
"span"
,{
style
:
n
},
e
[
c
]),
m
.
showIcon
&&
O
(
"i"
,{
class
:
"xm-iconfont xm-icon-close"
,
onClick
:
t
.
iconClick
.
bind
(
t
,
e
,
!
0
,
e
[
u
])}))})),
g
.
length
&&
y
.
push
(
O
(
"div"
,{
class
:
"xm-label-block"
,
style
:
_
},
"+ "
,
g
.
length
))}
else
y
=
b
.
length
&&
m
&&
m
.
template
?
m
.
template
(
n
,
b
):
b
.
map
((
function
(
e
){
return
e
[
c
]})).
join
(
","
);
return
O
(
"div"
,{
class
:[
"xm-label"
,
a
?
"auto-row"
:
"single-row"
].
join
(
" "
)},
O
(
"div"
,{
class
:
"scroll"
,
ref
:
function
(
e
){
return
t
.
labelRef
=
e
}},
x
?
O
(
"div"
,{
class
:
"label-content"
,
dangerouslySetInnerHTML
:{
__html
:
y
}}):
O
(
"div"
,{
class
:
"label-content"
,
title
:
v
},
y
)))}}])
&&
W
(
t
.
prototype
,
n
),
o
&&
W
(
t
,
o
),
i
}(
E
);
function
ne
(
e
){
return
(
ne
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
oe
(
e
,
t
){
var
n
=
Object
.
keys
(
e
);
if
(
Object
.
getOwnPropertySymbols
){
var
o
=
Object
.
getOwnPropertySymbols
(
e
);
t
&&
(
o
=
o
.
filter
((
function
(
t
){
return
Object
.
getOwnPropertyDescriptor
(
e
,
t
).
enumerable
}))),
n
.
push
.
apply
(
n
,
o
)}
return
n
}
function
re
(
e
){
for
(
var
t
=
1
;
t
<
arguments
.
length
;
t
++
){
var
n
=
null
!=
arguments
[
t
]?
arguments
[
t
]:{};
t
%
2
?
oe
(
Object
(
n
),
!
0
).
forEach
((
function
(
t
){
ie
(
e
,
t
,
n
[
t
])})):
Object
.
getOwnPropertyDescriptors
?
Object
.
defineProperties
(
e
,
Object
.
getOwnPropertyDescriptors
(
n
)):
oe
(
Object
(
n
)).
forEach
((
function
(
t
){
Object
.
defineProperty
(
e
,
t
,
Object
.
getOwnPropertyDescriptor
(
n
,
t
))}))}
return
e
}
function
ie
(
e
,
t
,
n
){
return
t
in
e
?
Object
.
defineProperty
(
e
,
t
,{
value
:
n
,
enumerable
:
!
0
,
configurable
:
!
0
,
writable
:
!
0
}):
e
[
t
]
=
n
,
e
}
function
le
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
ae
(
e
,
t
){
return
(
ae
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
se
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
ue
(
e
);
if
(
t
){
var
r
=
ue
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
ce
(
this
,
n
)}}
function
ce
(
e
,
t
){
return
!
t
||
"object"
!==
ne
(
t
)
&&
"function"
!=
typeof
t
?
function
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}(
e
):
t
}
function
ue
(
e
){
return
(
ue
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
var
pe
=
{},
fe
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
ae
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
se
(
i
);
function
i
(
e
){
var
t
;
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),(
t
=
r
.
call
(
this
,
e
)).
setState
({
filterValue
:
""
,
remote
:
!
0
,
loading
:
!
1
,
pageIndex
:
1
,
totalSize
:
0
,
val
:
pe
}),
t
.
searchCid
=
0
,
t
.
inputOver
=!
0
,
t
.
__value
=
""
,
t
.
tempData
=
[],
t
.
size
=
0
,
t
}
return
t
=
i
,(
n
=
[{
key
:
"optionClick"
,
value
:
function
(
e
,
t
,
n
,
o
){
this
.
props
.
ck
(
e
,
t
,
n
),
this
.
focus
(),
this
.
blockClick
(
o
)}},{
key
:
"groupClick"
,
value
:
function
(
e
,
t
){
var
n
=
this
.
props
.
prop
,
o
=
n
.
click
,
r
=
n
.
children
,
i
=
n
.
disabled
,
l
=
e
[
o
],
a
=
e
[
r
].
filter
((
function
(
e
){
return
!
e
[
i
]}));
"SELECT"
===
l
?
this
.
props
.
onReset
(
a
,
"append"
):
"CLEAR"
===
l
?
this
.
props
.
onReset
(
a
,
"delete"
):
"AUTO"
===
l
?
this
.
props
.
onReset
(
a
,
"auto"
):
p
(
l
)
&&
l
(
e
),
this
.
focus
(),
this
.
blockClick
(
t
)}},{
key
:
"blockClick"
,
value
:
function
(
e
){
e
.
stopPropagation
()}},{
key
:
"pagePrevClick"
,
value
:
function
(){
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]
||
this
.
size
;
var
e
=
this
.
state
.
pageIndex
;
e
<=
1
||
(
this
.
changePageIndex
(
e
-
1
),
this
.
props
.
pageRemote
&&
this
.
postData
(
e
-
1
,
!
0
))}},{
key
:
"pageNextClick"
,
value
:
function
(){
var
e
=
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]?
arguments
[
0
]:
this
.
size
,
t
=
this
.
state
.
pageIndex
;
t
>=
e
||
(
this
.
changePageIndex
(
t
+
1
),
this
.
props
.
pageRemote
&&
this
.
postData
(
t
+
1
,
!
0
))}},{
key
:
"changePageIndex"
,
value
:
function
(
e
){
this
.
setState
({
pageIndex
:
e
})}},{
key
:
"searchInput"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
e
.
target
.
value
;
n
!==
this
.
__value
&&
(
clearTimeout
(
this
.
searchCid
),
this
.
inputOver
&&
(
this
.
__value
=
n
,
this
.
searchCid
=
setTimeout
((
function
(){
t
.
callback
=!
0
,
t
.
setState
({
filterValue
:
t
.
__value
,
remote
:
!
0
,
pageIndex
:
1
})}),
this
.
props
.
delay
)))}},{
key
:
"focus"
,
value
:
function
(){
this
.
searchInputRef
&&
this
.
searchInputRef
.
focus
()}},{
key
:
"blur"
,
value
:
function
(){
this
.
searchInputRef
&&
this
.
searchInputRef
.
blur
()}},{
key
:
"handleComposition"
,
value
:
function
(
e
){
var
t
=
e
.
type
;
"compositionstart"
===
t
?(
this
.
inputOver
=!
1
,
clearTimeout
(
this
.
searchCid
)):
"compositionend"
===
t
&&
(
this
.
inputOver
=!
0
,
this
.
searchInput
(
e
))}},{
key
:
"postData"
,
value
:
function
(){
var
e
=
this
,
t
=
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]?
arguments
[
0
]:
this
.
state
.
pageIndex
,
n
=
arguments
.
length
>
1
&&
void
0
!==
arguments
[
1
]
&&
arguments
[
1
];(
this
.
state
.
remote
||
n
)
&&
(
this
.
callback
=!
1
,
this
.
setState
({
loading
:
!
0
,
remote
:
!
1
}),
this
.
blur
(),
this
.
props
.
remoteMethod
(
this
.
state
.
filterValue
,(
function
(
t
){
var
n
=
arguments
.
length
>
1
&&
void
0
!==
arguments
[
1
]?
arguments
[
1
]:
1
;
setTimeout
((
function
(){
e
.
focus
(),
e
.
callback
=!
0
,
e
.
setState
({
loading
:
!
1
,
totalSize
:
n
}),
e
.
props
.
onReset
(
t
,
"data"
)}),
10
)}),
this
.
props
.
show
,
t
))}},{
key
:
"keydown"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
t
.
keyCode
;
"div"
===
e
&&
(
27
===
o
||
9
===
o
?
this
.
props
.
onReset
(
!
1
,
"close"
):
37
===
o
?
this
.
pagePrevClick
():
39
===
o
&&
this
.
pageNextClick
());
var
r
=
this
.
props
.
prop
,
i
=
r
.
value
,
l
=
r
.
optgroup
,
a
=
r
.
disabled
,
s
=
this
.
tempData
.
filter
((
function
(
e
){
return
!
e
[
l
]
&&!
e
[
a
]})),
c
=
s
.
length
-
1
;
if
(
-
1
!==
c
){
var
u
=
s
.
findIndex
((
function
(
e
){
return
e
[
i
]
===
n
.
state
.
val
}));
if
(
38
===
o
){
u
<=
0
?
u
=
c
:
u
>
0
&&
(
u
-=
1
);
var
p
=
s
[
u
][
i
];
this
.
setState
({
val
:
p
})}
else
if
(
40
===
o
){
-
1
===
u
||
u
===
c
?
u
=
0
:
u
<
c
&&
(
u
+=
1
);
var
f
=
s
[
u
][
i
];
this
.
setState
({
val
:
f
})}
else
if
(
13
===
o
&&
this
.
state
.
val
!=
pe
){
var
d
=
s
[
u
];
this
.
optionClick
(
d
,
-
1
!=
this
.
props
.
sels
.
findIndex
((
function
(
e
){
return
e
[
i
]
===
n
.
state
.
val
})),
d
[
a
],
t
)}}}},{
key
:
"componentWillReceiveProps"
,
value
:
function
(
e
){
var
t
=
this
;
this
.
props
.
show
!=
e
.
show
&&
(
e
.
show
?
setTimeout
((
function
(){
e
.
filterable
?
t
.
focus
():
t
.
base
.
focus
()}),
0
):(
this
.
setState
({
filterValue
:
""
,
val
:
pe
}),
this
.
__value
=
""
,
this
.
searchInputRef
&&
(
this
.
searchInputRef
.
value
=
""
)))}},{
key
:
"render"
,
value
:
function
(
e
){
var
t
,
n
=
this
,
o
=
e
.
data
,
r
=
e
.
flatData
,
i
=
e
.
prop
,
l
=
e
.
template
,
a
=
e
.
theme
,
s
=
e
.
radio
,
c
=
e
.
sels
,
u
=
e
.
empty
,
h
=
e
.
filterable
,
m
=
e
.
filterMethod
,
b
=
e
.
remoteSearch
,
y
=
(
e
.
remoteMethod
,
e
.
delay
,
e
.
searchTips
),
x
=
e
.
create
,
v
=
e
.
pageRemote
,
g
=
e
.
max
,
_
=
i
.
name
,
w
=
i
.
value
,
k
=
i
.
disabled
,
C
=
i
.
children
,
S
=
i
.
optgroup
,
j
=
f
([],
r
);
if
((
v
||
h
&&
b
)
&&
this
.
postData
(),
h
&&!
b
){
j
=
j
.
filter
((
function
(
e
,
t
){
return
e
[
S
]?(
delete
e
.
__del
,
!
0
):
m
(
n
.
state
.
filterValue
,
e
,
t
,
i
)}));
for
(
var
A
=
0
;
A
<
j
.
length
-
1
;
A
++
){
var
E
=
j
[
A
],
R
=
j
[
A
+
1
];
E
[
S
]
&&
R
[
S
]
&&
(
j
[
A
].
__del
=!
0
)}
j
.
length
&&
j
[
j
.
length
-
1
][
S
]
&&
(
j
[
j
.
length
-
1
].
__del
=!
0
),
j
=
j
.
filter
((
function
(
e
){
return
!
e
.
__del
})),
t
=
this
.
state
.
filterValue
&&
p
(
x
)}
var
P
=
O
(
"div"
,{
class
:
h
?
"xm-search"
:
"xm-search dis"
},
O
(
"i"
,{
class
:
"xm-iconfont xm-icon-sousuo"
}),
O
(
"input"
,{
class
:
"xm-input xm-search-input"
,
placeholder
:
y
})),
I
=
{};
j
.
filter
((
function
(
e
){
return
e
[
S
]})).
forEach
((
function
(
e
){
e
[
C
].
forEach
((
function
(
t
){
return
I
[
t
[
w
]]
=
e
}))})),
j
=
j
.
filter
((
function
(
e
){
return
!
e
[
S
]}));
var
D
=
""
;
if
(
e
.
paging
){
var
M
=
v
?
this
.
state
.
totalSize
:
Math
.
floor
((
j
.
length
-
1
)
/
e
.
pageSize
)
+
1
;
M
<=
0
&&
(
M
=
1
);
var
T
=
this
.
state
.
pageIndex
;
if
(
T
>
M
&&
(
T
=
M
),
M
>
0
&&
T
<=
0
&&
(
T
=
1
),
!
v
){
var
z
=
(
T
-
1
)
*
e
.
pageSize
,
L
=
z
+
e
.
pageSize
;
j
=
j
.
slice
(
z
,
L
)}
var
V
=
{
cursor
:
"no-drop"
,
color
:
"#d2d2d2"
},
U
=
{},
F
=
{};
T
<=
1
&&
(
U
=
V
),
T
==
M
&&
(
F
=
V
),
this
.
state
.
pageIndex
!==
T
&&
this
.
changePageIndex
(
T
),
this
.
size
=
M
,
D
=
O
(
"div"
,{
class
:
"xm-paging"
},
O
(
"span"
,{
style
:
U
,
onClick
:
this
.
pagePrevClick
.
bind
(
this
,
M
)},
e
.
languageProp
.
paging
.
prev
),
O
(
"span"
,
null
,
this
.
state
.
pageIndex
,
" / "
,
M
),
O
(
"span"
,{
style
:
F
,
onClick
:
this
.
pageNextClick
.
bind
(
this
,
M
)},
e
.
languageProp
.
paging
.
next
))}
else
e
.
showCount
>
0
&&
(
j
=
j
.
slice
(
0
,
e
.
showCount
));
var
B
,
N
=
[],
H
=
{
__tmp
:
!
0
};
H
[
S
]
=!
0
,
j
.
forEach
((
function
(
e
){
var
t
=
I
[
e
[
w
]];
B
&&!
t
&&
(
t
=
H
),
t
!=
B
&&
(
B
=
t
,
t
&&
N
.
push
(
B
)),
N
.
push
(
e
)})),
j
=
N
,
t
&&
(
t
=
x
(
this
.
state
.
filterValue
,
f
([],
j
)))
&&
j
.
splice
(
0
,
0
,
re
(
re
({},
t
),{},{
__node
:{}}));
var
K
=
f
([],
j
);
this
.
tempData
=
K
;
var
q
=
O
(
"div"
,{
class
:
"xm-toolbar"
},
e
.
toolbar
.
list
.
map
((
function
(
t
){
var
o
,
r
=
e
.
languageProp
.
toolbar
[
t
];
o
=
"ALL"
===
t
?{
icon
:
"xm-iconfont xm-icon-quanxuan"
,
name
:
r
,
method
:
function
(
e
){
var
t
=
i
.
optgroup
,
o
=
i
.
disabled
,
r
=
e
.
filter
((
function
(
e
){
return
!
e
[
t
]})).
filter
((
function
(
e
){
return
!
e
[
o
]})),
l
=
c
.
filter
((
function
(
e
){
return
e
[
i
.
disabled
]})),
a
=
[];
a
=
s
?
l
.
length
?
l
:
r
.
slice
(
0
,
1
):
g
>
0
?
l
.
length
>=
g
?
l
:
d
(
r
.
slice
(
0
,
g
-
l
.
length
),
l
,
i
):
d
(
r
,
c
,
i
),
n
.
props
.
onReset
(
a
,
"sels"
)}}:
"CLEAR"
===
t
?{
icon
:
"xm-iconfont xm-icon-qingkong"
,
name
:
r
,
method
:
function
(
e
){
n
.
props
.
onReset
(
c
.
filter
((
function
(
e
){
return
e
[
i
.
disabled
]})),
"sels"
)}}:
"REVERSE"
===
t
?{
icon
:
"xm-iconfont xm-icon-fanxuan"
,
name
:
r
,
method
:
function
(
e
){
var
t
=
i
.
optgroup
,
o
=
i
.
disabled
,
r
=
e
.
filter
((
function
(
e
){
return
!
e
[
t
]})).
filter
((
function
(
e
){
return
!
e
[
o
]})),
l
=
[];
c
.
forEach
((
function
(
e
){
var
t
=
r
.
findIndex
((
function
(
t
){
return
t
[
w
]
===
e
[
w
]}));
-
1
==
t
?
l
.
push
(
e
):
r
.
splice
(
t
,
1
)}));
var
a
=
l
.
filter
((
function
(
e
){
return
e
[
i
.
disabled
]})),
u
=
[];
u
=
s
?
a
.
length
?
a
:
r
.
slice
(
0
,
1
):
g
>
0
?
a
.
length
>=
g
?
a
:
d
(
r
.
slice
(
0
,
g
-
a
.
length
),
a
,
i
):
d
(
r
,
l
,
i
),
n
.
props
.
onReset
(
u
,
"sels"
)}}:
t
;
var
l
=
function
(
e
){
"mouseenter"
===
e
.
type
&&
(
e
.
target
.
style
.
color
=
a
.
color
),
"mouseleave"
===
e
.
type
&&
(
e
.
target
.
style
.
color
=
""
)};
return
O
(
"div"
,{
class
:
"toolbar-tag"
,
style
:{},
onClick
:
function
(){
p
(
o
.
method
)
&&
o
.
method
(
K
),
n
.
focus
()},
onMouseEnter
:
l
,
onMouseLeave
:
l
},
e
.
toolbar
.
showIcon
&&
O
(
"i"
,{
class
:
o
.
icon
}),
O
(
"span"
,
null
,
o
.
name
))})).
filter
((
function
(
e
){
return
e
}))),
Y
=
"hidden"
!=
e
.
model
.
icon
;
return
(
j
=
j
.
map
((
function
(
e
){
return
e
[
S
]?
e
.
__tmp
?
O
(
"div"
,{
class
:
"item--divided"
}):
O
(
"div"
,{
class
:
"xm-group"
},
O
(
"div"
,{
class
:
"xm-group-item"
,
onClick
:
n
.
groupClick
.
bind
(
n
,
e
)},
e
[
_
])):
function
(
e
){
var
t
=!!
c
.
find
((
function
(
t
){
return
t
[
w
]
==
e
[
w
]})),
r
=
t
?{
color
:
a
.
color
,
border
:
"none"
}:{
borderColor
:
a
.
color
},
i
=
{};
e
[
w
]
===
n
.
state
.
val
&&
(
i
.
backgroundColor
=
a
.
hover
),
!
Y
&&
t
&&
(
i
.
backgroundColor
=
a
.
color
,
e
[
k
]
&&
(
i
.
backgroundColor
=
"#C2C2C2"
));
var
u
=
[
"xm-option"
,
e
[
k
]?
" disabled"
:
""
,
t
?
" selected"
:
""
,
Y
?
"show-icon"
:
"hide-icon"
].
join
(
" "
),
p
=
[
"xm-option-icon xm-iconfont"
,
s
?
"xm-icon-danx"
:
"xm-icon-duox"
].
join
(
" "
),
f
=
function
(
t
){
"mouseenter"
===
t
.
type
&&
(
e
[
k
]
||
n
.
setState
({
val
:
e
[
w
]}))};
return
O
(
"div"
,{
class
:
u
,
style
:
i
,
value
:
e
[
w
],
onClick
:
n
.
optionClick
.
bind
(
n
,
e
,
t
,
e
[
k
]),
onMouseEnter
:
f
,
onMouseLeave
:
f
},
Y
&&
O
(
"i"
,{
class
:
p
,
style
:
r
}),
O
(
"div"
,{
class
:
"xm-option-content"
,
dangerouslySetInnerHTML
:{
__html
:
l
({
data
:
o
,
item
:
e
,
arr
:
c
,
name
:
e
[
_
],
value
:
e
[
w
]})}}))}(
e
)}))).
length
||
(
!
e
.
pageEmptyShow
&&
(
D
=
""
),
j
.
push
(
O
(
"div"
,{
class
:
"xm-select-empty"
},
u
))),
O
(
"div"
,{
onClick
:
this
.
blockClick
,
tabindex
:
"1"
,
style
:
"outline: none;"
},
O
(
"div"
,
null
,
e
.
toolbar
.
show
&&
q
,
P
,
O
(
"div"
,{
class
:
"scroll-body"
,
style
:{
maxHeight
:
e
.
height
}},
j
),
e
.
paging
&&
D
),
this
.
state
.
loading
&&
O
(
"div"
,{
class
:
"loading"
},
O
(
"span"
,{
class
:
"loader"
})))}},{
key
:
"componentDidMount"
,
value
:
function
(){
var
e
=
this
.
base
.
querySelector
(
".xm-search-input"
);
e
&&
(
e
.
addEventListener
(
"compositionstart"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"compositionupdate"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"compositionend"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"input"
,
this
.
searchInput
.
bind
(
this
)),
this
.
searchInputRef
=
e
),
this
.
base
.
addEventListener
(
"keydown"
,
this
.
keydown
.
bind
(
this
,
"div"
))}},{
key
:
"componentDidUpdate"
,
value
:
function
(){
if
(
this
.
callback
){
this
.
callback
=!
1
;
var
e
=
this
.
props
.
filterDone
;
p
(
e
)
&&
e
(
this
.
state
.
filterValue
,
this
.
tempData
||
[])}}}])
&&
le
(
t
.
prototype
,
n
),
o
&&
le
(
t
,
o
),
i
}(
E
);
function
de
(
e
){
return
(
de
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
he
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
me
(
e
,
t
){
return
(
me
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
be
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
xe
(
e
);
if
(
t
){
var
r
=
xe
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
ye
(
this
,
n
)}}
function
ye
(
e
,
t
){
return
!
t
||
"object"
!==
de
(
t
)
&&
"function"
!=
typeof
t
?
function
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}(
e
):
t
}
function
xe
(
e
){
return
(
xe
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
var
ve
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
me
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
be
(
i
);
function
i
(
e
){
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),
r
.
call
(
this
,
e
)}
return
t
=
i
,(
n
=
[{
key
:
"blockClick"
,
value
:
function
(
e
){
e
.
stopPropagation
()}},{
key
:
"shouldComponentUpdate"
,
value
:
function
(){
return
!
this
.
prepare
}},{
key
:
"render"
,
value
:
function
(
e
){
return
this
.
prepare
=!
0
,
O
(
"div"
,{
onClick
:
this
.
blockClick
,
class
:
"xm-body-custom"
},
O
(
"div"
,{
class
:
"scroll-body"
,
style
:{
maxHeight
:
e
.
height
}},
O
(
"div"
,{
style
:
"margin: 5px 0"
,
dangerouslySetInnerHTML
:{
__html
:
e
.
content
}})))}}])
&&
he
(
t
.
prototype
,
n
),
o
&&
he
(
t
,
o
),
i
}(
E
);
function
ge
(
e
){
return
(
ge
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
_e
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
we
(
e
,
t
){
return
(
we
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
ke
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
Se
(
e
);
if
(
t
){
var
r
=
Se
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
Ce
(
this
,
n
)}}
function
Ce
(
e
,
t
){
return
!
t
||
"object"
!==
ge
(
t
)
&&
"function"
!=
typeof
t
?
function
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}(
e
):
t
}
function
Se
(
e
){
return
(
Se
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
var
Oe
=
{},
je
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
we
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
ke
(
i
);
function
i
(
e
){
var
t
;
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),(
t
=
r
.
call
(
this
,
e
)).
state
=
{
expandedKeys
:[],
filterValue
:
""
,
remote
:
!
0
,
loading
:
!
1
,
val
:
Oe
},
t
.
searchCid
=
0
,
t
.
inputOver
=!
0
,
t
.
__value
=
""
,
t
.
tempData
=
[],
t
}
return
t
=
i
,(
n
=
[{
key
:
"init"
,
value
:
function
(
e
){
var
t
=
e
.
tree
,
n
=
e
.
dataObj
,
o
=
e
.
flatData
,
r
=
e
.
prop
,
i
=
r
.
value
,
l
=
r
.
optgroup
,
a
=
[];
!
0
===
t
.
expandedKeys
?
a
=
o
.
filter
((
function
(
e
){
return
!
0
===
e
[
l
]})).
map
((
function
(
e
){
return
e
[
i
]})):
t
.
expandedKeys
.
forEach
((
function
(
e
){
a
.
push
(
e
);
for
(
var
t
=
n
[
e
],
o
=
function
(){
var
e
=
t
[
i
];
-
1
===
a
.
findIndex
((
function
(
t
){
return
t
===
e
}))
&&
a
.
push
(
e
),
t
=
t
.
__node
.
parent
};
t
;)
o
()})),
this
.
setState
({
expandedKeys
:
a
})}},{
key
:
"blockClick"
,
value
:
function
(
e
){
e
.
stopPropagation
()}},{
key
:
"optionClick"
,
value
:
function
(
e
,
t
,
n
,
o
,
r
){
var
i
=
this
;
if
(
"line"
===
o
){
if
(
!
0
===
e
.
__node
.
loading
)
return
;
var
l
=
this
.
props
,
a
=
l
.
tree
,
s
=
l
.
prop
,
c
=
l
.
sels
;
if
(
!
a
.
lazy
&&!
e
[
s
.
optgroup
])
return
void
this
.
props
.
ck
(
e
,
t
,
n
);
var
u
=
e
[
this
.
props
.
prop
.
value
],
p
=
this
.
state
.
expandedKeys
,
f
=
p
.
findIndex
((
function
(
e
){
return
e
===
u
}));
-
1
===
f
?
p
.
push
(
u
):
p
.
splice
(
f
,
1
),
this
.
setState
({
expandedKeys
:
p
});
var
d
=
e
[
s
.
children
];
a
.
lazy
&&
d
&&
0
===
d
.
length
&&!
1
!==
e
.
__node
.
loading
&&
(
e
.
__node
.
loading
=!
0
,
a
.
load
(
e
,(
function
(
t
){
e
.
__node
.
loading
=!
1
,
e
[
s
.
children
]
=
i
.
handlerData
(
t
,
s
.
children
),
e
[
s
.
selected
]
=-
1
!=
c
.
findIndex
((
function
(
t
){
return
t
[
s
.
value
]
===
e
[
s
.
value
]})),
i
.
props
.
onReset
(
c
,
"treeData"
)})))}
else
"checkbox"
===
o
&&
this
.
props
.
ck
(
e
,
t
,
n
);
this
.
blockClick
(
r
)}},{
key
:
"handlerData"
,
value
:
function
(
e
,
t
){
var
n
=
this
;
return
e
.
map
((
function
(
e
){
return
e
.
__node
=
{},
e
[
t
]
&&
(
e
[
t
]
=
n
.
handlerData
(
e
[
t
],
t
)),
e
}))}},{
key
:
"searchInput"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
e
.
target
.
value
;
n
!==
this
.
__value
&&
(
clearTimeout
(
this
.
searchCid
),
this
.
inputOver
&&
(
this
.
__value
=
n
,
this
.
searchCid
=
setTimeout
((
function
(){
t
.
callback
=!
0
,
t
.
setState
({
filterValue
:
t
.
__value
,
remote
:
!
0
})}),
this
.
props
.
delay
)))}},{
key
:
"focus"
,
value
:
function
(){
this
.
searchInputRef
&&
this
.
searchInputRef
.
focus
()}},{
key
:
"blur"
,
value
:
function
(){
this
.
searchInputRef
&&
this
.
searchInputRef
.
blur
()}},{
key
:
"handleComposition"
,
value
:
function
(
e
){
var
t
=
e
.
type
;
"compositionstart"
===
t
?(
this
.
inputOver
=!
1
,
clearTimeout
(
this
.
searchCid
)):
"compositionend"
===
t
&&
(
this
.
inputOver
=!
0
,
this
.
searchInput
(
e
))}},{
key
:
"filterData"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
this
.
props
,
r
=
o
.
prop
,
i
=
o
.
filterMethod
,
l
=
o
.
tree
,
a
=
r
.
children
,
s
=
r
.
optgroup
,
c
=
(
r
.
name
,
r
.
value
);
return
e
.
forEach
((
function
(
e
,
o
){
if
(
e
[
s
]){
var
u
=
n
.
filterData
(
e
[
a
],
t
);
if
(
e
.
__node
.
hidn
=!!
t
&&
0
===
u
.
filter
((
function
(
e
){
return
!
e
.
__node
.
hidn
})).
length
,
!
e
.
__node
.
hidn
){
var
p
=
n
.
state
.
expandedKeys
;
return
void
(
t
&&-
1
===
p
.
findIndex
((
function
(
t
){
return
t
===
e
[
c
]}))
&&
(
p
.
push
(
e
[
c
]),
n
.
setState
({
expandedKeys
:
p
})))}
if
(
l
.
strict
)
return
}
e
.
__node
.
hidn
=!!
t
&&!
i
(
t
,
e
,
o
,
r
)})),
e
}},{
key
:
"postData"
,
value
:
function
(){
var
e
=
this
;
this
.
state
.
remote
&&
(
this
.
callback
=!
1
,
this
.
setState
({
loading
:
!
0
,
remote
:
!
1
}),
this
.
blur
(),
this
.
props
.
remoteMethod
(
this
.
state
.
filterValue
,(
function
(
t
,
n
){
e
.
focus
(),
e
.
callback
=!
0
,
e
.
setState
({
loading
:
!
1
,
totalSize
:
n
}),
e
.
props
.
onReset
(
t
,
"data"
)}),
this
.
props
.
show
,
1
))}},{
key
:
"componentWillReceiveProps"
,
value
:
function
(
e
){
var
t
=
this
;
this
.
props
.
show
!=
e
.
show
&&
(
e
.
show
?
setTimeout
((
function
(){
return
t
.
focus
()}),
0
):(
this
.
setState
({
filterValue
:
""
,
val
:
Oe
}),
this
.
__value
=
""
,
this
.
searchInputRef
&&
(
this
.
searchInputRef
.
value
=
""
)))}},{
key
:
"componentWillMount"
,
value
:
function
(){
this
.
init
(
this
.
props
)}},{
key
:
"render"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
(
t
.
expandedKeys
,
e
.
prop
),
r
=
e
.
empty
,
i
=
e
.
sels
,
l
=
e
.
theme
,
a
=
e
.
radio
,
s
=
e
.
template
,
c
=
e
.
data
,
u
=
e
.
tree
,
h
=
e
.
filterable
,
m
=
e
.
remoteSearch
,
b
=
e
.
searchTips
,
y
=
o
.
name
,
x
=
o
.
value
,
v
=
o
.
disabled
,
g
=
o
.
children
,
_
=
o
.
optgroup
,
w
=
"hidden"
!=
e
.
model
.
icon
,
k
=
function
(
e
,
t
,
o
){
var
r
=!!
i
.
find
((
function
(
t
){
return
t
[
x
]
==
e
[
x
]})),
p
=
e
[
v
],
f
=!
0
===
e
.
__node
.
half
;
u
.
strict
&&
(
r
=
r
||
f
||
e
.
__node
.
selected
,
p
=
p
||
e
.
__node
.
disabled
);
var
d
=
r
?{
color
:
l
.
color
,
border
:
"none"
}:{
borderColor
:
l
.
color
},
h
=
{
paddingLeft
:
t
+
"px"
};
e
[
x
]
===
n
.
state
.
val
&&
(
h
.
backgroundColor
=
l
.
hover
),
!
w
&&
r
&&
(
h
.
backgroundColor
=
l
.
color
,
p
&&
(
h
.
backgroundColor
=
"#C2C2C2"
));
var
m
=
[
"xm-option"
,
p
?
" disabled"
:
""
,
r
?
" selected"
:
""
,
w
?
"show-icon"
:
"hide-icon"
].
join
(
" "
),
b
=
[
"xm-option-icon xm-iconfont"
,
a
?
"xm-icon-danx"
:
u
.
strict
&&
f
?
"xm-icon-banxuan"
:
"xm-icon-duox"
].
join
(
" "
),
_
=
[
"xm-tree-icon"
,
o
?
"expand"
:
""
,
e
[
g
]
&&
(
e
[
g
].
length
>
0
||
u
.
lazy
&&!
1
!==
e
.
__node
.
loading
)?
"xm-visible"
:
"xm-hidden"
].
join
(
" "
),
k
=
[];
u
.
showFolderIcon
&&
(
k
.
push
(
O
(
"i"
,{
class
:
_
})),
u
.
showLine
&&
(
o
&&
k
.
push
(
O
(
"i"
,{
class
:
"left-line"
,
style
:{
left
:
t
-
u
.
indent
+
3
+
"px"
}})),
k
.
push
(
O
(
"i"
,{
class
:
"top-line"
,
style
:{
left
:
t
-
u
.
indent
+
3
+
"px"
,
width
:
u
.
indent
+
(
0
===
o
?
10
:
-
2
)
+
"px"
}}))));
var
C
=
function
(
t
){
"mouseenter"
===
t
.
type
&&
(
e
[
v
]
||
n
.
setState
({
val
:
e
[
x
]}))};
return
O
(
"div"
,{
class
:
m
,
style
:
h
,
value
:
e
[
x
],
onClick
:
n
.
optionClick
.
bind
(
n
,
e
,
r
,
e
[
v
],
"line"
),
onMouseEnter
:
C
,
onMouseLeave
:
C
},
k
,
e
.
__node
.
loading
&&
O
(
"span"
,{
class
:
"loader"
}),
w
&&
O
(
"i"
,{
class
:
b
,
style
:
d
,
onClick
:
n
.
optionClick
.
bind
(
n
,
e
,
r
,
e
[
v
],
"checkbox"
)}),
O
(
"div"
,{
class
:
"xm-option-content"
,
dangerouslySetInnerHTML
:{
__html
:
s
({
data
:
c
,
item
:
e
,
arr
:
i
,
name
:
e
[
y
],
value
:
e
[
x
]})}}))};
h
&&
(
m
?
this
.
postData
():
this
.
filterData
(
c
,
this
.
state
.
filterValue
));
var
C
=
f
([],
c
),
S
=
f
([],
i
);
this
.
tempData
=
C
;
var
j
=
c
.
map
((
function
(
e
){
return
function
e
(
t
,
o
){
if
(
!
t
.
__node
.
hidn
){
var
r
=
t
[
g
];
if
(
o
+=
u
.
indent
,
r
){
var
i
=-
1
!==
n
.
state
.
expandedKeys
.
findIndex
((
function
(
e
){
return
t
[
x
]
===
e
}));
return
0
===
r
.
length
&&
(
i
=!
1
),
O
(
"div"
,{
class
:
"xm-tree"
},
u
.
showFolderIcon
&&
u
.
showLine
&&
i
&&
r
.
length
>
0
&&
O
(
"i"
,{
class
:
"left-line left-line-group"
,
style
:{
left
:
o
+
3
+
"px"
}}),
k
(
t
,
o
,
0
===
r
.
length
&&
(
!
u
.
lazy
||
u
.
lazy
&&!
1
===
t
.
__node
.
loading
)?
0
:
i
),
i
&&
O
(
"div"
,{
class
:
"xm-tree-box"
},
r
.
map
((
function
(
t
){
return
e
(
t
,
o
)}))))}
return
k
(
t
,
o
,
0
)}}(
e
,
10
-
u
.
indent
)})).
filter
((
function
(
e
){
return
e
}));
function
A
(
e
,
t
){
t
.
forEach
((
function
(
t
){
return
t
[
_
]?(
!
u
.
strict
&&
e
.
push
(
t
),
A
(
e
,
t
[
g
])):
e
.
push
(
t
)}))}
var
E
=
O
(
"div"
,{
class
:
"xm-toolbar"
},
e
.
toolbar
.
list
.
map
((
function
(
t
){
var
r
,
s
=
e
.
languageProp
.
toolbar
[
t
];
r
=
"ALL"
===
t
?{
icon
:
"xm-iconfont xm-icon-quanxuan"
,
name
:
s
,
method
:
function
(
e
){
var
t
=
[];
A
(
t
,
e
),
t
=
t
.
filter
((
function
(
e
){
return
!
e
[
v
]})),
n
.
props
.
onReset
(
a
?
t
.
slice
(
0
,
1
):
d
(
t
,
i
,
o
),
"treeData"
)}}:
"CLEAR"
===
t
?{
icon
:
"xm-iconfont xm-icon-qingkong"
,
name
:
s
,
method
:
function
(
e
){
n
.
props
.
onReset
(
i
.
filter
((
function
(
e
){
return
e
[
o
.
disabled
]})),
"treeData"
)}}:
"REVERSE"
===
t
?{
icon
:
"xm-iconfont xm-icon-fanxuan"
,
name
:
s
,
method
:
function
(
e
){
var
t
=
[];
A
(
t
,
e
),
t
=
t
.
filter
((
function
(
e
){
return
!
e
[
v
]}));
var
r
=
[];
i
.
forEach
((
function
(
e
){
var
n
=
t
.
findIndex
((
function
(
t
){
return
t
[
x
]
===
e
[
x
]}));
-
1
==
n
?
r
.
push
(
e
):
t
.
splice
(
n
,
1
)})),
n
.
props
.
onReset
(
a
?
r
.
slice
(
0
,
1
):
d
(
t
,
r
,
o
),
"treeData"
)}}:
t
;
var
c
=
function
(
e
){
"mouseenter"
===
e
.
type
&&
(
e
.
target
.
style
.
color
=
l
.
color
),
"mouseleave"
===
e
.
type
&&
(
e
.
target
.
style
.
color
=
""
)};
return
O
(
"div"
,{
class
:
"toolbar-tag"
,
onClick
:
function
(){
p
(
r
.
method
)
&&
r
.
method
(
C
,
S
)},
onMouseEnter
:
c
,
onMouseLeave
:
c
},
e
.
toolbar
.
showIcon
&&
O
(
"i"
,{
class
:
r
.
icon
}),
O
(
"span"
,
null
,
r
.
name
))})).
filter
((
function
(
e
){
return
e
}))),
R
=
O
(
"div"
,{
class
:
h
?
"xm-search"
:
"xm-search dis"
},
O
(
"i"
,{
class
:
"xm-iconfont xm-icon-sousuo"
}),
O
(
"input"
,{
class
:
"xm-input xm-search-input"
,
placeholder
:
b
}));
return
j
.
length
||
j
.
push
(
O
(
"div"
,{
class
:
"xm-select-empty"
},
r
)),
O
(
"div"
,{
onClick
:
this
.
blockClick
,
class
:
"xm-body-tree"
},
e
.
toolbar
.
show
&&
E
,
R
,
O
(
"div"
,{
class
:
"scroll-body"
,
style
:{
maxHeight
:
e
.
height
}},
j
),
this
.
state
.
loading
&&
O
(
"div"
,{
class
:
"loading"
},
O
(
"span"
,{
class
:
"loader"
})))}},{
key
:
"componentDidMount"
,
value
:
function
(){
var
e
=
this
.
base
.
querySelector
(
".xm-search-input"
);
e
&&
(
e
.
addEventListener
(
"compositionstart"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"compositionupdate"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"compositionend"
,
this
.
handleComposition
.
bind
(
this
)),
e
.
addEventListener
(
"input"
,
this
.
searchInput
.
bind
(
this
)),
this
.
searchInputRef
=
e
)}},{
key
:
"componentDidUpdate"
,
value
:
function
(){
if
(
this
.
callback
){
this
.
callback
=!
1
;
var
e
=
this
.
props
.
filterDone
;
p
(
e
)
&&
e
(
this
.
state
.
filterValue
,
this
.
tempData
||
[])}}}])
&&
_e
(
t
.
prototype
,
n
),
o
&&
_e
(
t
,
o
),
i
}(
E
);
function
Ae
(
e
){
return
(
Ae
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
Ee
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
Re
(
e
,
t
){
return
(
Re
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
Pe
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
De
(
e
);
if
(
t
){
var
r
=
De
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
Ie
(
this
,
n
)}}
function
Ie
(
e
,
t
){
return
!
t
||
"object"
!==
Ae
(
t
)
&&
"function"
!=
typeof
t
?
function
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}(
e
):
t
}
function
De
(
e
){
return
(
De
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
var
Me
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
Re
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
Pe
(
i
);
function
i
(
e
){
var
t
;
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),(
t
=
r
.
call
(
this
,
e
)).
state
=
{
expand
:[]},
t
}
return
t
=
i
,(
n
=
[{
key
:
"blockClick"
,
value
:
function
(
e
){
e
.
stopPropagation
()}},{
key
:
"optionClick"
,
value
:
function
(
e
,
t
,
n
,
o
,
r
,
i
){
if
(
"line"
===
o
){
if
(
n
)
return
;
if
(
!
0
===
e
.
__node
.
loading
)
return
;
var
l
=
this
.
props
,
a
=
l
.
cascader
,
s
=
l
.
prop
;
if
(
l
.
sels
,
!
a
.
lazy
&&!
e
[
s
.
optgroup
])
return
void
this
.
props
.
ck
(
e
,
t
,
n
);
var
c
=
this
.
state
.
expand
.
slice
(
0
,
r
+
1
);
c
[
r
]
=
e
[
this
.
props
.
prop
.
value
],
this
.
setState
({
expand
:
c
})}
else
"checkbox"
===
o
&&
this
.
props
.
ck
(
e
,
t
,
n
);
this
.
blockClick
(
i
)}},{
key
:
"componentWillReceiveProps"
,
value
:
function
(
e
){}},{
key
:
"componentWillMount"
,
value
:
function
(){}},{
key
:
"render"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
e
.
prop
,
r
=
e
.
empty
,
i
=
e
.
sels
,
l
=
e
.
theme
,
a
=
e
.
radio
,
s
=
e
.
template
,
c
=
e
.
data
,
u
=
e
.
cascader
,
p
=
o
.
name
,
f
=
o
.
value
,
d
=
o
.
disabled
,
h
=
o
.
children
,
m
=
"hidden"
!=
e
.
model
.
icon
,
b
=
[],
y
=
function
e
(
t
,
o
,
r
){
var
y
=
t
[
h
];
o
=
o
+
u
.
indent
+
6
;
var
x
=
y
&&
n
.
state
.
expand
[
r
]
===
t
[
f
];
return
x
&&
b
.
push
(
O
(
"div"
,{
class
:
"xm-cascader-box"
,
index
:
r
%
4
,
style
:{
left
:
o
+
"px"
,
width
:
u
.
indent
+
"px"
}},
O
(
"div"
,{
class
:
"xm-cascader-scroll"
},
y
.
map
((
function
(
t
){
return
e
(
t
,
o
,
r
+
1
)}))))),
function
(
e
,
t
,
o
,
r
){
var
b
=!!
i
.
find
((
function
(
t
){
return
t
[
f
]
==
e
[
f
]})),
y
=
e
[
d
],
x
=!
0
===
e
.
__node
.
half
;
u
.
strict
&&
(
b
=
b
||
x
||
e
.
__node
.
selected
,
y
=
y
||
e
.
__node
.
disabled
);
var
v
=
b
?{
color
:
l
.
color
,
border
:
"none"
}:{
borderColor
:
l
.
color
},
g
=
{
backgroundColor
:
"transparent"
},
_
=
[
"xm-option"
,
y
?
" disabled"
:
""
,
b
?
" selected"
:
""
,
m
?
"show-icon"
:
"hide-icon"
].
join
(
" "
),
w
=
[
"xm-option-icon xm-iconfont"
,
a
?
"xm-icon-danx"
:
u
.
strict
&&
x
?
"xm-icon-banxuan"
:
"xm-icon-duox"
].
join
(
" "
);
e
[
f
]
===
n
.
state
.
val
&&
(
g
.
backgroundColor
=
l
.
hover
);
var
k
=
{},
C
=
{};
r
&&
(
k
.
color
=
l
.
color
,
k
.
fontWeight
=
700
,
C
.
color
=
l
.
color
);
var
S
=
function
(
t
){
"mouseenter"
===
t
.
type
?
e
[
d
]
||
n
.
setState
({
val
:
e
[
f
]}):
"mouseleave"
===
t
.
type
&&
n
.
setState
({
val
:
""
})};
return
O
(
"div"
,{
class
:
_
,
style
:
g
,
value
:
e
[
f
],
onClick
:
n
.
optionClick
.
bind
(
n
,
e
,
b
,
y
,
"line"
,
o
),
onMouseEnter
:
S
,
onMouseLeave
:
S
},
m
&&
O
(
"i"
,{
class
:
w
,
style
:
v
,
onClick
:
n
.
optionClick
.
bind
(
n
,
e
,
b
,
y
,
"checkbox"
,
o
)}),
O
(
"div"
,{
class
:
"xm-option-content"
,
style
:
k
,
dangerouslySetInnerHTML
:{
__html
:
s
({
data
:
c
,
item
:
e
,
arr
:
i
,
name
:
e
[
p
],
value
:
e
[
f
]})}}),
e
[
h
]
&&
O
(
"div"
,{
class
:
"xm-right-arrow"
,
style
:
C
}))}(
t
,
0
,
r
,
x
)},
x
=
c
.
map
((
function
(
e
){
return
y
(
e
,
2
,
0
)})).
concat
(
b
).
filter
((
function
(
e
){
return
e
}));
return
x
.
length
||
x
.
push
(
O
(
"div"
,{
class
:
"xm-select-empty"
},
r
)),
O
(
"div"
,{
onClick
:
this
.
blockClick
,
class
:
"xm-body-cascader"
,
style
:{
width
:
u
.
indent
+
"px"
,
height
:
e
.
height
}},
x
)}},{
key
:
"componentDidMount"
,
value
:
function
(){
this
.
props
.
onReset
(
"cascader"
,
"class"
)}},{
key
:
"componentDidUpdate"
,
value
:
function
(){}}])
&&
Ee
(
t
.
prototype
,
n
),
o
&&
Ee
(
t
,
o
),
i
}(
E
);
function
Te
(
e
){
return
function
(
e
){
if
(
Array
.
isArray
(
e
))
return
ze
(
e
)}(
e
)
||
function
(
e
){
if
(
"undefined"
!=
typeof
Symbol
&&
Symbol
.
iterator
in
Object
(
e
))
return
Array
.
from
(
e
)}(
e
)
||
function
(
e
,
t
){
if
(
!
e
)
return
;
if
(
"string"
==
typeof
e
)
return
ze
(
e
,
t
);
var
n
=
Object
.
prototype
.
toString
.
call
(
e
).
slice
(
8
,
-
1
);
"Object"
===
n
&&
e
.
constructor
&&
(
n
=
e
.
constructor
.
name
);
if
(
"Map"
===
n
||
"Set"
===
n
)
return
Array
.
from
(
e
);
if
(
"Arguments"
===
n
||
/^
(?:
Ui|I
)
nt
(?:
8|16|32
)(?:
Clamped
)?
Array$/
.
test
(
n
))
return
ze
(
e
,
t
)}(
e
)
||
function
(){
throw
new
TypeError
(
"Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
)}()}
function
ze
(
e
,
t
){(
null
==
t
||
t
>
e
.
length
)
&&
(
t
=
e
.
length
);
for
(
var
n
=
0
,
o
=
new
Array
(
t
);
n
<
t
;
n
++
)
o
[
n
]
=
e
[
n
];
return
o
}
function
Le
(
e
,
t
){
var
n
=
Object
.
keys
(
e
);
if
(
Object
.
getOwnPropertySymbols
){
var
o
=
Object
.
getOwnPropertySymbols
(
e
);
t
&&
(
o
=
o
.
filter
((
function
(
t
){
return
Object
.
getOwnPropertyDescriptor
(
e
,
t
).
enumerable
}))),
n
.
push
.
apply
(
n
,
o
)}
return
n
}
function
Ve
(
e
){
for
(
var
t
=
1
;
t
<
arguments
.
length
;
t
++
){
var
n
=
null
!=
arguments
[
t
]?
arguments
[
t
]:{};
t
%
2
?
Le
(
Object
(
n
),
!
0
).
forEach
((
function
(
t
){
Ue
(
e
,
t
,
n
[
t
])})):
Object
.
getOwnPropertyDescriptors
?
Object
.
defineProperties
(
e
,
Object
.
getOwnPropertyDescriptors
(
n
)):
Le
(
Object
(
n
)).
forEach
((
function
(
t
){
Object
.
defineProperty
(
e
,
t
,
Object
.
getOwnPropertyDescriptor
(
n
,
t
))}))}
return
e
}
function
Ue
(
e
,
t
,
n
){
return
t
in
e
?
Object
.
defineProperty
(
e
,
t
,{
value
:
n
,
enumerable
:
!
0
,
configurable
:
!
0
,
writable
:
!
0
}):
e
[
t
]
=
n
,
e
}
function
Fe
(
e
){
return
(
Fe
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
Be
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
function
Ne
(
e
,
t
){
return
(
Ne
=
Object
.
setPrototypeOf
||
function
(
e
,
t
){
return
e
.
__proto__
=
t
,
e
})(
e
,
t
)}
function
He
(
e
){
var
t
=
function
(){
if
(
"undefined"
==
typeof
Reflect
||!
Reflect
.
construct
)
return
!
1
;
if
(
Reflect
.
construct
.
sham
)
return
!
1
;
if
(
"function"
==
typeof
Proxy
)
return
!
0
;
try
{
return
Date
.
prototype
.
toString
.
call
(
Reflect
.
construct
(
Date
,[],(
function
(){}))),
!
0
}
catch
(
e
){
return
!
1
}}();
return
function
(){
var
n
,
o
=
Ye
(
e
);
if
(
t
){
var
r
=
Ye
(
this
).
constructor
;
n
=
Reflect
.
construct
(
o
,
arguments
,
r
)}
else
n
=
o
.
apply
(
this
,
arguments
);
return
Ke
(
this
,
n
)}}
function
Ke
(
e
,
t
){
return
!
t
||
"object"
!==
Fe
(
t
)
&&
"function"
!=
typeof
t
?
qe
(
e
):
t
}
function
qe
(
e
){
if
(
void
0
===
e
)
throw
new
ReferenceError
(
"this hasn't been initialised - super() hasn't been called"
);
return
e
}
function
Ye
(
e
){
return
(
Ye
=
Object
.
setPrototypeOf
?
Object
.
getPrototypeOf
:
function
(
e
){
return
e
.
__proto__
||
Object
.
getPrototypeOf
(
e
)})(
e
)}
var
Ze
=
function
(
e
){
!
function
(
e
,
t
){
if
(
"function"
!=
typeof
t
&&
null
!==
t
)
throw
new
TypeError
(
"Super expression must either be null or a function"
);
e
.
prototype
=
Object
.
create
(
t
&&
t
.
prototype
,{
constructor
:{
value
:
e
,
writable
:
!
0
,
configurable
:
!
0
}}),
t
&&
Ne
(
e
,
t
)}(
i
,
e
);
var
t
,
n
,
o
,
r
=
He
(
i
);
function
i
(
e
){
var
t
;
return
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
i
),
t
=
r
.
call
(
this
,
e
),
rt
[
e
.
el
]
=
qe
(
t
),
t
.
state
=
t
.
initState
(),
t
.
bodyView
=
null
,
t
}
return
t
=
i
,(
n
=
[{
key
:
"initState"
,
value
:
function
(){
return
{
data
:[],
dataObj
:{},
flatData
:[],
sels
:[],
show
:
!
1
,
tmpColor
:
""
,
bodyClass
:
""
}}},{
key
:
"init"
,
value
:
function
(
e
,
t
){
var
n
,
o
=
e
.
data
,
r
=
e
.
prop
,
i
=
e
.
initValue
,
l
=
e
.
radio
;
if
(
t
){
var
a
=
{},
s
=
[];
this
.
load
(
o
,
a
,
s
),
n
=
this
.
exchangeValue
(
i
||
Object
.
keys
(
a
).
filter
((
function
(
e
){
return
!
0
===
a
[
e
][
r
.
selected
]})),
a
),
l
&&
n
.
length
>
1
&&
(
n
=
n
.
slice
(
0
,
1
)),
this
.
setState
({
sels
:
n
,
dataObj
:
a
,
flatData
:
s
})}
return
this
.
setState
({
data
:
o
}),
n
}},{
key
:
"exchangeValue"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
arguments
.
length
>
1
&&
void
0
!==
arguments
[
1
]?
arguments
[
1
]:
this
.
state
.
dataObj
,
o
=
e
.
map
((
function
(
e
){
return
"object"
===
Fe
(
e
)?
Ve
(
Ve
({},
e
),{},{
__node
:{}}):
n
[
e
]})).
filter
((
function
(
e
){
return
e
})),
r
=!
0
,
i
=
this
.
props
.
tree
;
return
i
.
show
&&!
1
===
i
.
strict
&&
(
r
=!
1
),
r
&&
(
o
=
o
.
filter
((
function
(
e
){
return
!
0
!==
e
[
t
.
props
.
prop
.
optgroup
]}))),
o
}},{
key
:
"value"
,
value
:
function
(
e
,
t
,
n
){
!
1
!==
t
&&!
0
!==
t
&&
(
t
=
this
.
state
.
show
);
var
o
=
this
.
props
,
r
=
o
.
prop
,
i
=
o
.
tree
,
l
=
this
.
exchangeValue
(
e
);
if
(
i
.
show
&&
i
.
strict
){
var
a
=
this
.
state
.
data
;
this
.
clearAndReset
(
a
,
l
),
l
=
this
.
init
({
data
:
a
,
prop
:
r
},
!
0
)}
this
.
resetSelectValue
(
l
,
l
,
!
0
,
n
),
this
.
setState
({
show
:
t
})}},{
key
:
"clearAndReset"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
this
.
props
.
prop
,
r
=
o
.
selected
,
i
=
o
.
children
,
l
=
o
.
value
;
e
.
forEach
((
function
(
e
){
e
[
r
]
=-
1
!=
t
.
findIndex
((
function
(
t
){
return
t
[
l
]
===
e
[
l
]}));
var
o
=
e
[
i
];
o
&&
u
(
o
)
&&
n
.
clearAndReset
(
o
,
t
)}))}},{
key
:
"load"
,
value
:
function
(
e
,
t
,
n
,
o
){
var
r
=
this
,
i
=
arguments
.
length
>
4
&&
void
0
!==
arguments
[
4
]?
arguments
[
4
]:
0
,
l
=
this
.
props
,
a
=
l
.
prop
,
s
=
l
.
tree
,
c
=
a
.
children
,
p
=
a
.
optgroup
,
f
=
a
.
value
,
d
=
a
.
selected
,
h
=
a
.
disabled
;
e
.
forEach
((
function
(
e
){
e
.
__node
=
{
parent
:
o
,
level
:
i
,
loading
:
e
.
__node
&&
e
.
__node
.
loading
},
t
[
e
[
f
]]
=
e
,
n
.
push
(
e
);
var
l
=
e
[
c
];
if
(
l
&&
u
(
l
)){
var
a
=
l
.
length
;
if
(
a
>
0
){
r
.
load
(
l
,
t
,
n
,
e
,
i
+
1
),
e
[
p
]
=!
0
,
s
.
strict
&&
(
!
0
===
e
[
d
]
&&
(
delete
e
[
d
],
l
.
forEach
((
function
(
e
){
return
e
[
d
]
=!
0
}))),
!
0
===
e
[
h
]
&&
(
delete
e
[
h
],
l
.
forEach
((
function
(
e
){
return
e
[
h
]
=!
0
}))));
var
m
=
l
.
filter
((
function
(
e
){
return
!
0
===
e
[
d
]
||!
0
===
e
.
__node
.
selected
})).
length
;
e
.
__node
.
selected
=
m
===
a
,
e
.
__node
.
half
=
m
>
0
&&
m
<
a
||
l
.
filter
((
function
(
e
){
return
!
0
===
e
.
__node
.
half
})).
length
>
0
,
e
.
__node
.
disabled
=
l
.
filter
((
function
(
e
){
return
!
0
===
e
[
h
]
||!
0
===
e
.
__node
.
disabled
})).
length
===
a
}}}))}},{
key
:
"resetSelectValue"
,
value
:
function
(){
var
e
=
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]?
arguments
[
0
]:[],
t
=
arguments
.
length
>
1
&&
void
0
!==
arguments
[
1
]?
arguments
[
1
]:[],
n
=
arguments
.
length
>
2
?
arguments
[
2
]:
void
0
,
o
=!
(
arguments
.
length
>
3
&&
void
0
!==
arguments
[
3
])
||
arguments
[
3
],
r
=
this
.
props
.
on
;
if
(
p
(
r
)
&&
this
.
prepare
&&
o
){
var
i
=
r
({
arr
:
e
,
change
:
t
,
isAdd
:
n
});
if
(
u
(
i
))
return
this
.
value
(
i
,
null
,
!
1
)}
this
.
setState
({
sels
:
e
})}},{
key
:
"updateBorderColor"
,
value
:
function
(
e
){
this
.
setState
({
tmpColor
:
e
})}},{
key
:
"treeHandler"
,
value
:
function
(
e
,
t
,
n
,
o
){
var
r
=
this
,
i
=
this
.
props
.
prop
,
l
=
i
.
value
,
a
=
(
i
.
selected
,
i
.
disabled
),
s
=
i
.
children
,
c
=
i
.
optgroup
,
u
=
t
[
s
];
u
.
filter
((
function
(
e
){
return
!
(
e
[
a
]
||
e
.
__node
.
disabled
)})).
forEach
((
function
(
t
){
if
(
t
[
c
])
r
.
treeHandler
(
e
,
t
,
n
,
o
);
else
{
var
i
=
e
.
findIndex
((
function
(
e
){
return
e
[
l
]
==
t
[
l
]}));
"del"
===
o
?
-
1
!=
i
&&
(
e
.
splice
(
i
,
1
),
n
.
push
(
t
)):
"half"
!==
o
&&
"add"
!==
o
||-
1
==
i
&&
(
e
.
push
(
t
),
n
.
push
(
t
))}}));
var
p
=
u
.
length
,
f
=
u
.
filter
((
function
(
t
){
return
-
1
!==
e
.
findIndex
((
function
(
e
){
return
e
[
l
]
===
t
[
l
]}))
||!
0
===
t
.
__node
.
selected
})).
length
;
t
.
__node
.
selected
=
f
===
p
,
t
.
__node
.
half
=
f
>
0
&&
f
<
p
}},{
key
:
"itemClick"
,
value
:
function
(
e
,
t
,
n
,
o
){
var
r
=
this
.
props
,
i
=
r
.
theme
,
l
=
r
.
prop
,
a
=
r
.
radio
,
s
=
r
.
repeat
,
c
=
r
.
clickClose
,
u
=
r
.
max
,
f
=
r
.
maxMethod
,
d
=
r
.
tree
,
h
=
this
.
state
.
sels
,
m
=
l
.
value
,
b
=
(
l
.
selected
,
l
.
disabled
,
l
.
children
),
y
=
l
.
optgroup
;
if
(
!
n
){
if
(
e
[
y
]
&&
d
.
strict
){
e
[
b
];
var
x
=
[],
v
=!
0
;
e
.
__node
.
selected
?(
this
.
treeHandler
(
h
,
e
,
x
,
"del"
),
v
=!
1
):
e
.
__node
.
half
?(
this
.
treeHandler
(
h
,
e
,
x
,
"half"
),
0
===
x
.
length
&&
(
this
.
treeHandler
(
h
,
e
,
x
,
"del"
),
v
=!
1
)):
this
.
treeHandler
(
h
,
e
,
x
,
"add"
),
this
.
resetSelectValue
(
h
,
x
,
v
),
this
.
setState
({
data
:
this
.
state
.
data
})}
else
if
(
!
t
||
s
&&!
o
){
var
g
=
(
w
=
u
,
w
-=
0
,
isNaN
(
w
)
&&
(
w
=
0
),
w
);
if
(
g
>
0
&&
h
.
length
>=
g
)
return
this
.
updateBorderColor
(
i
.
maxColor
),
void
(
f
&&
p
(
f
)
&&
f
(
h
,
e
));
h
=
a
?[
e
]:[].
concat
(
Te
(
h
),[
e
]),
this
.
resetSelectValue
(
h
,[
e
],
!
t
)}
else
{
var
_
=
h
.
findIndex
((
function
(
t
){
return
t
[
m
]
==
e
[
m
]}));
-
1
!=
_
&&
(
h
.
splice
(
_
,
1
),
this
.
resetSelectValue
(
h
,[
e
],
!
t
))}
var
w
,
k
=
e
.
__node
.
parent
;
if
(
k
){
for
(;
k
;){
var
C
=
k
[
b
],
S
=
C
.
length
,
O
=
C
.
filter
((
function
(
e
){
return
-
1
!==
h
.
findIndex
((
function
(
t
){
return
t
[
m
]
===
e
[
m
]}))
||!
0
===
e
.
__node
.
selected
})).
length
;
k
.
__node
.
selected
=
O
===
S
,
k
.
__node
.
half
=
O
>
0
&&
O
<
S
||
C
.
filter
((
function
(
e
){
return
!
0
===
e
.
__node
.
half
})).
length
>
0
,
k
=
k
.
__node
.
parent
}
this
.
setState
({
data
:
this
.
state
.
data
})}
c
&&!
o
&&
this
.
onClick
()}}},{
key
:
"onClick"
,
value
:
function
(
e
){
var
t
=
this
;
if
(
"relative"
!==
this
.
props
.
model
.
type
)
if
(
this
.
props
.
disabled
)
!
1
!==
this
.
state
.
show
&&
this
.
setState
({
show
:
!
1
});
else
{
var
n
=!
this
.
state
.
show
;
if
(
n
){
if
(
this
.
props
.
show
&&
0
==
this
.
props
.
show
())
return
;
Object
.
keys
(
nt
).
filter
((
function
(
e
){
return
e
!=
t
.
props
.
el
})).
forEach
((
function
(
e
){
return
nt
[
e
].
closed
()}))}
else
{
if
(
this
.
props
.
hide
&&
0
==
this
.
props
.
hide
())
return
;
this
.
bodyView
.
scroll
&&
this
.
bodyView
.
scroll
(
0
,
0
)}
this
.
setState
({
show
:
n
}),
e
&&
e
.
stopPropagation
()}}},{
key
:
"onReset"
,
value
:
function
(
e
,
t
){
var
n
=
this
;
if
(
"data"
===
t
){
var
o
=
e
.
filter
((
function
(
e
){
return
!
0
===
e
[
n
.
props
.
prop
.
selected
]}));
this
.
resetSelectValue
(
d
(
o
,
this
.
state
.
sels
,
this
.
props
.
prop
),
o
,
!
0
);
var
r
=
[];
this
.
load
(
e
,{},
r
),
this
.
setState
({
data
:
e
,
flatData
:
r
})}
else
"sels"
===
t
?
this
.
resetSelectValue
(
e
,
e
,
!
0
):
"append"
===
t
?
this
.
append
(
e
):
"delete"
===
t
?
this
.
del
(
e
):
"auto"
===
t
?
this
.
auto
(
e
):
"treeData"
===
t
?
this
.
value
(
e
,
null
,
!
0
):
"close"
===
t
?
this
.
onClick
():
"class"
===
t
&&
this
.
setState
({
bodyClass
:
e
})}},{
key
:
"append"
,
value
:
function
(
e
){
var
t
=
this
.
exchangeValue
(
e
);
this
.
resetSelectValue
(
d
(
t
,
this
.
state
.
sels
,
this
.
props
.
prop
),
t
,
!
0
)}},{
key
:
"del"
,
value
:
function
(
e
){
var
t
=
this
.
props
.
prop
.
value
,
n
=
this
.
state
.
sels
;(
e
=
this
.
exchangeValue
(
e
)).
forEach
((
function
(
e
){
var
o
=
n
.
findIndex
((
function
(
n
){
return
n
[
t
]
===
e
[
t
]}));
-
1
!=
o
&&
n
.
splice
(
o
,
1
)})),
this
.
resetSelectValue
(
n
,
e
,
!
1
)}},{
key
:
"auto"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
this
.
props
.
prop
.
value
;
e
.
filter
((
function
(
e
){
return
-
1
!=
t
.
state
.
sels
.
findIndex
((
function
(
t
){
return
t
[
n
]
===
e
[
n
]}))})).
length
==
e
.
length
?
this
.
del
(
e
):
this
.
append
(
e
)}},{
key
:
"componentWillReceiveProps"
,
value
:
function
(
e
){
this
.
init
(
e
,
e
.
updateData
)}},{
key
:
"componentWillMount"
,
value
:
function
(){
this
.
init
(
this
.
props
,
!
0
)}},{
key
:
"render"
,
value
:
function
(
e
,
t
){
var
n
=
this
,
o
=
e
.
theme
,
r
=
e
.
prop
,
i
=
(
e
.
radio
,
e
.
repeat
,
e
.
clickClose
,
e
.
on
,
e
.
max
,
e
.
maxMethod
,
e
.
content
),
l
=
e
.
disabled
,
a
=
e
.
tree
,
s
=
{
borderColor
:
o
.
color
},
c
=
t
.
data
,
u
=
t
.
dataObj
,
p
=
t
.
flatData
,
f
=
t
.
sels
,
d
=
t
.
show
,
h
=
t
.
tmpColor
,
m
=
t
.
bodyClass
;
l
&&
(
d
=!
1
);
var
b
=
{
style
:
Ve
(
Ve
({},
e
.
style
),
d
?
s
:{}),
onClick
:
this
.
onClick
.
bind
(
this
),
ua
:
-
1
!=
navigator
.
userAgent
.
indexOf
(
"Mac OS"
)?
"mac"
:
"win"
,
size
:
e
.
size
,
tabindex
:
1
};
h
&&
(
b
.
style
.
borderColor
=
h
,
setTimeout
((
function
(){
b
.
style
.
borderColor
=
""
,
n
.
updateBorderColor
(
""
)}),
300
)),
r
.
value
;
var
y
=
Ve
(
Ve
({},
e
),{},{
data
:
c
,
sels
:
f
,
ck
:
this
.
itemClick
.
bind
(
this
),
title
:
f
.
map
((
function
(
e
){
return
e
[
r
.
name
]})).
join
(
","
)}),
x
=
Ve
(
Ve
({},
e
),{},{
data
:
c
,
dataObj
:
u
,
flatData
:
p
,
sels
:
f
,
ck
:
this
.
itemClick
.
bind
(
this
),
show
:
d
,
onReset
:
this
.
onReset
.
bind
(
this
)}),
v
=
i
?
O
(
ve
,
x
):
a
.
show
?
O
(
je
,
x
):
e
.
cascader
.
show
?
O
(
Me
,
x
):
O
(
fe
,
x
);
return
O
(
"xm-select"
,
b
,
O
(
"input"
,{
class
:
"xm-select-default"
,
"lay-verify"
:
e
.
layVerify
,
"lay-verType"
:
e
.
layVerType
,
name
:
e
.
name
,
value
:
f
.
map
((
function
(
e
){
return
e
[
r
.
value
]})).
join
(
","
)}),
O
(
"i"
,{
class
:
d
?
"xm-icon xm-icon-expand"
:
"xm-icon"
}),
0
===
f
.
length
&&
O
(
"div"
,{
class
:
"xm-tips"
},
e
.
tips
),
O
(
te
,
y
),
O
(
"div"
,{
class
:[
"xm-body"
,
m
,
e
.
model
.
type
,
d
?
""
:
"dis"
].
join
(
" "
),
ref
:
function
(
e
){
return
n
.
bodyView
=
e
}},
v
),
l
&&
O
(
"div"
,{
class
:
"xm-select-disabled"
}))}},{
key
:
"componentDidMount"
,
value
:
function
(){
var
e
=
this
;
this
.
prepare
=!
0
,
this
.
base
.
addEventListener
(
"keydown"
,(
function
(
t
){
13
===
t
.
keyCode
&&
e
.
onClick
()})),
this
.
input
=
this
.
base
.
querySelector
(
".xm-select-default"
);
var
t
=
window
.
MutationObserver
||
window
.
WebKitMutationObserver
||
window
.
MozMutationObserver
;
t
&&
new
t
((
function
(
t
){
t
.
forEach
((
function
(
t
){
"attributes"
==
t
.
type
&&
"class"
===
t
.
attributeName
&&-
1
!==
e
.
input
.
className
.
indexOf
(
"layui-form-danger"
)
&&
(
e
.
input
.
className
=
"xm-select-default"
,
e
.
base
.
style
.
borderColor
=
e
.
props
.
theme
.
maxColor
)}))})).
observe
(
this
.
input
,{
attributes
:
!
0
});
for
(
var
n
=
this
.
base
;
n
;){
if
(
"FORM"
===
n
.
tagName
){
var
o
=
n
.
querySelector
(
'button[type="reset"]'
);
o
&&
o
.
addEventListener
(
"click"
,(
function
(
t
){
e
.
init
(
e
.
props
,
!
0
)}));
break
}
n
=
n
.
parentElement
}}},{
key
:
"componentDidUpdate"
,
value
:
function
(){
var
e
=
this
.
props
,
t
=
e
.
direction
;
if
(
"relative"
!==
e
.
model
.
type
){
var
n
=
this
.
base
.
getBoundingClientRect
();
if
(
"auto"
===
t
){
this
.
bodyView
.
style
.
display
=
"block"
,
this
.
bodyView
.
style
.
visibility
=
"hidden"
;
var
o
=
this
.
bodyView
.
getBoundingClientRect
().
height
;
this
.
bodyView
.
style
.
display
=
""
,
this
.
bodyView
.
style
.
visibility
=
""
;
var
r
=
n
.
y
||
n
.
top
||
0
,
i
=
document
.
documentElement
.
clientHeight
-
r
-
n
.
height
-
20
;
t
=
i
>
o
||
r
<
i
?
"down"
:
"up"
}
"down"
==
t
?(
this
.
bodyView
.
style
.
top
=
n
.
height
+
4
+
"px"
,
this
.
bodyView
.
style
.
bottom
=
"auto"
):(
this
.
bodyView
.
style
.
top
=
"auto"
,
this
.
bodyView
.
style
.
bottom
=
n
.
height
+
4
+
"px"
)}}}])
&&
Be
(
t
.
prototype
,
n
),
o
&&
Be
(
t
,
o
),
i
}(
E
),
Qe
=
{
tips
:
"请选择"
,
empty
:
"暂无数据"
,
searchTips
:
"请选择"
,
toolbar
:{
ALL
:
"全选"
,
CLEAR
:
"清空"
,
REVERSE
:
"反选"
,
SEARCH
:
"搜索"
},
paging
:{
prev
:
"上一页"
,
next
:
"下一页"
}},
Je
=
{
zn
:
Qe
,
en
:{
tips
:
"please selected"
,
empty
:
"no data"
,
searchTips
:
"please search"
,
toolbar
:{
ALL
:
"select all"
,
CLEAR
:
"clear"
,
REVERSE
:
"invert select"
,
SEARCH
:
"search"
},
paging
:{
prev
:
"prev"
,
next
:
"next"
}}};
function
We
(){
return
(
We
=
Object
.
assign
||
function
(
e
){
for
(
var
t
=
1
;
t
<
arguments
.
length
;
t
++
){
var
n
=
arguments
[
t
];
for
(
var
o
in
n
)
Object
.
prototype
.
hasOwnProperty
.
call
(
n
,
o
)
&&
(
e
[
o
]
=
n
[
o
])}
return
e
}).
apply
(
this
,
arguments
)}
function
Ge
(
e
){
return
(
Ge
=
"function"
==
typeof
Symbol
&&
"symbol"
==
typeof
Symbol
.
iterator
?
function
(
e
){
return
typeof
e
}:
function
(
e
){
return
e
&&
"function"
==
typeof
Symbol
&&
e
.
constructor
===
Symbol
&&
e
!==
Symbol
.
prototype
?
"symbol"
:
typeof
e
})(
e
)}
function
Xe
(
e
,
t
){
for
(
var
n
=
0
;
n
<
t
.
length
;
n
++
){
var
o
=
t
[
n
];
o
.
enumerable
=
o
.
enumerable
||!
1
,
o
.
configurable
=!
0
,
"value"
in
o
&&
(
o
.
writable
=!
0
),
Object
.
defineProperty
(
e
,
o
.
key
,
o
)}}
var
$e
=
function
(){
function
e
(
t
){
!
function
(
e
,
t
){
if
(
!
(
e
instanceof
t
))
throw
new
TypeError
(
"Cannot call a class as a function"
)}(
this
,
e
),
this
.
init
(
t
)}
var
t
,
n
,
o
;
return
t
=
e
,(
n
=
[{
key
:
"init"
,
value
:
function
(
e
){
this
.
options
=
function
(){
var
e
=
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]?
arguments
[
0
]:
"zn"
,
t
=
Je
[
e
]
||
Qe
;
return
{
language
:
e
,
languageProp
:
t
,
data
:[],
content
:
""
,
name
:
"select"
,
layVerify
:
""
,
layVerType
:
""
,
size
:
"medium"
,
disabled
:
!
1
,
initValue
:
null
,
create
:
null
,
tips
:
t
.
tips
,
empty
:
t
.
empty
,
delay
:
500
,
searchTips
:
t
.
searchTips
,
filterable
:
!
1
,
filterMethod
:
function
(
e
,
t
,
n
,
o
){
return
!
e
||-
1
!=
t
[
o
.
name
].
indexOf
(
e
)},
remoteSearch
:
!
1
,
remoteMethod
:
function
(
e
,
t
){
t
([])},
direction
:
"auto"
,
style
:{},
height
:
"200px"
,
autoRow
:
!
1
,
paging
:
!
1
,
pageSize
:
10
,
pageEmptyShow
:
!
0
,
pageRemote
:
!
1
,
radio
:
!
1
,
repeat
:
!
1
,
clickClose
:
!
1
,
max
:
0
,
maxMethod
:
function
(
e
,
t
){},
showCount
:
0
,
toolbar
:{
show
:
!
1
,
showIcon
:
!
0
,
list
:[
"ALL"
,
"CLEAR"
]},
tree
:{
show
:
!
1
,
showFolderIcon
:
!
0
,
showLine
:
!
0
,
indent
:
20
,
expandedKeys
:[],
strict
:
!
0
,
lazy
:
!
1
,
load
:
null
,
simple
:
!
1
},
cascader
:{
show
:
!
1
,
indent
:
100
,
strict
:
!
0
},
prop
:{
name
:
"name"
,
value
:
"value"
,
selected
:
"selected"
,
disabled
:
"disabled"
,
children
:
"children"
,
optgroup
:
"optgroup"
,
click
:
"click"
},
theme
:{
color
:
"#009688"
,
maxColor
:
"#e54d42"
,
hover
:
"#f2f2f2"
},
model
:{
label
:{
type
:
"block"
,
text
:{
left
:
""
,
right
:
""
,
separator
:
", "
},
block
:{
showCount
:
0
,
showIcon
:
!
0
,
template
:
null
},
count
:{
template
:
function
(
e
,
t
){
return
"已选中 "
.
concat
(
t
.
length
,
" 项, 共 "
).
concat
(
e
.
length
,
" 项"
)}}},
icon
:
"show"
,
type
:
"absolute"
},
show
:
function
(){},
hide
:
function
(){},
template
:
function
(
e
){
e
.
item
,
e
.
sels
;
var
t
=
e
.
name
;
return
e
.
value
,
t
},
on
:
function
(
e
){
e
.
arr
,
e
.
item
,
e
.
selected
}}}(
e
.
language
),
this
.
update
(
e
)}},{
key
:
"update"
,
value
:
function
(){
var
e
=
arguments
.
length
>
0
&&
void
0
!==
arguments
[
0
]?
arguments
[
0
]:{},
t
=!!
e
.
data
;
this
.
options
=
f
(
this
.
options
,
e
);
var
n
=
this
.
options
.
dom
;
if
(
n
){
var
o
=
this
.
options
.
data
||
[];
if
(
"function"
==
typeof
o
&&
(
o
=
o
(),
this
.
options
.
data
=
o
),
u
(
o
))
return
Y
(
O
(
Ze
,
We
({},
this
.
options
,{
updateData
:
t
})),
n
),
this
;
c
(
"data数据必须为数组类型, 不能是"
.
concat
(
"undefined"
==
typeof
data
?
"undefined"
:
Ge
(
data
),
"类型"
))}
else
c
(
"没有找到渲染对象: "
.
concat
(
e
.
el
,
", 请检查"
))}},{
key
:
"reset"
,
value
:
function
(){
var
e
=
this
.
options
.
el
;
return
this
.
init
(
ot
[
e
]),
rt
[
e
].
init
(
this
.
options
,
!
0
),
this
}},{
key
:
"opened"
,
value
:
function
(){
var
e
=
rt
[
this
.
options
.
el
];
return
!
e
.
state
.
show
&&
e
.
onClick
(),
this
}},{
key
:
"closed"
,
value
:
function
(){
var
e
=
rt
[
this
.
options
.
el
];
return
e
.
state
.
show
&&
e
.
onClick
(),
this
}},{
key
:
"getValue"
,
value
:
function
(
e
){
var
t
=
this
,
n
=
this
.
options
,
o
=
n
.
tree
,
r
=
n
.
prop
,
i
=
n
.
data
,
l
=
rt
[
this
.
options
.
el
].
state
.
sels
,
a
=
l
;
o
.
show
&&
o
.
strict
&&
o
.
simple
&&
h
(
i
,
l
,
a
=
[],
r
);
var
s
=
m
(
a
,
r
.
children
,[
"__node"
]);
return
"name"
===
e
?
s
.
map
((
function
(
e
){
return
e
[
t
.
options
.
prop
.
name
]})):
"nameStr"
===
e
?
s
.
map
((
function
(
e
){
return
e
[
t
.
options
.
prop
.
name
]})).
join
(
","
):
"value"
===
e
?
s
.
map
((
function
(
e
){
return
e
[
t
.
options
.
prop
.
value
]})):
"valueStr"
===
e
?
s
.
map
((
function
(
e
){
return
e
[
t
.
options
.
prop
.
value
]})).
join
(
","
):
s
}},{
key
:
"setValue"
,
value
:
function
(
e
,
t
){
var
n
=
arguments
.
length
>
2
&&
void
0
!==
arguments
[
2
]
&&
arguments
[
2
];
if
(
u
(
e
))
return
rt
[
this
.
options
.
el
].
value
(
this
.
options
.
radio
?
e
.
slice
(
0
,
1
):
e
,
t
,
n
),
this
;
c
(
"请传入数组结构..."
)}},{
key
:
"append"
,
value
:
function
(
e
){
if
(
u
(
e
))
return
rt
[
this
.
options
.
el
].
append
(
e
),
this
;
c
(
"请传入数组结构..."
)}},{
key
:
"delete"
,
value
:
function
(
e
){
if
(
u
(
e
))
return
rt
[
this
.
options
.
el
].
del
(
e
),
this
;
c
(
"请传入数组结构..."
)}},{
key
:
"warning"
,
value
:
function
(
e
){
var
t
=
arguments
.
length
>
1
&&
void
0
!==
arguments
[
1
]
&&
arguments
[
1
],
n
=
e
||
this
.
options
.
theme
.
maxColor
;
return
!
0
===
t
?
rt
[
this
.
options
.
el
].
base
.
style
.
borderColor
=
n
:
rt
[
this
.
options
.
el
].
updateBorderColor
(
n
),
this
}}])
&&
Xe
(
t
.
prototype
,
n
),
o
&&
Xe
(
t
,
o
),
e
}();
function
et
(
e
){
return
function
(
e
){
if
(
Array
.
isArray
(
e
))
return
tt
(
e
)}(
e
)
||
function
(
e
){
if
(
"undefined"
!=
typeof
Symbol
&&
Symbol
.
iterator
in
Object
(
e
))
return
Array
.
from
(
e
)}(
e
)
||
function
(
e
,
t
){
if
(
!
e
)
return
;
if
(
"string"
==
typeof
e
)
return
tt
(
e
,
t
);
var
n
=
Object
.
prototype
.
toString
.
call
(
e
).
slice
(
8
,
-
1
);
"Object"
===
n
&&
e
.
constructor
&&
(
n
=
e
.
constructor
.
name
);
if
(
"Map"
===
n
||
"Set"
===
n
)
return
Array
.
from
(
e
);
if
(
"Arguments"
===
n
||
/^
(?:
Ui|I
)
nt
(?:
8|16|32
)(?:
Clamped
)?
Array$/
.
test
(
n
))
return
tt
(
e
,
t
)}(
e
)
||
function
(){
throw
new
TypeError
(
"Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
)}()}
function
tt
(
e
,
t
){(
null
==
t
||
t
>
e
.
length
)
&&
(
t
=
e
.
length
);
for
(
var
n
=
0
,
o
=
new
Array
(
t
);
n
<
t
;
n
++
)
o
[
n
]
=
e
[
n
];
return
o
}
var
nt
=
{},
ot
=
{},
rt
=
{};
t
.
c
=
{
name
:
o
.
a
,
version
:
o
.
b
,
render
:
function
(
e
){
var
t
=
e
.
el
;
if
(
e
.
dom
=
s
(
t
),
t
.
nodeType
){
var
n
=
"DOM_RENDER_"
+
Date
.
now
()
+
"_"
+
Math
.
random
();
t
.
setAttribute
(
o
.
a
,
n
),
t
=
"["
.
concat
(
o
.
a
,
"='"
).
concat
(
n
,
"']"
),
e
.
el
=
t
}
ot
[
t
]
=
e
;
var
r
=
new
$e
(
e
);
return
r
&&
(
nt
[
t
]
=
r
),
r
},
get
:
function
(
e
,
t
){
var
n
;
switch
(
Object
.
prototype
.
toString
.
call
(
e
)){
case
"[object String]"
:
e
&&
(
n
=
function
(
t
){
return
t
===
e
});
break
;
case
"[object RegExp]"
:
n
=
function
(
t
){
return
e
.
test
(
t
)};
break
;
case
"[object Function]"
:
n
=
e
}
var
o
=
Object
.
keys
(
nt
),
r
=
(
n
?
o
.
filter
(
n
):
o
).
map
((
function
(
e
){
return
nt
[
e
]})).
filter
((
function
(
e
){
return
s
(
e
.
options
.
el
)}));
return
t
?
r
[
0
]:
r
},
batch
:
function
(
e
,
t
){
var
n
=
Array
.
prototype
.
slice
.
call
(
arguments
);
return
n
.
splice
(
0
,
2
),
this
.
get
(
e
).
map
((
function
(
e
){
return
e
[
t
].
apply
(
e
,
et
(
n
))}))}}}});
\ No newline at end of file
\ No newline at end of file
js/ztree.js
View file @
b68230a
...
@@ -3971,5 +3971,410 @@ layui.define(function (exports) {
...
@@ -3971,5 +3971,410 @@ layui.define(function (exports) {
return
!
root
.
curEditNode
&&
(
_uCanDo
?
_uCanDo
.
apply
(
view
,
arguments
)
:
true
)
return
!
root
.
curEditNode
&&
(
_uCanDo
?
_uCanDo
.
apply
(
view
,
arguments
)
:
true
)
}
}
})(
layui
.
$
)
})(
layui
.
$
)
/*
* JQuery zTree exHideNodes
* v3.5.46
* http://treejs.cn/
*
* Copyright (c) 2010 Hunter.z
*
* Licensed same as jquery - MIT License
* http://www.opensource.org/licenses/mit-license.php
*
* Date: 2020-11-21
*/
;(
function
(
$
)
{
var
_setting
=
{
data
:
{
key
:
{
isHidden
:
"isHidden"
}
}
};
//default init node of exLib
var
_initNode
=
function
(
setting
,
level
,
n
,
parentNode
,
isFirstNode
,
isLastNode
,
openFlag
)
{
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
data
.
isHidden
(
setting
,
n
,
isHidden
);
data
.
initHideForExCheck
(
setting
,
n
);
},
//add dom for check
_beforeA
=
function
(
setting
,
node
,
html
)
{
},
//update zTreeObj, add method of exLib
_zTreeTools
=
function
(
setting
,
zTreeTools
)
{
zTreeTools
.
showNodes
=
function
(
nodes
,
options
)
{
view
.
showNodes
(
setting
,
nodes
,
options
);
}
zTreeTools
.
showNode
=
function
(
node
,
options
)
{
if
(
!
node
)
{
return
;
}
view
.
showNodes
(
setting
,
[
node
],
options
);
}
zTreeTools
.
hideNodes
=
function
(
nodes
,
options
)
{
view
.
hideNodes
(
setting
,
nodes
,
options
);
}
zTreeTools
.
hideNode
=
function
(
node
,
options
)
{
if
(
!
node
)
{
return
;
}
view
.
hideNodes
(
setting
,
[
node
],
options
);
}
var
_checkNode
=
zTreeTools
.
checkNode
;
if
(
_checkNode
)
{
zTreeTools
.
checkNode
=
function
(
node
,
checked
,
checkTypeFlag
,
callbackFlag
)
{
if
(
!!
node
&&
!!
data
.
isHidden
(
setting
,
node
))
{
return
;
}
_checkNode
.
apply
(
zTreeTools
,
arguments
);
}
}
},
//method of operate data
_data
=
{
initHideForExCheck
:
function
(
setting
,
n
)
{
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
isHidden
&&
setting
.
check
&&
setting
.
check
.
enable
)
{
if
(
typeof
n
.
_nocheck
==
"undefined"
)
{
n
.
_nocheck
=
!!
n
.
nocheck
n
.
nocheck
=
true
;
}
n
.
check_Child_State
=
-
1
;
if
(
view
.
repairParentChkClassWithSelf
)
{
view
.
repairParentChkClassWithSelf
(
setting
,
n
);
}
}
},
initShowForExCheck
:
function
(
setting
,
n
)
{
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
!
isHidden
&&
setting
.
check
&&
setting
.
check
.
enable
)
{
if
(
typeof
n
.
_nocheck
!=
"undefined"
)
{
n
.
nocheck
=
n
.
_nocheck
;
delete
n
.
_nocheck
;
}
if
(
view
.
setChkClass
)
{
var
checkObj
=
$$
(
n
,
consts
.
id
.
CHECK
,
setting
);
view
.
setChkClass
(
setting
,
checkObj
,
n
);
}
if
(
view
.
repairParentChkClassWithSelf
)
{
view
.
repairParentChkClassWithSelf
(
setting
,
n
);
}
}
}
},
//method of operate ztree dom
_view
=
{
clearOldFirstNode
:
function
(
setting
,
node
)
{
var
n
=
node
.
getNextNode
();
while
(
!!
n
)
{
if
(
n
.
isFirstNode
)
{
n
.
isFirstNode
=
false
;
view
.
setNodeLineIcos
(
setting
,
n
);
break
;
}
if
(
n
.
isLastNode
)
{
break
;
}
n
=
n
.
getNextNode
();
}
},
clearOldLastNode
:
function
(
setting
,
node
,
openFlag
)
{
var
n
=
node
.
getPreNode
();
while
(
!!
n
)
{
if
(
n
.
isLastNode
)
{
n
.
isLastNode
=
false
;
if
(
openFlag
)
{
view
.
setNodeLineIcos
(
setting
,
n
);
}
break
;
}
if
(
n
.
isFirstNode
)
{
break
;
}
n
=
n
.
getPreNode
();
}
},
makeDOMNodeMainBefore
:
function
(
html
,
setting
,
node
)
{
var
isHidden
=
data
.
isHidden
(
setting
,
node
);
html
.
push
(
"<li "
,
(
isHidden
?
"style='display:none;' "
:
""
),
"id='"
,
node
.
tId
,
"' class='"
,
consts
.
className
.
LEVEL
,
node
.
level
,
"' tabindex='0' hidefocus='true' treenode>"
);
},
showNode
:
function
(
setting
,
node
,
options
)
{
data
.
isHidden
(
setting
,
node
,
false
);
data
.
initShowForExCheck
(
setting
,
node
);
$$
(
node
,
setting
).
show
();
},
showNodes
:
function
(
setting
,
nodes
,
options
)
{
if
(
!
nodes
||
nodes
.
length
==
0
)
{
return
;
}
var
pList
=
{},
i
,
j
;
for
(
i
=
0
,
j
=
nodes
.
length
;
i
<
j
;
i
++
)
{
var
n
=
nodes
[
i
];
if
(
!
pList
[
n
.
parentTId
])
{
var
pn
=
n
.
getParentNode
();
pList
[
n
.
parentTId
]
=
(
pn
===
null
)
?
data
.
getRoot
(
setting
)
:
n
.
getParentNode
();
}
view
.
showNode
(
setting
,
n
,
options
);
}
for
(
var
tId
in
pList
)
{
var
children
=
data
.
nodeChildren
(
setting
,
pList
[
tId
]);
view
.
setFirstNodeForShow
(
setting
,
children
);
view
.
setLastNodeForShow
(
setting
,
children
);
}
},
hideNode
:
function
(
setting
,
node
,
options
)
{
data
.
isHidden
(
setting
,
node
,
true
);
node
.
isFirstNode
=
false
;
node
.
isLastNode
=
false
;
data
.
initHideForExCheck
(
setting
,
node
);
view
.
cancelPreSelectedNode
(
setting
,
node
);
$$
(
node
,
setting
).
hide
();
},
hideNodes
:
function
(
setting
,
nodes
,
options
)
{
if
(
!
nodes
||
nodes
.
length
==
0
)
{
return
;
}
var
pList
=
{},
i
,
j
;
for
(
i
=
0
,
j
=
nodes
.
length
;
i
<
j
;
i
++
)
{
var
n
=
nodes
[
i
];
if
((
n
.
isFirstNode
||
n
.
isLastNode
)
&&
!
pList
[
n
.
parentTId
])
{
var
pn
=
n
.
getParentNode
();
pList
[
n
.
parentTId
]
=
(
pn
===
null
)
?
data
.
getRoot
(
setting
)
:
n
.
getParentNode
();
}
view
.
hideNode
(
setting
,
n
,
options
);
}
for
(
var
tId
in
pList
)
{
var
children
=
data
.
nodeChildren
(
setting
,
pList
[
tId
]);
view
.
setFirstNodeForHide
(
setting
,
children
);
view
.
setLastNodeForHide
(
setting
,
children
);
}
},
setFirstNode
:
function
(
setting
,
parentNode
)
{
var
children
=
data
.
nodeChildren
(
setting
,
parentNode
);
var
isHidden
=
data
.
isHidden
(
setting
,
children
[
0
],
false
);
if
(
children
.
length
>
0
&&
!
isHidden
)
{
children
[
0
].
isFirstNode
=
true
;
}
else
if
(
children
.
length
>
0
)
{
view
.
setFirstNodeForHide
(
setting
,
children
);
}
},
setLastNode
:
function
(
setting
,
parentNode
)
{
var
children
=
data
.
nodeChildren
(
setting
,
parentNode
);
var
isHidden
=
data
.
isHidden
(
setting
,
children
[
0
]);
if
(
children
.
length
>
0
&&
!
isHidden
)
{
children
[
children
.
length
-
1
].
isLastNode
=
true
;
}
else
if
(
children
.
length
>
0
)
{
view
.
setLastNodeForHide
(
setting
,
children
);
}
},
setFirstNodeForHide
:
function
(
setting
,
nodes
)
{
var
n
,
i
,
j
;
for
(
i
=
0
,
j
=
nodes
.
length
;
i
<
j
;
i
++
)
{
n
=
nodes
[
i
];
if
(
n
.
isFirstNode
)
{
break
;
}
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
!
isHidden
&&
!
n
.
isFirstNode
)
{
n
.
isFirstNode
=
true
;
view
.
setNodeLineIcos
(
setting
,
n
);
break
;
}
else
{
n
=
null
;
}
}
return
n
;
},
setFirstNodeForShow
:
function
(
setting
,
nodes
)
{
var
n
,
i
,
j
,
first
,
old
;
for
(
i
=
0
,
j
=
nodes
.
length
;
i
<
j
;
i
++
)
{
n
=
nodes
[
i
];
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
!
first
&&
!
isHidden
&&
n
.
isFirstNode
)
{
first
=
n
;
break
;
}
else
if
(
!
first
&&
!
isHidden
&&
!
n
.
isFirstNode
)
{
n
.
isFirstNode
=
true
;
first
=
n
;
view
.
setNodeLineIcos
(
setting
,
n
);
}
else
if
(
first
&&
n
.
isFirstNode
)
{
n
.
isFirstNode
=
false
;
old
=
n
;
view
.
setNodeLineIcos
(
setting
,
n
);
break
;
}
else
{
n
=
null
;
}
}
return
{
"new"
:
first
,
"old"
:
old
};
},
setLastNodeForHide
:
function
(
setting
,
nodes
)
{
var
n
,
i
;
for
(
i
=
nodes
.
length
-
1
;
i
>=
0
;
i
--
)
{
n
=
nodes
[
i
];
if
(
n
.
isLastNode
)
{
break
;
}
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
!
isHidden
&&
!
n
.
isLastNode
)
{
n
.
isLastNode
=
true
;
view
.
setNodeLineIcos
(
setting
,
n
);
break
;
}
else
{
n
=
null
;
}
}
return
n
;
},
setLastNodeForShow
:
function
(
setting
,
nodes
)
{
var
n
,
i
,
j
,
last
,
old
;
for
(
i
=
nodes
.
length
-
1
;
i
>=
0
;
i
--
)
{
n
=
nodes
[
i
];
var
isHidden
=
data
.
isHidden
(
setting
,
n
);
if
(
!
last
&&
!
isHidden
&&
n
.
isLastNode
)
{
last
=
n
;
break
;
}
else
if
(
!
last
&&
!
isHidden
&&
!
n
.
isLastNode
)
{
n
.
isLastNode
=
true
;
last
=
n
;
view
.
setNodeLineIcos
(
setting
,
n
);
}
else
if
(
last
&&
n
.
isLastNode
)
{
n
.
isLastNode
=
false
;
old
=
n
;
view
.
setNodeLineIcos
(
setting
,
n
);
break
;
}
else
{
n
=
null
;
}
}
return
{
"new"
:
last
,
"old"
:
old
};
}
},
_z
=
{
view
:
_view
,
data
:
_data
};
$
.
extend
(
true
,
$
.
fn
.
zTree
.
_z
,
_z
);
var
zt
=
$
.
fn
.
zTree
,
tools
=
zt
.
_z
.
tools
,
consts
=
zt
.
consts
,
view
=
zt
.
_z
.
view
,
data
=
zt
.
_z
.
data
,
event
=
zt
.
_z
.
event
,
$$
=
tools
.
$
;
data
.
isHidden
=
function
(
setting
,
node
,
newIsHidden
)
{
if
(
!
node
)
{
return
false
;
}
var
key
=
setting
.
data
.
key
.
isHidden
;
if
(
typeof
newIsHidden
!==
'undefined'
)
{
if
(
typeof
newIsHidden
===
"string"
)
{
newIsHidden
=
tools
.
eqs
(
newIsHidden
,
"true"
);
}
newIsHidden
=
!!
newIsHidden
;
node
[
key
]
=
newIsHidden
;
}
else
if
(
typeof
node
[
key
]
==
"string"
){
node
[
key
]
=
tools
.
eqs
(
node
[
key
],
"true"
);
}
else
{
node
[
key
]
=
!!
node
[
key
];
}
return
node
[
key
];
};
data
.
exSetting
(
_setting
);
data
.
addInitNode
(
_initNode
);
data
.
addBeforeA
(
_beforeA
);
data
.
addZTreeTools
(
_zTreeTools
);
// Override method in core
var
_dInitNode
=
data
.
initNode
;
data
.
initNode
=
function
(
setting
,
level
,
node
,
parentNode
,
isFirstNode
,
isLastNode
,
openFlag
)
{
var
tmpPNode
=
(
parentNode
)
?
parentNode
:
data
.
getRoot
(
setting
),
children
=
tmpPNode
[
setting
.
data
.
key
.
children
];
data
.
tmpHideFirstNode
=
view
.
setFirstNodeForHide
(
setting
,
children
);
data
.
tmpHideLastNode
=
view
.
setLastNodeForHide
(
setting
,
children
);
if
(
openFlag
)
{
view
.
setNodeLineIcos
(
setting
,
data
.
tmpHideFirstNode
);
view
.
setNodeLineIcos
(
setting
,
data
.
tmpHideLastNode
);
}
isFirstNode
=
(
data
.
tmpHideFirstNode
===
node
);
isLastNode
=
(
data
.
tmpHideLastNode
===
node
);
if
(
_dInitNode
)
_dInitNode
.
apply
(
data
,
arguments
);
if
(
openFlag
&&
isLastNode
)
{
view
.
clearOldLastNode
(
setting
,
node
,
openFlag
);
}
};
var
_makeChkFlag
=
data
.
makeChkFlag
;
if
(
!!
_makeChkFlag
)
{
data
.
makeChkFlag
=
function
(
setting
,
node
)
{
if
(
!!
node
&&
!!
data
.
isHidden
(
setting
,
node
))
{
return
;
}
_makeChkFlag
.
apply
(
data
,
arguments
);
}
}
var
_getTreeCheckedNodes
=
data
.
getTreeCheckedNodes
;
if
(
!!
_getTreeCheckedNodes
)
{
data
.
getTreeCheckedNodes
=
function
(
setting
,
nodes
,
checked
,
results
)
{
if
(
!!
nodes
&&
nodes
.
length
>
0
)
{
var
p
=
nodes
[
0
].
getParentNode
();
if
(
!!
p
&&
!!
data
.
isHidden
(
setting
,
p
))
{
return
[];
}
}
return
_getTreeCheckedNodes
.
apply
(
data
,
arguments
);
}
}
var
_getTreeChangeCheckedNodes
=
data
.
getTreeChangeCheckedNodes
;
if
(
!!
_getTreeChangeCheckedNodes
)
{
data
.
getTreeChangeCheckedNodes
=
function
(
setting
,
nodes
,
results
)
{
if
(
!!
nodes
&&
nodes
.
length
>
0
)
{
var
p
=
nodes
[
0
].
getParentNode
();
if
(
!!
p
&&
!!
data
.
isHidden
(
setting
,
p
))
{
return
[];
}
}
return
_getTreeChangeCheckedNodes
.
apply
(
data
,
arguments
);
}
}
var
_expandCollapseSonNode
=
view
.
expandCollapseSonNode
;
if
(
!!
_expandCollapseSonNode
)
{
view
.
expandCollapseSonNode
=
function
(
setting
,
node
,
expandFlag
,
animateFlag
,
callback
)
{
if
(
!!
node
&&
!!
data
.
isHidden
(
setting
,
node
))
{
return
;
}
_expandCollapseSonNode
.
apply
(
view
,
arguments
);
}
}
var
_setSonNodeCheckBox
=
view
.
setSonNodeCheckBox
;
if
(
!!
_setSonNodeCheckBox
)
{
view
.
setSonNodeCheckBox
=
function
(
setting
,
node
,
value
,
srcNode
)
{
if
(
!!
node
&&
!!
data
.
isHidden
(
setting
,
node
))
{
return
;
}
_setSonNodeCheckBox
.
apply
(
view
,
arguments
);
}
}
var
_repairParentChkClassWithSelf
=
view
.
repairParentChkClassWithSelf
;
if
(
!!
_repairParentChkClassWithSelf
)
{
view
.
repairParentChkClassWithSelf
=
function
(
setting
,
node
)
{
if
(
!!
node
&&
!!
data
.
isHidden
(
setting
,
node
))
{
return
;
}
_repairParentChkClassWithSelf
.
apply
(
view
,
arguments
);
}
}
})(
layui
.
$
);
exports
(
'ztree'
,
layui
.
$
.
fn
.
zTree
)
exports
(
'ztree'
,
layui
.
$
.
fn
.
zTree
)
})
})
login.html
View file @
b68230a
...
@@ -66,6 +66,7 @@
...
@@ -66,6 +66,7 @@
if
(
result
.
code
==
'0'
)
{
if
(
result
.
code
==
'0'
)
{
var
sessionId
=
result
.
data
.
sessionId
var
sessionId
=
result
.
data
.
sessionId
helper
.
store
.
set
(
'token'
,
sessionId
)
helper
.
store
.
set
(
'token'
,
sessionId
)
helper
.
store
.
set
(
'user'
,
result
.
data
)
go
(
'merchant'
,
'index'
)
go
(
'merchant'
,
'index'
)
}
}
})
})
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment