Commit 6daa6bda authored by Vincent Bechu's avatar Vincent Bechu Committed by Eteri

erp5_officejs: fix local storage for source code

parent d60c15be
......@@ -26,7 +26,7 @@ var repair = false;
check_local_modification: false,
signature_storage: {
type: "indexeddb",
database: "installer_hash"
database: window.location.pathname + version_url + "_hash"
},
local_sub_storage: {
type: "query",
......@@ -34,7 +34,8 @@ var repair = false;
type: "uuid",
sub_storage: {
type: "indexeddb",
database: "officejs_code_source"
database: window.location.origin + window.location.pathname +
version_url
}
}
},
......
......@@ -236,7 +236,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>958.64411.34322.58368</string> </value>
<value> <string>960.4200.19356.54459</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -254,7 +254,7 @@
</tuple>
<state>
<tuple>
<float>1493803864.07</float>
<float>1497535303.22</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -39,13 +39,13 @@ var global = self, window = self;
.replace(self.registration.scope, "")
.replace(self.version_url, "");
if (relative_url === "") {
relative_url = self.registration.scope;
relative_url = "/";
}
event.respondWith(
new self.RSVP.Queue()
.push(function () {
if (self.storage.get === undefined) {
self.storage = createStorage("officejs_code_source");
self.storage = createStorage(self.registration.scope);
}
return self.storage.getAttachment("/", relative_url)
.push(function (blob) {
......
......@@ -227,7 +227,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>959.27737.62903.2116</string> </value>
<value> <string>960.4199.25759.2730</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -245,7 +245,7 @@
</tuple>
<state>
<tuple>
<float>1497359632.58</float>
<float>1497613210.46</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