Ability to force the version of onlyoffice
This commit is contained in:
parent
746b382166
commit
ad8bf87c3f
@ -81,7 +81,7 @@ define([
|
||||
hashes: {},
|
||||
ids: {},
|
||||
mediasSources: {},
|
||||
version: NEW_VERSION
|
||||
version: privateData.ooForceVersion ? Number(privateData.ooForceVersion) : NEW_VERSION
|
||||
};
|
||||
var oldHashes = {};
|
||||
var oldIds = {};
|
||||
@ -1437,7 +1437,11 @@ define([
|
||||
|
||||
var version = '';
|
||||
// Old version detected: use the old OO and start the migration if we can
|
||||
if (content && !content.version) {
|
||||
if (privateData.ooForceVersion) {
|
||||
if (privateData.ooForceVersion === "1") {
|
||||
version = "v1/";
|
||||
}
|
||||
} else if (content && (!content.version || content.version === 1)) {
|
||||
version = 'v1/';
|
||||
APP.migrate = true;
|
||||
// Registedred users can start the migration
|
||||
|
||||
@ -38,6 +38,7 @@ define([
|
||||
}).nThen(function (/*waitFor*/) {
|
||||
var addData = function (obj) {
|
||||
obj.ooType = window.location.pathname.replace(/^\//, '').replace(/\/$/, '');
|
||||
obj.ooForceVersion = localStorage.CryptPad_ooVersion || sessionStorage.CryptPad_ooVersion || "";
|
||||
};
|
||||
var addRpc = function (sframeChan, Cryptpad, Utils) {
|
||||
sframeChan.on('Q_OO_SAVE', function (data, cb) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user