Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
lib
unicaen
app
Commits
3c670f5f
Commit
3c670f5f
authored
May 28, 2020
by
Jean-Philippe Metivier
Browse files
Ajout des scriptVars dans les scripts des hearders et du footer
parent
a0a0cde0
Pipeline
#9654
failed with stage
in 12 seconds
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
src/UnicaenApp/Exporter/Pdf.php
View file @
3c670f5f
...
@@ -401,6 +401,7 @@ class Pdf implements ExporterInterface
...
@@ -401,6 +401,7 @@ class Pdf implements ExporterInterface
'headerTitle'
=>
$this
->
headerTitle
,
'headerTitle'
=>
$this
->
headerTitle
,
'headerSubtitle'
=>
$this
->
headerSubtitle
,
'headerSubtitle'
=>
$this
->
headerSubtitle
,
'logo'
=>
$this
->
logo
);
'logo'
=>
$this
->
logo
);
$scriptVars
=
array_merge
(
$scriptVars
,
current
(
$this
->
scriptVars
));
// le logo doit être passé ainsi pour pouvoir être référencé dans la balise <img> sous la forme "var:logo"
// le logo doit être passé ainsi pour pouvoir être référencé dans la balise <img> sous la forme "var:logo"
$this
->
getMpdf
()
->
logo
=
$this
->
logo
;
$this
->
getMpdf
()
->
logo
=
$this
->
logo
;
...
@@ -492,6 +493,7 @@ class Pdf implements ExporterInterface
...
@@ -492,6 +493,7 @@ class Pdf implements ExporterInterface
$scriptVars
=
array
(
$scriptVars
=
array
(
'footerTitle'
=>
$this
->
footerTitle
);
'footerTitle'
=>
$this
->
footerTitle
);
$scriptVars
=
array_merge
(
$scriptVars
,
current
(
$this
->
scriptVars
));
if
(
isset
(
$this
->
footerScripts
[
'O'
]))
{
if
(
isset
(
$this
->
footerScripts
[
'O'
]))
{
$footerOdd
=
$this
->
getRenderer
()
->
render
(
$this
->
footerScripts
[
'O'
],
$scriptVars
);
$footerOdd
=
$this
->
getRenderer
()
->
render
(
$this
->
footerScripts
[
'O'
],
$scriptVars
);
...
...
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