Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Nicolas Wavrant
erp5
Commits
9f8dd82c
Commit
9f8dd82c
authored
Sep 05, 2019
by
Yusei Tahara
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Use absolute wallpaper image URL to support firefox.
parent
70cf895f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/WebSection_renderDefaultPageAsGadget.py
...5_web_renderjs_ui/WebSection_renderDefaultPageAsGadget.py
+6
-1
No files found.
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/WebSection_renderDefaultPageAsGadget.py
View file @
9f8dd82c
import
json
import
re
import
urlparse
if
REQUEST
is
None
:
REQUEST
=
context
.
REQUEST
...
...
@@ -73,6 +74,10 @@ wallpaper_url = web_section.getLayoutProperty("configuration_wallpaper_url", def
if
wallpaper_url
is
None
:
mapping_dict
[
"extra_css_full_link_tag"
]
=
''
else
:
if
not
urlparse
.
urlparse
(
wallpaper_url
).
scheme
:
wallpaper_absolute_url
=
urlparse
.
urljoin
(
root_website_url
+
'/'
,
wallpaper_url
);
else
:
wallpaper_absolute_url
=
wallpaper_url
from
base64
import
urlsafe_b64encode
mapping_dict
[
"extra_css_full_link_tag"
]
=
'<link rel="stylesheet" href="data:text/css;base64,%s">'
%
urlsafe_b64encode
(
"""
html::after {
...
...
@@ -89,6 +94,6 @@ else:
background-attachment: fixed;
background-image: url("%s");
}
"""
%
wallpaper_url
);
"""
%
wallpaper_
absolute_
url
);
return
view_as_web_method
(
mapping_dict
=
mapping_dict
)
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