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
Tristan Cavelier
erp5
Commits
42fef3a8
Commit
42fef3a8
authored
Feb 14, 2019
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_render_ui] Allow any external app to download the source code
parent
a5bd823c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
0 deletions
+9
-0
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/File_viewAsWeb.py
...eItem/portal_skins/erp5_web_renderjs_ui/File_viewAsWeb.py
+3
-0
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/Image_viewAsWeb.py
...Item/portal_skins/erp5_web_renderjs_ui/Image_viewAsWeb.py
+3
-0
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/WebPage_viewAsWeb.py
...em/portal_skins/erp5_web_renderjs_ui/WebPage_viewAsWeb.py
+3
-0
No files found.
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/File_viewAsWeb.py
View file @
42fef3a8
...
...
@@ -9,6 +9,9 @@ file_content = file.getData()
# The vanilla HTML is wanted
response
.
setBase
(
None
)
# Allow any external app to download the source code
response
.
setHeader
(
"Access-Control-Allow-Origin"
,
"*"
)
if
REQUEST
.
getHeader
(
'If-Modified-Since'
,
''
)
==
file
.
getModificationDate
().
rfc822
():
response
.
setStatus
(
304
)
return
""
...
...
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/Image_viewAsWeb.py
View file @
42fef3a8
...
...
@@ -6,6 +6,9 @@ if response is None:
# The vanilla HTML is wanted
response
.
setBase
(
None
)
# Allow any external app to download the source code
response
.
setHeader
(
"Access-Control-Allow-Origin"
,
"*"
)
image
=
context
if
REQUEST
.
getHeader
(
'If-Modified-Since'
,
''
)
==
image
.
getModificationDate
().
rfc822
():
response
.
setStatus
(
304
)
...
...
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs_ui/WebPage_viewAsWeb.py
View file @
42fef3a8
...
...
@@ -6,6 +6,9 @@ if response is None:
# The vanilla HTML is wanted
response
.
setBase
(
None
)
# Allow any external app to download the source code
response
.
setHeader
(
"Access-Control-Allow-Origin"
,
"*"
)
web_page
=
context
web_section
=
REQUEST
.
get
(
"current_web_section"
)
if
web_section
is
None
:
...
...
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