Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
tev
plugin_event
Commits
54a90b6b
Commit
54a90b6b
authored
Nov 03, 2016
by
LE GAC Renaud
Browse files
Update views/report/grid to remove hack for ExtJS 6.0.1 and to remove pMathJax.
parent
8efb6798
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
19 deletions
+9
-19
views/report/grid.html
views/report/grid.html
+9
-19
No files found.
views/report/grid.html
View file @
54a90b6b
...
...
@@ -83,24 +83,6 @@
nColumns
=
columns
.
length
,
i
,
grid
;
// backward compatibility
// Ext JS 4.2.1 the width of the column is defined using the property flex
// Ext JS 6.0.1 this cause crash of the grid when a hidden column is activated
// The workaround is to destroy the flex property and to use the
// columnWidth instead. the latter is a percentage ranging from 0 to 1.
//
for
(
i
=
0
;
i
<
nColumns
;
i
+=
1
)
{
column
=
columns
[
i
];
if
(
column
.
flex
!==
undefined
&&
column
.
columnWidth
===
undefined
)
{
if
(
column
.
flex
<=
1
)
{
column
.
columnWidth
=
column
.
flex
*
0.1
;
}
else
{
column
.
columnWidth
=
1
;
}
}
delete
column
.
flex
;
}
// convert renderer / summaryRenderer properties
// typicaly a string to a function
//
...
...
@@ -117,9 +99,17 @@
}
// instantiate the grid
// NOTE ExtJS 6.2.0
// With ExtJS 6.2.0, the configuration is not working:
//
// plugins: ['pGridExport', 'pMathJax']
//
// It is related to layout and pMathJax !
// Remove pMathJax since its use is marginal in that application.
cfgGrid
=
Ext
.
apply
(
cfgGrid
,
{
plugins
:
[
'
pGridExport
'
,
'
pMathJax
'
],
plugins
:
[
'
pGridExport
'
],
store
:
cfgStore
,
forceFit
:
true
,
padding
:
"
10 40 20 30
"
,
...
...
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