Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Element
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林焕东
Element
Commits
cdb5d45d
Commit
cdb5d45d
authored
Jan 23, 2019
by
曹磊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Table: fixed show-summary issue when multilevel header has fixed attr(#13914)
parent
653f0d4c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
4 deletions
+14
-4
packages/table/src/table-footer.js
packages/table/src/table-footer.js
+14
-4
No files found.
packages/table/src/table-footer.js
View file @
cdb5d45d
...
...
@@ -62,7 +62,7 @@ export default {
<
td
colspan
=
{
column
.
colSpan
}
rowspan
=
{
column
.
rowSpan
}
class
=
{
[
column
.
id
,
column
.
headerAlign
,
column
.
className
||
''
,
this
.
isCellHidden
(
cellIndex
,
this
.
columns
)
?
'
is-hidden
'
:
''
,
!
column
.
children
?
'
is-leaf
'
:
''
,
column
.
labelClassName
]
}
>
class
=
{
[
column
.
id
,
column
.
headerAlign
,
column
.
className
||
''
,
this
.
isCellHidden
(
cellIndex
,
this
.
columns
,
column
)
?
'
is-hidden
'
:
''
,
!
column
.
children
?
'
is-leaf
'
:
''
,
column
.
labelClassName
]
}
>
<
div
class
=
{
[
'
cell
'
,
column
.
labelClassName
]
}
>
{
sums
[
cellIndex
]
...
...
@@ -116,6 +116,14 @@ export default {
return
this
.
store
.
states
.
fixedColumns
.
length
;
},
leftFixedLeafCount
()
{
return
this
.
store
.
states
.
fixedLeafColumnsLength
;
},
rightFixedLeafCount
()
{
return
this
.
store
.
states
.
rightFixedLeafColumnsLength
;
},
rightFixedCount
()
{
return
this
.
store
.
states
.
rightFixedColumns
.
length
;
},
...
...
@@ -130,15 +138,17 @@ export default {
},
methods
:
{
isCellHidden
(
index
,
columns
)
{
isCellHidden
(
index
,
columns
,
column
)
{
if
(
this
.
fixed
===
true
||
this
.
fixed
===
'
left
'
)
{
return
index
>=
this
.
leftFixedCount
;
return
index
>=
this
.
leftFixed
Leaf
Count
;
}
else
if
(
this
.
fixed
===
'
right
'
)
{
let
before
=
0
;
for
(
let
i
=
0
;
i
<
index
;
i
++
)
{
before
+=
columns
[
i
].
colSpan
;
}
return
before
<
this
.
columnsCount
-
this
.
rightFixedCount
;
return
before
<
this
.
columnsCount
-
this
.
rightFixedLeafCount
;
}
else
if
(
!
this
.
fixed
&&
column
.
fixed
)
{
// hide cell when footer instance is not fixed and column is fixed
return
true
;
}
else
{
return
(
index
<
this
.
leftFixedCount
)
||
(
index
>=
this
.
columnsCount
-
this
.
rightFixedCount
);
}
...
...
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