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 ccf3bde3
authored
Aug 21, 2021
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
提交员工
1 parent
5e927a51
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
16 deletions
html/employee/add.html
html/employee/add.html
View file @
ccf3bde
...
...
@@ -206,13 +206,6 @@
var
visibleMerchant
=
{}
pwd
.
attr
(
'readonly'
,
false
)
// 判断是否是编辑
if
(
id
)
{
resetpsw
.
removeClass
(
'hide'
)
resetpsw
.
addClass
(
'show'
)
merchantId
=
qs
(
'merchantId'
)
getList
(
merchantId
)
}
// 判断是从商户过来还是员工
if
(
qs
(
'channel'
))
{
getList
(
qs
(
'merchantId'
))
...
...
@@ -223,6 +216,13 @@
}
else
{
var
str
=
'<div id="merchantSelect" class="hide"><select id="merchantName" name="merchantId" lay-filter="merchants" lay-verify="required" autocomplete="off" placeholder="请选择商户名称" required></select></div>'
$
(
'#merchantBox'
).
append
(
str
)
if
(
qs
(
'id'
))
{
// 判断是否是编辑
resetpsw
.
removeClass
(
'hide'
)
resetpsw
.
addClass
(
'show'
)
merchantId
=
qs
(
'merchantId'
)
getList
(
qs
(
'merchantId'
))
}
findAllMerchant
()
$
(
'#merchantSelect'
).
removeClass
(
'hide'
)
$
(
'#merchantSelect'
).
addClass
(
'show'
)
...
...
@@ -309,7 +309,7 @@
layer
.
msg
(
'操作成功'
,
{
icon
:
1
})
//
window.history.back()
window
.
history
.
back
()
}
})
return
false
...
...
@@ -342,22 +342,16 @@
if
(
id
)
{
getById
(
function
(
checkedList
)
{
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
,
{
checkedList
:
checkedList
})
// var node = visibleMerchant.getNodesByParam('id', merchantId)
// visibleMerchant.checkNode(node, true, true)
visibleMerchant
.
checkNodes
(
checkedList
)
all_nodes
=
visibleMerchant
.
transformToArray
(
visibleMerchant
.
getNodes
())
bindEvent
()
})
}
else
{
console
.
log
(
11
)
const
arr
=
[]
arr
.
push
(
+
merchantId
)
visibleMerchant
=
tree
.
create
(
'visibleInferiorMerTree'
,
res
.
data
,
{
checkedList
:
arr
})
var
node
=
visibleMerchant
.
getNodesByParam
(
'id'
,
merchantId
)
console
.
log
(
node
,
visibleMerchant
)
// node.checked = true
// visibleMerchant.checkNode(node, true, true)
// visibleMerchant.updateNode(node)
visibleMerchant
.
checkNodes
(
arr
)
all_nodes
=
visibleMerchant
.
transformToArray
(
visibleMerchant
.
getNodes
())
bindEvent
()
}
...
...
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