Commit ed1e1e5a authored by Roque's avatar Roque

erp5_officejs: new parameter appcache in hateoas script

- this new parameter disable permission check when hateoas is called by bootloader
- appcache storage sync is canceled if storage requires authentication
- WIP: redirect to login not working
parent 32a029cf
......@@ -239,7 +239,7 @@ officejs_logo.png\n
jio_appcachestorage.js\n
\n
#configuration resources\n
hateoas/ERP5Document_getHateoas?mode=traverse&relative_url=portal_skins%2Ferp5_officejs_jio_connector%2FHTMLPost_viewAsJio&view=jio_view\n
hateoas/ERP5Document_getHateoas?mode=traverse&relative_url=portal_skins%2Ferp5_officejs_jio_connector%2FHTMLPost_viewAsJio&view=jio_view&appcache=1\n
\n
gadget_erp5_page_ojs_controller.html\n
gadget_erp5_page_ojs_controller.js\n
......@@ -733,7 +733,7 @@ NETWORK:\n
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>974.28784.24754.58845</string> </value>
<value> <string>974.29872.42985.19473</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -751,7 +751,7 @@ NETWORK:\n
</tuple>
<state>
<tuple>
<float>1552947714.61</float>
<float>1553006152.79</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -116,7 +116,7 @@ CACHE MANIFEST\n
CACHE:\n
\n
#discussion tool\n
hateoas/ERP5Document_getHateoas?mode=traverse&relative_url=portal_skins%2Ferp5_officejs_jio_connector%2FHTMLPost_viewAsJio&view=jio_view\n
hateoas/ERP5Document_getHateoas?mode=traverse&relative_url=portal_skins%2Ferp5_officejs_jio_connector%2FHTMLPost_viewAsJio&view=jio_view&appcache=1\n
\n
NETWORK:\n
*
......@@ -262,7 +262,7 @@ NETWORK:\n
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>974.28632.10387.52002</string> </value>
<value> <string>974.29872.40794.13499</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -280,7 +280,7 @@ NETWORK:\n
</tuple>
<state>
<tuple>
<float>1552929997.96</float>
<float>1553006157.09</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -171,6 +171,10 @@
});
}, function (error) {
console.log("Error while appcache-local storage synchronization");
if (error.currentTarget.status == "401") {
console.log("Unauthorized access to storage, sync cancelled");
return;
}
throw error;
});
});
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>974.29065.11280.57736</string> </value>
<value> <string>974.29947.29457.36147</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1552954433.8</float>
<float>1553007300.28</float>
<string>UTC</string>
</tuple>
</state>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment