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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
erp5
Commits
97891b1a
Commit
97891b1a
authored
Aug 07, 2020
by
Roque
Browse files
Options
Browse Files
Download
Plain Diff
Erp5 officejs fix cache
See merge request
!1227
parents
410744dc
2e547774
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
1870 additions
and
22 deletions
+1870
-22
bt5/erp5_gadget_interface_validator/PathTemplateItem/web_page_module/gadget_interface_validator_jio_js.js
...Item/web_page_module/gadget_interface_validator_jio_js.js
+1
-1
bt5/erp5_gadget_interface_validator/PathTemplateItem/web_page_module/gadget_interface_validator_jio_js.xml
...tem/web_page_module/gadget_interface_validator_jio_js.xml
+2
-2
bt5/erp5_gadget_interface_validator_ui_test/SkinTemplateItem/portal_skins/erp5_gadget_interface_validator_ui_test/WebSection_getInterfaceValidatorTestPrecacheManifest.py
...t/WebSection_getInterfaceValidatorTestPrecacheManifest.py
+5
-1
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_jio_precachestorage_js.js
...web_page_module/gadget_officejs_jio_precachestorage_js.js
+2
-4
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_jio_precachestorage_js.xml
...eb_page_module/gadget_officejs_jio_precachestorage_js.xml
+1855
-2
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs/WebSection_getPrecacheManifest.py
...skins/erp5_web_renderjs/WebSection_getPrecacheManifest.py
+5
-12
No files found.
bt5/erp5_gadget_interface_validator/PathTemplateItem/web_page_module/gadget_interface_validator_jio_js.js
View file @
97891b1a
...
...
@@ -22,7 +22,7 @@
})
.
push
(
function
(
evt
)
{
var
key
,
precache_dict
=
evt
.
target
.
response
,
precache_dict
=
evt
.
target
.
response
.
url_dict
,
result_list
=
[],
precache_absolute_url
=
(
new
URL
(
precache_url
,
window
.
location
)).
href
;
for
(
key
in
precache_dict
)
{
...
...
bt5/erp5_gadget_interface_validator/PathTemplateItem/web_page_module/gadget_interface_validator_jio_js.xml
View file @
97891b1a
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
98
1.51931.38103.24746
</string>
</value>
<value>
<string>
98
5.49101.35647.15445
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
15
81590120.37
</float>
<float>
15
96722312.92
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_gadget_interface_validator_ui_test/SkinTemplateItem/portal_skins/erp5_gadget_interface_validator_ui_test/WebSection_getInterfaceValidatorTestPrecacheManifest.py
View file @
97891b1a
...
...
@@ -22,7 +22,11 @@ url_list = [
if
REQUEST
is
not
None
:
import
json
manifest_dict
=
{
'url_dict'
:
dict
.
fromkeys
(
url_list
),
'modification_date'
:
context
.
getModificationDate
().
rfc822
()
}
REQUEST
.
RESPONSE
.
setHeader
(
'Content-Type'
,
'application/json'
)
return
json
.
dumps
(
dict
.
fromkeys
(
url_list
)
,
indent
=
2
)
return
json
.
dumps
(
manifest_dict
,
indent
=
2
)
return
url_list
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_jio_precachestorage_js.js
View file @
97891b1a
...
...
@@ -101,10 +101,8 @@
var
base_manifest_text
=
response
.
target
.
responseText
,
relative_url_list
,
i
,
hash
=
rusha
.
digestFromString
(
base_manifest_text
+
response
.
target
.
getResponseHeader
(
"
ETag
"
));
relative_url_list
=
Object
.
keys
(
JSON
.
parse
(
base_manifest_text
));
hash
=
rusha
.
digestFromString
(
base_manifest_text
);
relative_url_list
=
Object
.
keys
(
JSON
.
parse
(
base_manifest_text
).
url_dict
);
storage
.
_relative_url_list
.
push
(
storage
.
_version
);
storage
.
_relative_url_list
.
push
(
storage
.
_version
+
storage
.
_precache_manifest_script
);
...
...
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_jio_precachestorage_js.xml
View file @
97891b1a
This source diff could not be displayed because it is too large. You can
view the blob
instead.
bt5/erp5_web_renderjs_ui/SkinTemplateItem/portal_skins/erp5_web_renderjs/WebSection_getPrecacheManifest.py
View file @
97891b1a
web_section
=
context
if
REQUEST
is
not
None
:
modification_date_string
=
web_section
.
getModificationDate
().
rfc822
()
weak_etag_header
=
'W/"%s"'
%
modification_date_string
REQUEST
.
RESPONSE
.
setHeader
(
'ETag'
,
weak_etag_header
)
if_none_match
=
REQUEST
.
getHeader
(
'If-None-Match'
,
''
)
#using 'in' instead of '==' because the header value may contain a suffix
#for the server HTTP compression. e.g. "-gzip" suffix for DeflateAlterETag on apache
if
weak_etag_header
[:
-
1
]
in
if_none_match
:
REQUEST
.
RESPONSE
.
setStatus
(
304
)
return
""
# Add all ERP5JS gadget
url_list
=
[
'favicon.ico'
,
...
...
@@ -197,7 +186,11 @@ for precache_manifest_script_id in precache_manifest_url_list:
if
REQUEST
is
not
None
:
import
json
manifest_dict
=
{
'url_dict'
:
dict
.
fromkeys
(
url_list
),
'modification_date'
:
context
.
getModificationDate
().
rfc822
()
}
REQUEST
.
RESPONSE
.
setHeader
(
'Content-Type'
,
'application/json'
)
return
json
.
dumps
(
dict
.
fromkeys
(
url_list
)
,
indent
=
2
)
return
json
.
dumps
(
manifest_dict
,
indent
=
2
)
return
list
(
set
(
url_list
))
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