Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fgqyxxlr
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
yaru
fgqyxxlr
Commits
d93e43cc
Commit
d93e43cc
authored
Jan 03, 2020
by
RuoYi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
表格树父节点兼容0,'0','',null
parent
47f007ba
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
ruoyi-admin/src/main/resources/static/ajax/libs/bootstrap-treetable/bootstrap-treetable.js
+6
-2
No files found.
ruoyi-admin/src/main/resources/static/ajax/libs/bootstrap-treetable/bootstrap-treetable.js
View file @
d93e43cc
...
...
@@ -252,8 +252,12 @@
$
.
each
(
data
,
function
(
index
,
item
)
{
// 添加一个默认属性,用来判断当前节点有没有被显示
item
.
isShow
=
false
;
// 顶级节点校验判断
var
_defaultRootFlag
=
$
.
inArray
(
item
[
options
.
code
],
parentCodes
)
>
0
&&
!
rootFlag
;
// 顶级节点校验判断,兼容0,'0','',null
var
_defaultRootFlag
=
item
[
options
.
parentCode
]
==
'0'
||
item
[
options
.
parentCode
]
==
0
||
item
[
options
.
parentCode
]
==
null
||
item
[
options
.
parentCode
]
==
''
||
$
.
inArray
(
item
[
options
.
code
],
parentCodes
)
>
0
&&
!
rootFlag
;
if
(
!
item
[
options
.
parentCode
]
||
(
_root
?
(
item
[
options
.
parentCode
]
==
options
.
rootIdValue
)
:
_defaultRootFlag
))
{
rootFlag
=
true
;
if
(
!
target
.
data_list
[
"_root_"
])
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment