From c98e86df324ce9300fec4c51d4d762fcf92e09c2 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 10 Apr 2019 11:58:28 +0300 Subject: [PATCH 01/25] changed sctipt sequence --- controller/editorcontroller.php | 18 ++++++------- js/main.js | 45 +++++++++++++++++++-------------- 2 files changed, 34 insertions(+), 29 deletions(-) diff --git a/controller/editorcontroller.php b/controller/editorcontroller.php index 9f282236..e9651b08 100644 --- a/controller/editorcontroller.php +++ b/controller/editorcontroller.php @@ -485,6 +485,7 @@ public function config($fileId, $filePath = NULL, $token = NULL, $desktop = fals "document" => [ "fileType" => $ext, "key" => DocumentService::GenerateRevisionId($key), + "permissions" => [], "title" => $fileName, "url" => $fileUrl, ], @@ -494,8 +495,9 @@ public function config($fileId, $filePath = NULL, $token = NULL, $desktop = fals ] ]; - if (\OC::$server->getRequest()->isUserAgent([$this::USER_AGENT_MOBILE])) { - $params["type"] = "mobile"; + $permissions_modifyFilter = $this->config->getSystemValue($this->config->_permissions_modifyFilter); + if (isset($permissions_modifyFilter)) { + $params["document"]["permissions"]["modifyFilter"] = $permissions_modifyFilter; } $canEdit = isset($format["edit"]) && $format["edit"]; @@ -520,6 +522,10 @@ public function config($fileId, $filePath = NULL, $token = NULL, $desktop = fals $params["editorConfig"]["mode"] = "view"; } + if (\OC::$server->getRequest()->isUserAgent([$this::USER_AGENT_MOBILE])) { + $params["type"] = "mobile"; + } + if (!empty($userId)) { $params["editorConfig"]["user"] = [ "id" => $userId, @@ -576,14 +582,6 @@ public function config($fileId, $filePath = NULL, $token = NULL, $desktop = fals $params = $this->setCustomization($params); - $permissions_modifyFilter = $this->config->getSystemValue($this->config->_permissions_modifyFilter); - if (isset($permissions_modifyFilter)) { - if (!array_key_exists("permissions", $params["document"])) { - $params["document"]["permissions"] = []; - } - $params["document"]["permissions"]["modifyFilter"] = $permissions_modifyFilter; - } - if (!empty($this->config->GetDocumentServerSecret())) { $token = \Firebase\JWT\JWT::encode($params, $this->config->GetDocumentServerSecret()); $params["token"] = $token; diff --git a/js/main.js b/js/main.js index 7b3825c0..d964209b 100644 --- a/js/main.js +++ b/js/main.js @@ -168,28 +168,28 @@ var register = function() { var formats = OCA.Onlyoffice.setting.formats; - $.each(formats, function (ext, attr) { - if (!attr.mime) { + $.each(formats, function (ext, config) { + if (!config.mime) { return true; } fileList.fileActions.registerAction({ name: "onlyofficeOpen", displayName: t(OCA.Onlyoffice.AppName, "Open in ONLYOFFICE"), - mime: attr.mime, + mime: config.mime, permissions: OC.PERMISSION_READ, iconClass: "icon-onlyoffice-open", actionHandler: OCA.Onlyoffice.FileClick }); - if (attr.def) { - fileList.fileActions.setDefault(attr.mime, "onlyofficeOpen"); + if (config.def) { + fileList.fileActions.setDefault(config.mime, "onlyofficeOpen"); } - if (attr.conv) { + if (config.conv) { fileList.fileActions.registerAction({ name: "onlyofficeConvert", displayName: t(OCA.Onlyoffice.AppName, "Convert with ONLYOFFICE"), - mime: attr.mime, + mime: config.mime, permissions: ($("#isPublic").val() ? OC.PERMISSION_UPDATE : OC.PERMISSION_READ), iconClass: "icon-onlyoffice-convert", actionHandler: OCA.Onlyoffice.FileConvertClick @@ -245,27 +245,34 @@ } }; - var initPage = function(){ + var getFileExtension = function (fileName) { + var extension = fileName.substr(fileName.lastIndexOf(".") + 1).toLowerCase(); + return extension; + } + + var initPage = function () { if ($("#isPublic").val() === "1" && !$("#filestable").length) { var fileName = $("#filename").val(); - var extension = fileName.substr(fileName.lastIndexOf(".") + 1).toLowerCase(); + var extension = getFileExtension(fileName); var initSharedButton = function() { var formats = OCA.Onlyoffice.setting.formats; - var conf = formats[extension]; - if (conf) { - var button = document.createElement("a"); - button.href = OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/s/" + encodeURIComponent($("#sharingToken").val())); - button.className = "button"; - button.innerText = t(OCA.Onlyoffice.AppName, "Open in ONLYOFFICE") + var config = formats[extension]; + if (!config) { + return; + } - if (!OCA.Onlyoffice.setting.sameTab) { - button.target = "_blank"; - } + var button = document.createElement("a"); + button.href = OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/s/" + encodeURIComponent($("#sharingToken").val())); + button.className = "button"; + button.innerText = t(OCA.Onlyoffice.AppName, "Open in ONLYOFFICE") - $("#preview").append(button); + if (!OCA.Onlyoffice.setting.sameTab) { + button.target = "_blank"; } + + $("#preview").append(button); }; OCA.Onlyoffice.GetSettings(initSharedButton); From 3e7c1a567801a4de832ef427f46c3d5cf6b08834 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Thu, 11 Apr 2019 16:58:24 +0300 Subject: [PATCH 02/25] fix getting domain for desktop --- js/desktop.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/desktop.js b/js/desktop.js index 34433b73..b50c6a7c 100644 --- a/js/desktop.js +++ b/js/desktop.js @@ -37,7 +37,7 @@ OCA.Onlyoffice.Desktop = true; $("html").addClass("AscDesktopEditor"); - var domain = location.href.split(OC.generateUrl(""))[0]; + var domain = new RegExp("^http(s)?:\/\/[^\/]+").exec(location)[0]; var data = { displayName: oc_current_user, From 6d4119e41f75b58b1aa91f1861f9a0feb19fb1c9 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Thu, 11 Apr 2019 16:59:07 +0300 Subject: [PATCH 03/25] fix domain for virtual path --- js/desktop.js | 1 + 1 file changed, 1 insertion(+) diff --git a/js/desktop.js b/js/desktop.js index b50c6a7c..62898977 100644 --- a/js/desktop.js +++ b/js/desktop.js @@ -38,6 +38,7 @@ $("html").addClass("AscDesktopEditor"); var domain = new RegExp("^http(s)?:\/\/[^\/]+").exec(location)[0]; + domain += + OC.getRootPath(); var data = { displayName: oc_current_user, From eaad9afe4036f082667d726dc034a8e8b69edcdf Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Tue, 16 Apr 2019 11:31:38 +0300 Subject: [PATCH 04/25] retrieve file by owner --- controller/callbackcontroller.php | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/controller/callbackcontroller.php b/controller/callbackcontroller.php index dccb139d..58908cab 100644 --- a/controller/callbackcontroller.php +++ b/controller/callbackcontroller.php @@ -373,26 +373,30 @@ public function track($doc, $users, $key, $status, $url, $token) { } try { + $ownerId = $hashData->ownerId; + $token = isset($hashData->token) ? $hashData->token : NULL; + if (empty($ownerId) && empty($token)) { + $this->logger->error("Track without owner: " . $fileId . " status " . $trackerStatus, array("app" => $this->appName)); + return new JSONResponse(["message" => $this->trans->t("File owner is empty")], Http::STATUS_BAD_REQUEST); + } + $userId = $users[0]; $user = $this->userManager->get($userId); if (!empty($user)) { - \OC_Util::tearDownFS(); - \OC_Util::setupFS($userId); - $this->userSession->setUser($user); } else { - $ownerId = $hashData->ownerId; + $this->logger->debug("Track by anonymous " . $userId, array("app" => $this->appName)); + } - \OC_Util::tearDownFS(); - if (!empty($ownerId)) { - \OC_Util::setupFS($ownerId); - } + \OC_Util::tearDownFS(); + if (!empty($ownerId)) { + \OC_Util::setupFS($ownerId); } - $token = isset($hashData->token) ? $hashData->token : NULL; - list ($file, $error) = empty($token) ? $this->getFile($userId, $fileId) : $this->getFileByToken($fileId, $token); + list ($file, $error) = empty($token) ? $this->getFile($ownerId, $fileId) : $this->getFileByToken($fileId, $token); if (isset($error)) { + $this->logger->error("track error" . $fileId ." " . $error, array("app" => $this->appName)); return $error; } @@ -430,6 +434,8 @@ public function track($doc, $users, $key, $status, $url, $token) { } $newData = $documentService->Request($url); + + $this->logger->debug("Track put content " . $file->getPath(), array("app" => $this->appName)); $file->putContent($newData); $error = 0; } catch (\Exception $e) { From f8927c43bcf4c736b21c9a02c2f9a95c9fcd9fec Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Thu, 18 Apr 2019 19:07:17 +0300 Subject: [PATCH 05/25] change title in the convertation request --- lib/documentservice.php | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/lib/documentservice.php b/lib/documentservice.php index ea14002a..25579e11 100644 --- a/lib/documentservice.php +++ b/lib/documentservice.php @@ -118,36 +118,32 @@ function GetConvertedUri($document_uri, $from_extension, $to_extension, $documen * @return array */ function SendRequestToConvertService($document_uri, $from_extension, $to_extension, $document_revision_id, $is_async) { - if (empty($from_extension)) { - $path_parts = pathinfo($document_uri); - $from_extension = $path_parts["extension"]; - } + $documentServerUrl = $this->config->GetDocumentServerInternalUrl(false); - $title = basename($document_uri); - if (empty($title)) { - $title = $document_revision_id . $from_extension; + if (empty($documentServerUrl)) { + throw new \Exception($this->trans->t("ONLYOFFICE app is not configured. Please contact admin")); } + $urlToConverter = $documentServerUrl . "ConvertService.ashx"; + if (empty($document_revision_id)) { $document_revision_id = $document_uri; } $document_revision_id = self::GenerateRevisionId($document_revision_id); - $documentServerUrl = $this->config->GetDocumentServerInternalUrl(false); - - if (empty($documentServerUrl)) { - throw new \Exception($this->trans->t("ONLYOFFICE app is not configured. Please contact admin")); + if (empty($from_extension)) { + $from_extension = pathinfo($document_uri)["extension"]; + } else { + $from_extension = trim($from_extension, "."); } - $urlToConverter = $documentServerUrl . "ConvertService.ashx"; - $data = [ "async" => $is_async, "url" => $document_uri, "outputtype" => trim($to_extension, "."), - "filetype" => trim($from_extension, "."), - "title" => $title, + "filetype" => $from_extension, + "title" => $document_revision_id . "." . $from_extension, "key" => $document_revision_id ]; From 72d5851bc4371919b4d983e3211ff65f7aba0943 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 22 Apr 2019 15:02:27 +0300 Subject: [PATCH 06/25] save after deleting pulbic link --- controller/callbackcontroller.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controller/callbackcontroller.php b/controller/callbackcontroller.php index 58908cab..a6feba30 100644 --- a/controller/callbackcontroller.php +++ b/controller/callbackcontroller.php @@ -393,7 +393,7 @@ public function track($doc, $users, $key, $status, $url, $token) { \OC_Util::setupFS($ownerId); } - list ($file, $error) = empty($token) ? $this->getFile($ownerId, $fileId) : $this->getFileByToken($fileId, $token); + list ($file, $error) = !empty($ownerId) ? $this->getFile($ownerId, $fileId) : $this->getFileByToken($fileId, $token); if (isset($error)) { $this->logger->error("track error" . $fileId ." " . $error, array("app" => $this->appName)); From 4d578fa5ea977cae4c9d4fe0ba756c67815e4b20 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 22 Apr 2019 16:56:11 +0300 Subject: [PATCH 07/25] error type only if error --- js/settings.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/settings.js b/js/settings.js index a8b48cb1..11af5f1d 100644 --- a/js/settings.js +++ b/js/settings.js @@ -117,7 +117,7 @@ ? (t(OCA.Onlyoffice.AppName, "Error when trying to connect") + " (" + response.error + ")") : t(OCA.Onlyoffice.AppName, "Settings have been successfully updated"); OC.Notification.show(message, { - type: "error", + type: response.error ? "error" : null, timeout: 3 }); } From 37255b642b2460914384075658dc3c76559c9330 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 22 Apr 2019 16:22:08 +0300 Subject: [PATCH 08/25] remake settings page --- css/settings.css | 15 +++++++++----- js/settings.js | 4 ++-- templates/settings.php | 47 ++++++++++++++++++++++++++---------------- 3 files changed, 41 insertions(+), 25 deletions(-) diff --git a/css/settings.css b/css/settings.css index ca224136..725b4278 100644 --- a/css/settings.css +++ b/css/settings.css @@ -29,25 +29,30 @@ .section-onlyoffice h2 { display: inline; } +.onlyoffice-error { + color: red; +} .onlyoffice-header { display: inline-block; margin-top: 16px; } .section-onlyoffice input { display: block; - margin: 6px 0 4px; width: 250px; } .onlyoffice-hide { display: none; } -.onlyoffice-link-action { - border-bottom: 1px dotted; +#onlyofficeAdv { cursor: pointer; text-decoration: none; } -.onlyoffice-error { - color: red; +#onlyofficeAdv .icon { + display: inline-block; + margin-bottom: -3px; +} +#s2id_onlyofficeLimitGroups { + margin-bottom: 16px; } .onlyoffice-exts { column-width: 100px; diff --git a/js/settings.js b/js/settings.js index 11af5f1d..8c7d8838 100644 --- a/js/settings.js +++ b/js/settings.js @@ -37,11 +37,11 @@ } var advToogle = function () { - $("#onlyofficeSecretPanel, #onlyofficeSaveBreak").toggleClass("onlyoffice-hide"); + $("#onlyofficeSecretPanel").toggleClass("onlyoffice-hide"); + $("#onlyofficeAdv .icon").toggleClass("icon-triangle-s icon-triangle-n"); }; if ($("#onlyofficeInternalUrl").val().length - || $("#onlyofficeSecret").val().length || $("#onlyofficeStorageUrl").val().length) { advToogle(); } diff --git a/templates/settings.php b/templates/settings.php index b7b567a3..0596810b 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -34,47 +34,55 @@

ONLYOFFICE

"> -

t("ONLYOFFICE Document Service Location specifies the address of the server with the document services installed. Please change the '' for the server address in the below line.")) ?>

+

t("Server settings")) ?>

t("Encryption App is enabled, the application cannot work. You can continue working with the application if you enable master key.")) ?>

+
-

t("Document Editing Service address")) ?>

- " placeholder="https:///" type="text"> +

t("ONLYOFFICE Document Service Location specifies the address of the server with the document services installed. Please change the '' for the server address in the below line.")) ?>

+ +

t("Document Editing Service address")) ?>

+

" placeholder="https:///" type="text">

- t("Advanced server settings")) ?> +

t("Secret key (leave blank to disable)")) ?>

+

" placeholder="secret" type="text">

+ +

+ + t("Advanced server settings")) ?> + + +

t("Document Editing Service address for internal requests from the server")) ?>

- " placeholder="https:///" type="text"> +

" placeholder="https:///" type="text">

t("Server address for internal requests from the Document Editing Service")) ?>

- " placeholder="" type="text"> - -

t("Secret key (leave blank to disable)")) ?>

- " placeholder="secret" type="text"> +

" placeholder="" type="text">

-
+
-

+

t("Common settings")) ?>

+ +

0) { ?>checked="checked" /> " style="display: block; margin-top: 6px; width: 250px;" />

-
-

+

checked="checked" />

-
-

t("The default application for opening the format")) ?>

+

t("The default application for opening the format")) ?>

$setting) { ?> @@ -89,8 +97,10 @@
-

t("Open the file for editing (due to format restrictions, the data might be lost when saving to the formats from the list below)")) ?>

- "> +

+ t("Open the file for editing (due to format restrictions, the data might be lost when saving to the formats from the list below)")) ?> + "> +

$setting) { ?> @@ -104,6 +114,7 @@
+
- t("Save")) ?> +

\ No newline at end of file From 881f204ce7b9eea5ee6f862c2bf944dea6cab216 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 22 Apr 2019 16:55:18 +0300 Subject: [PATCH 09/25] split saving settings --- appinfo/routes.php | 3 +- controller/settingscontroller.php | 44 ++++++++++++++++---------- js/settings.js | 51 +++++++++++++++++++++++-------- templates/settings.php | 4 +++ 4 files changed, 72 insertions(+), 30 deletions(-) diff --git a/appinfo/routes.php b/appinfo/routes.php index 4accc964..c5d16c15 100644 --- a/appinfo/routes.php +++ b/appinfo/routes.php @@ -37,7 +37,8 @@ ["name" => "editor#config", "url" => "/ajax/config/{fileId}", "verb" => "GET"], ["name" => "editor#create", "url" => "/ajax/new", "verb" => "POST"], ["name" => "editor#convert", "url" => "/ajax/convert", "verb" => "POST"], - ["name" => "settings#save_settings", "url" => "/ajax/settings", "verb" => "PUT"], + ["name" => "settings#save_address", "url" => "/ajax/settings/address", "verb" => "PUT"], + ["name" => "settings#save_common", "url" => "/ajax/settings/common", "verb" => "PUT"], ["name" => "settings#get_settings", "url" => "/ajax/settings", "verb" => "GET"], ] ]; \ No newline at end of file diff --git a/controller/settingscontroller.php b/controller/settingscontroller.php index 1acd11a5..b10911eb 100644 --- a/controller/settingscontroller.php +++ b/controller/settingscontroller.php @@ -128,27 +128,19 @@ public function index() { } /** - * Save app settings + * Save address settings * * @param string $documentserver - document service address * @param string $documentserverInternal - document service address available from Nextcloud * @param string $storageUrl - Nextcloud address available from document server * @param string $secret - secret key for signature - * @param array $defFormats - formats array with default action - * @param array $editFormats - editable formats array - * @param bool $sameTab - open in same tab - * @param array $limitGroups - list of groups * * @return array */ - public function SaveSettings($documentserver, + public function SaveAddress($documentserver, $documentserverInternal, $storageUrl, - $secret, - $defFormats, - $editFormats, - $sameTab, - $limitGroups + $secret ) { $this->config->SetDocumentServerUrl($documentserver); $this->config->SetDocumentServerInternalUrl($documentserverInternal); @@ -162,11 +154,6 @@ public function SaveSettings($documentserver, $this->config->SetSettingsError($error); } - $this->config->SetDefaultFormats($defFormats); - $this->config->SetEditableFormats($editFormats); - $this->config->SetSameTab($sameTab); - $this->config->SetLimitGroups($limitGroups); - if ($this->checkEncryptionModule()) { $this->logger->info("SaveSettings when encryption is enabled", array("app" => $this->appName)); } @@ -180,6 +167,31 @@ public function SaveSettings($documentserver, ]; } + /** + * Save common settings + * + * @param array $defFormats - formats array with default action + * @param array $editFormats - editable formats array + * @param bool $sameTab - open in same tab + * @param array $limitGroups - list of groups + * + * @return array + */ + public function SaveCommon($defFormats, + $editFormats, + $sameTab, + $limitGroups + ) { + + $this->config->SetDefaultFormats($defFormats); + $this->config->SetEditableFormats($editFormats); + $this->config->SetSameTab($sameTab); + $this->config->SetLimitGroups($limitGroups); + + return [ + ]; + } + /** * Get app settings * diff --git a/js/settings.js b/js/settings.js index 8c7d8838..49ad8164 100644 --- a/js/settings.js +++ b/js/settings.js @@ -64,7 +64,7 @@ groupListToggle(); - $("#onlyofficeSave").click(function () { + $("#onlyofficeAddrSave").click(function () { $(".section-onlyoffice").addClass("icon-loading"); var onlyofficeUrl = $("#onlyofficeUrl").val().trim(); @@ -76,6 +76,39 @@ var onlyofficeStorageUrl = ($("#onlyofficeStorageUrl:visible").val() || "").trim(); var onlyofficeSecret = $("#onlyofficeSecret:visible").val() || ""; + $.ajax({ + method: "PUT", + url: OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/ajax/settings/address"), + data: { + documentserver: onlyofficeUrl, + documentserverInternal: onlyofficeInternalUrl, + storageUrl: onlyofficeStorageUrl, + secret: onlyofficeSecret + }, + success: function onSuccess(response) { + $(".section-onlyoffice").removeClass("icon-loading"); + if (response && response.documentserver != null) { + $("#onlyofficeUrl").val(response.documentserver); + $("#onlyofficeInternalUrl").val(response.documentserverInternal); + $("#onlyofficeStorageUrl").val(response.storageUrl); + $("#onlyofficeSecret").val(response.secret); + + var message = + response.error + ? (t(OCA.Onlyoffice.AppName, "Error when trying to connect") + " (" + response.error + ")") + : t(OCA.Onlyoffice.AppName, "Settings have been successfully updated"); + OC.Notification.show(message, { + type: response.error ? "error" : null, + timeout: 3 + }); + } + } + }); + }); + + $("#onlyofficeSave").click(function () { + $(".section-onlyoffice").addClass("icon-loading"); + var defFormats = {}; $("input[id^=\"onlyofficeDefFormat\"]").each(function() { defFormats[this.name] = this.checked; @@ -93,12 +126,8 @@ $.ajax({ method: "PUT", - url: OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/ajax/settings"), + url: OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/ajax/settings/common"), data: { - documentserver: onlyofficeUrl, - documentserverInternal: onlyofficeInternalUrl, - storageUrl: onlyofficeStorageUrl, - secret: onlyofficeSecret, defFormats: defFormats, editFormats: editFormats, sameTab: sameTab, @@ -106,18 +135,14 @@ }, success: function onSuccess(response) { $(".section-onlyoffice").removeClass("icon-loading"); - if (response && response.documentserver != null) { + if (response) { $("#onlyofficeUrl").val(response.documentserver); $("#onlyofficeInternalUrl").val(response.documentserverInternal); $("#onlyofficeStorageUrl").val(response.storageUrl); $("#onlyofficeSecret").val(response.secret); - var message = - response.error - ? (t(OCA.Onlyoffice.AppName, "Error when trying to connect") + " (" + response.error + ")") - : t(OCA.Onlyoffice.AppName, "Settings have been successfully updated"); + var message = t(OCA.Onlyoffice.AppName, "Settings have been successfully updated"); OC.Notification.show(message, { - type: response.error ? "error" : null, timeout: 3 }); } @@ -128,7 +153,7 @@ $(".section-onlyoffice input").keypress(function (e) { var code = e.keyCode || e.which; if (code === 13) { - $("#onlyofficeSave").click(); + $("#onlyofficeAddrSave").click(); } }); }); diff --git a/templates/settings.php b/templates/settings.php index 0596810b..471668e9 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -67,6 +67,10 @@
+

+
+
+

t("Common settings")) ?>

From b86a3b68029763281e2a481f1664011ed2d843bf Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 22 Apr 2019 17:06:23 +0300 Subject: [PATCH 10/25] split settings page --- templates/settings.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/templates/settings.php b/templates/settings.php index 471668e9..f56c5c59 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -68,9 +68,10 @@

-
-
+ + +

t("Common settings")) ?>

From e758ce9fa211960cdd44182340f0b099d1c78988 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Tue, 23 Apr 2019 16:48:07 +0300 Subject: [PATCH 11/25] hide section without configured server settings --- controller/settingscontroller.php | 3 ++- js/settings.js | 2 ++ templates/settings.php | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/controller/settingscontroller.php b/controller/settingscontroller.php index b10911eb..0e34eb6d 100644 --- a/controller/settingscontroller.php +++ b/controller/settingscontroller.php @@ -122,7 +122,8 @@ public function index() { "formats" => $this->config->FormatsSetting(), "sameTab" => $this->config->GetSameTab(), "encryption" => $this->checkEncryptionModule(), - "limitGroups" => $this->config->GetLimitGroups() + "limitGroups" => $this->config->GetLimitGroups(), + "successful" => $this->config->SettingsAreSuccessful() ]; return new TemplateResponse($this->appName, "settings", $data, "blank"); } diff --git a/js/settings.js b/js/settings.js index 49ad8164..20986916 100644 --- a/js/settings.js +++ b/js/settings.js @@ -93,6 +93,8 @@ $("#onlyofficeStorageUrl").val(response.storageUrl); $("#onlyofficeSecret").val(response.secret); + $(".section-onlyoffice-2").toggleClass("onlyoffice-hide", !response.documentserver.length || !!response.error.length); + var message = response.error ? (t(OCA.Onlyoffice.AppName, "Error when trying to connect") + " (" + response.error + ")") diff --git a/templates/settings.php b/templates/settings.php index f56c5c59..46cd3168 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -71,7 +71,7 @@

-
+
onlyoffice-hide">

t("Common settings")) ?>

From 5dd90834ac639fee8168e28a45a88734c3947774 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 24 Apr 2019 12:05:55 +0300 Subject: [PATCH 12/25] fix info link position --- css/settings.css | 5 +++-- templates/settings.php | 6 ++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/css/settings.css b/css/settings.css index 725b4278..d2f1c0d5 100644 --- a/css/settings.css +++ b/css/settings.css @@ -26,8 +26,9 @@ * */ -.section-onlyoffice h2 { - display: inline; + #content .section-onlyoffice .icon-info { + box-sizing: content-box; + padding-top: 6px; } .onlyoffice-error { color: red; diff --git a/templates/settings.php b/templates/settings.php index 46cd3168..91806b9f 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -31,8 +31,10 @@ script("onlyoffice", "settings"); ?>

-

ONLYOFFICE

- "> +

+ ONLYOFFICE + "> +

t("Server settings")) ?>

From 59d893b4ebc38e4243a88bfabc15bfd75bce4d58 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 24 Apr 2019 18:55:37 +0300 Subject: [PATCH 13/25] customization settings --- controller/editorcontroller.php | 18 +++++++ controller/settingscontroller.php | 16 +++++- js/settings.js | 9 +++- lib/appconfig.php | 81 +++++++++++++++++++++++++++++++ templates/settings.php | 26 ++++++++++ 5 files changed, 147 insertions(+), 3 deletions(-) diff --git a/controller/editorcontroller.php b/controller/editorcontroller.php index e9651b08..56b241d8 100644 --- a/controller/editorcontroller.php +++ b/controller/editorcontroller.php @@ -774,6 +774,24 @@ private function getUrl($fileId, $token = NULL) { * @return array */ private function setCustomization($params) { + //default is true + if ($this->config->GetCustomizationChat() === false) { + $params["editorConfig"]["customization"]["chat"] = false; + } + + //default is false + if ($this->config->GetCustomizationFeedback() === true) { + $params["editorConfig"]["customization"]["feedback"] = true; + } + + //default is true + if ($this->config->GetCustomizationHelp() === false) { + $params["editorConfig"]["customization"]["help"] = false; + } + + + /* from system config */ + $customer = $this->config->getSystemValue($this->config->_customization_customer); if (isset($customer)) { $params["editorConfig"]["customization"]["customer"] = $customer; diff --git a/controller/settingscontroller.php b/controller/settingscontroller.php index 0e34eb6d..3fac1124 100644 --- a/controller/settingscontroller.php +++ b/controller/settingscontroller.php @@ -123,6 +123,9 @@ public function index() { "sameTab" => $this->config->GetSameTab(), "encryption" => $this->checkEncryptionModule(), "limitGroups" => $this->config->GetLimitGroups(), + "chat" => $this->config->GetCustomizationChat(), + "feedback" => $this->config->GetCustomizationFeedback(), + "help" => $this->config->GetCustomizationHelp(), "successful" => $this->config->SettingsAreSuccessful() ]; return new TemplateResponse($this->appName, "settings", $data, "blank"); @@ -173,21 +176,30 @@ public function SaveAddress($documentserver, * * @param array $defFormats - formats array with default action * @param array $editFormats - editable formats array - * @param bool $sameTab - open in same tab + * @param bool $sameTab - open in the same tab * @param array $limitGroups - list of groups + * @param bool $chat - display chat + * @param bool $feedback - display feedback + * @param bool $help - display help * * @return array */ public function SaveCommon($defFormats, $editFormats, $sameTab, - $limitGroups + $limitGroups, + $chat, + $feedback, + $help ) { $this->config->SetDefaultFormats($defFormats); $this->config->SetEditableFormats($editFormats); $this->config->SetSameTab($sameTab); $this->config->SetLimitGroups($limitGroups); + $this->config->SetCustomizationChat($chat); + $this->config->SetCustomizationFeedback($feedback); + $this->config->SetCustomizationHelp($help); return [ ]; diff --git a/js/settings.js b/js/settings.js index 20986916..8b08a484 100644 --- a/js/settings.js +++ b/js/settings.js @@ -126,6 +126,10 @@ var limitGroupsString = $("#onlyofficeGroups").prop("checked") ? $("#onlyofficeLimitGroups").val() : ""; var limitGroups = limitGroupsString ? limitGroupsString.split("|") : []; + var chat = $("#onlyofficeChat").is(":checked"); + var feedback = $("#onlyofficeFeedback").is(":checked"); + var help = $("#onlyofficeHelp").is(":checked"); + $.ajax({ method: "PUT", url: OC.generateUrl("apps/" + OCA.Onlyoffice.AppName + "/ajax/settings/common"), @@ -133,7 +137,10 @@ defFormats: defFormats, editFormats: editFormats, sameTab: sameTab, - limitGroups: limitGroups + limitGroups: limitGroups, + chat: chat, + feedback: feedback, + help: help }, success: function onSuccess(response) { $(".section-onlyoffice").removeClass("icon-loading"); diff --git a/lib/appconfig.php b/lib/appconfig.php index 52a68123..c2a3133b 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -109,6 +109,27 @@ class AppConfig { */ private $_sameTab = "sameTab"; + /** + * The config key for the chat display setting + * + * @var string + */ + private $_customizationChat = "customizationChat"; + + /** + * The config key for the feedback display setting + * + * @var string + */ + private $_customizationFeedback = "customizationFeedback"; + + /** + * The config key for the help display setting + * + * @var string + */ + private $_customizationHelp = "customizationHelp"; + /** * The config key for the setting limit groups * @@ -430,6 +451,66 @@ public function GetSameTab() { return $this->config->getAppValue($this->appName, $this->_sameTab, "false") === "true"; } + /** + * Save chat display setting + * + * @param bool $value - display chat + */ + public function SetCustomizationChat($value) { + $this->logger->info("Set chat display: " . json_encode($value), array("app" => $this->appName)); + + $this->config->setAppValue($this->appName, $this->_customizationChat, json_encode($value)); + } + + /** + * Get chat display setting + * + * @return bool + */ + public function GetCustomizationChat() { + return $this->config->getAppValue($this->appName, $this->_customizationChat, "true") === "true"; + } + + /** + * Save feedback display setting + * + * @param bool $value - display feedback + */ + public function SetCustomizationFeedback($value) { + $this->logger->info("Set feedback display: " . json_encode($value), array("app" => $this->appName)); + + $this->config->setAppValue($this->appName, $this->_customizationFeedback, json_encode($value)); + } + + /** + * Get feedback display setting + * + * @return bool + */ + public function GetCustomizationFeedback() { + return $this->config->getAppValue($this->appName, $this->_customizationFeedback, "true") === "true"; + } + + /** + * Save help display setting + * + * @param bool $value - display help + */ + public function SetCustomizationHelp($value) { + $this->logger->info("Set help display: " . json_encode($value), array("app" => $this->appName)); + + $this->config->setAppValue($this->appName, $this->_customizationHelp, json_encode($value)); + } + + /** + * Get help display setting + * + * @return bool + */ + public function GetCustomizationHelp() { + return $this->config->getAppValue($this->appName, $this->_customizationHelp, "true") === "true"; + } + /** * Save the list of groups * diff --git a/templates/settings.php b/templates/settings.php index 91806b9f..899ac2c9 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -123,5 +123,31 @@

+

+ t("Editor customization settings")) ?> + "> +

+ +

t("The customization section allows to customize the editor interface")) ?>

+ +

+ checked="checked" /> + +

+ +

+ checked="checked" /> + +

+ +

+ checked="checked" /> + +

+
+

\ No newline at end of file From a52610133fcfa516e5944e9e1f2cda522ac9586b Mon Sep 17 00:00:00 2001 From: hellonadya Date: Thu, 16 May 2019 18:08:15 +0300 Subject: [PATCH 14/25] Update README.md --- README.md | 79 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 75 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index bf7bc632..aee82bda 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,14 @@ -# ![](screenshots/icon.png) Nextcloud ONLYOFFICE integration app +# ![](screenshots/icon.png) Nextcloud-ONLYOFFICE integration app + +* [Overview](#overview) +* [Installing ONLYOFFICE Document Server](#installing-onlyoffice-document-server) +* [ONLYOFFICE Document Server editions](#onlyoffice-document-server-editions) +* [Installing Nextcloud-ONLYOFFICE integration app](#installing-nextcloud-onlyoffice-integration-app) +* [Configuring Nextcloud-ONLYOFFICE integration app](#configuring-nextcloud-onlyoffice-integration-app) +* [How it works](#how-it-works) +* [Known issues](#known-issues) + +# Overview This app enables users to edit office documents from [Nextcloud](https://nextcloud.com) using ONLYOFFICE Document Server. Currently the following document formats can be edited with this app: csv, docx, pptx, txt, xlsx. @@ -23,8 +33,69 @@ Or you can use Document Server behind a proxy, please refer to [this article](ht The easiest way to start an instance of ONLYOFFICE Document Server is to use [Docker](https://github.com/ONLYOFFICE/Docker-DocumentServer). - -## Installing Nextcloud ONLYOFFICE integration app +## ONLYOFFICE Document Server editions + +ONLYOFFICE offers different versions of its online document editors that can be deployed on your own servers. + +ONLYOFFICE Document Server: +* Community Edition (`onlyoffice-documentserver` package) + +* Integration Edition (`onlyoffice-documentserver-ie` package) + +The table below will help you to make the right choice. + +| Pricing and licensing | Community Edition | Integration Edition | +| ------------- | ------------- | ------------- | +| | [Get it now](https://www.onlyoffice.com/download.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | [Start Free Trial](https://www.onlyoffice.com/connectors-request.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | +| Cost | FREE | [Go to the pricing page](https://www.onlyoffice.com/integration-edition-prices.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | +| Simultaneous connections | up to 20 maximum | As in chosen pricing plan | +| Number of users | up to 20 recommended | As in chosen pricing plan | +| License | GNU AGPL v.3 | Proprietary | +| **Support** | **Community Edition** | **Integration Edition** | +| Documentation | [Help Center](https://helpcenter.onlyoffice.com/server/docker/opensource/index.aspx) | [Help Center](https://helpcenter.onlyoffice.com/server/integration-edition/index.aspx) | +| Standard support | [GitHub](https://github.com/ONLYOFFICE/DocumentServer/issues) or paid | One year support included | +| Premium support | [Buy Now](https://www.onlyoffice.com/support.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | [Buy Now](https://www.onlyoffice.com/support.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | +| **Services** | **Community Edition** | **Integration Edition** | +| Conversion Service | + | + | +| Document Builder Service | - | + | +| **Interface** | **Community Edition** | **Integration Edition** | +| Tabbed interface | - | + | +| White Label | - | - | +| Integrated test example (node.js)* | - | + | +| **Plugins & Macros** | **Community Edition** | **Integration Edition** | +| Plugins | + | + | +| Macros | + | + | +| **Collaborative capabilities** | **Community Edition** | **Integration Edition** | +| Two co-editing modes | + | + | +| Comments | + | + | +| Built-in chat | + | + | +| Review and tracking changes | + | + | +| Display modes of tracking changes | - | + | +| Version history | + | + | +| **Document Editor features** | **Community Edition** | **Integration Edition** | +| Font and paragraph formatting | + | + | +| Object insertion | + | + | +| Content control | - | + | +| Layout tools | + | + | +| Table of contents | + | + | +| Navigation panel | - | + | +| Mail Merge | + | + | +| **Spreadsheet Editor features** | **Community Edition** | **Integration Edition** | +| Font and paragraph formatting | + | + | +| Object insertion | + | + | +| Functions, formulas, equations | + | + | +| Table templates | + | + | +| Pivot tables | - | +** | +| **Presentation Editor features** | **Community Edition** | **Integration Edition** | +| Font and paragraph formatting | + | + | +| Object insertion | + | + | +| Animations | + | + | +| Presenter mode | - | + | +| Notes | + | + | +| | [Get it now](https://www.onlyoffice.com/download.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | [Start Free Trial](https://www.onlyoffice.com/connectors-request.aspx?utm_source=github&utm_medium=cpc&utm_campaign=GitHubNextcloud) | + + +## Installing Nextcloud-ONLYOFFICE integration app The Nextcloud administrator can install the integration app from the in-built application market. For that go to the user name and select **Apps**. @@ -58,7 +129,7 @@ There are several ways to do that: 3. In Nextcloud open the `~/index.php/settings/apps?category=disabled` page with _Not enabled_ apps by administrator and click _Enable_ for the **ONLYOFFICE** application. -## Configuring Nextcloud ONLYOFFICE integration app +## Configuring Nextcloud-ONLYOFFICE integration app In Nextcloud open the `~/index.php/settings/admin/onlyoffice` page with administrative settings for **ONLYOFFICE** section. Enter the following address to connect ONLYOFFICE Document Server: From 4c6a33211bd944c9c7779ea6cdae77cfdbb9aaa6 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Fri, 14 Jun 2019 10:20:55 +0300 Subject: [PATCH 15/25] rename result param --- controller/callbackcontroller.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/controller/callbackcontroller.php b/controller/callbackcontroller.php index a6feba30..ce1d9064 100644 --- a/controller/callbackcontroller.php +++ b/controller/callbackcontroller.php @@ -363,7 +363,7 @@ public function track($doc, $users, $key, $status, $url, $token) { $trackerStatus = $this->_trackerStatus[$status]; - $error = 1; + $result = 1; switch ($trackerStatus) { case "MustSave": case "Corrupted": @@ -437,7 +437,7 @@ public function track($doc, $users, $key, $status, $url, $token) { $this->logger->debug("Track put content " . $file->getPath(), array("app" => $this->appName)); $file->putContent($newData); - $error = 0; + $result = 0; } catch (\Exception $e) { $this->logger->error("Track " . $trackerStatus . " error: " . $e->getMessage(), array("app" => $this->appName)); } @@ -445,13 +445,13 @@ public function track($doc, $users, $key, $status, $url, $token) { case "Editing": case "Closed": - $error = 0; + $result = 0; break; } $this->logger->debug("Track: " . $fileId . " status " . $status . " result " . $error, array("app" => $this->appName)); - return new JSONResponse(["error" => $error], Http::STATUS_OK); + return new JSONResponse(["error" => $result], Http::STATUS_OK); } From d264f75701f18cbf46c8a09b6be8d7ee4db68464 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Fri, 14 Jun 2019 12:23:40 +0300 Subject: [PATCH 16/25] support master encryption --- controller/callbackcontroller.php | 4 ++++ controller/settingscontroller.php | 27 ++------------------------- lib/appconfig.php | 23 +++++++++++++++++++++++ 3 files changed, 29 insertions(+), 25 deletions(-) diff --git a/controller/callbackcontroller.php b/controller/callbackcontroller.php index ce1d9064..7f1a6acb 100644 --- a/controller/callbackcontroller.php +++ b/controller/callbackcontroller.php @@ -388,6 +388,10 @@ public function track($doc, $users, $key, $status, $url, $token) { $this->logger->debug("Track by anonymous " . $userId, array("app" => $this->appName)); } + if ($this->config->checkEncryptionModule() === "master") { + \OC_User::setIncognitoMode(true); + } + \OC_Util::tearDownFS(); if (!empty($ownerId)) { \OC_Util::setupFS($ownerId); diff --git a/controller/settingscontroller.php b/controller/settingscontroller.php index 1acd11a5..5621e7cf 100644 --- a/controller/settingscontroller.php +++ b/controller/settingscontroller.php @@ -29,7 +29,6 @@ namespace OCA\Onlyoffice\Controller; -use OCP\App; use OCP\AppFramework\Controller; use OCP\AppFramework\Http\TemplateResponse; use OCP\IL10N; @@ -121,7 +120,7 @@ public function index() { "currentServer" => $this->urlGenerator->getAbsoluteURL("/"), "formats" => $this->config->FormatsSetting(), "sameTab" => $this->config->GetSameTab(), - "encryption" => $this->checkEncryptionModule(), + "encryption" => ($this->config->checkEncryptionModule() === true), "limitGroups" => $this->config->GetLimitGroups() ]; return new TemplateResponse($this->appName, "settings", $data, "blank"); @@ -167,7 +166,7 @@ public function SaveSettings($documentserver, $this->config->SetSameTab($sameTab); $this->config->SetLimitGroups($limitGroups); - if ($this->checkEncryptionModule()) { + if ($this->config->checkEncryptionModule() === true) { $this->logger->info("SaveSettings when encryption is enabled", array("app" => $this->appName)); } @@ -276,26 +275,4 @@ private function checkDocServiceUrl() { return ""; } - - /** - * Checking encryption enabled - * - * @return bool - */ - private function checkEncryptionModule() { - if (!App::isEnabled("encryption")) { - return false; - } - if (!\OC::$server->getEncryptionManager()->isEnabled()) { - return false; - } - - $crypt = new \OCA\Encryption\Crypto\Crypt(\OC::$server->getLogger(), \OC::$server->getUserSession(), \OC::$server->getConfig(), \OC::$server->getL10N("encryption")); - $util = new \OCA\Encryption\Util(new \OC\Files\View(), $crypt, \OC::$server->getLogger(), \OC::$server->getUserSession(), \OC::$server->getConfig(), \OC::$server->getUserManager()); - if ($util->isMasterKeyEnabled()) { - return false; - } - - return true; - } } diff --git a/lib/appconfig.php b/lib/appconfig.php index 52a68123..6df10cbc 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -29,6 +29,7 @@ namespace OCA\Onlyoffice; +use OCP\App; use OCP\IConfig; use OCP\ILogger; @@ -538,6 +539,28 @@ public function SettingsAreSuccessful() { return empty($this->config->getAppValue($this->appName, $this->_settingsError, "")); } + /** + * Checking encryption enabled + * + * @return string|bool + */ + public function checkEncryptionModule() { + if (!App::isEnabled("encryption")) { + return false; + } + if (!\OC::$server->getEncryptionManager()->isEnabled()) { + return false; + } + + $crypt = new \OCA\Encryption\Crypto\Crypt(\OC::$server->getLogger(), \OC::$server->getUserSession(), \OC::$server->getConfig(), \OC::$server->getL10N("encryption")); + $util = new \OCA\Encryption\Util(new \OC\Files\View(), $crypt, \OC::$server->getLogger(), \OC::$server->getUserSession(), \OC::$server->getConfig(), \OC::$server->getUserManager()); + if ($util->isMasterKeyEnabled()) { + return "master"; + } + + return true; + } + /** * Get supported formats * From 9061f4d03099ea1d923b740839e2a8fb187894ce Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 24 Apr 2019 19:11:59 +0300 Subject: [PATCH 17/25] customization settings (DS 5.3) --- controller/editorcontroller.php | 10 ++++++ controller/settingscontroller.php | 10 +++++- js/settings.js | 6 +++- lib/appconfig.php | 54 +++++++++++++++++++++++++++++++ templates/settings.php | 12 +++++++ 5 files changed, 90 insertions(+), 2 deletions(-) diff --git a/controller/editorcontroller.php b/controller/editorcontroller.php index 56b241d8..1d6b5f8e 100644 --- a/controller/editorcontroller.php +++ b/controller/editorcontroller.php @@ -779,6 +779,11 @@ private function setCustomization($params) { $params["editorConfig"]["customization"]["chat"] = false; } + //default is false + if ($this->config->GetCustomizationCompactHeader() === true) { + $params["editorConfig"]["customization"]["compactHeader"] = true; + } + //default is false if ($this->config->GetCustomizationFeedback() === true) { $params["editorConfig"]["customization"]["feedback"] = true; @@ -789,6 +794,11 @@ private function setCustomization($params) { $params["editorConfig"]["customization"]["help"] = false; } + //default is false + if ($this->config->GetCustomizationToolbarNoTabs() === true) { + $params["editorConfig"]["customization"]["toolbarNoTabs"] = true; + } + /* from system config */ diff --git a/controller/settingscontroller.php b/controller/settingscontroller.php index 3fac1124..ad5d8bc7 100644 --- a/controller/settingscontroller.php +++ b/controller/settingscontroller.php @@ -124,8 +124,10 @@ public function index() { "encryption" => $this->checkEncryptionModule(), "limitGroups" => $this->config->GetLimitGroups(), "chat" => $this->config->GetCustomizationChat(), + "compactHeader" => $this->config->GetCustomizationCompactHeader(), "feedback" => $this->config->GetCustomizationFeedback(), "help" => $this->config->GetCustomizationHelp(), + "toolbarNoTabs" => $this->config->GetCustomizationToolbarNoTabs(), "successful" => $this->config->SettingsAreSuccessful() ]; return new TemplateResponse($this->appName, "settings", $data, "blank"); @@ -179,8 +181,10 @@ public function SaveAddress($documentserver, * @param bool $sameTab - open in the same tab * @param array $limitGroups - list of groups * @param bool $chat - display chat + * @param bool $compactHeader - display compact header * @param bool $feedback - display feedback * @param bool $help - display help + * @param bool $toolbarNoTabs - display toolbar tab * * @return array */ @@ -189,8 +193,10 @@ public function SaveCommon($defFormats, $sameTab, $limitGroups, $chat, + $compactHeader, $feedback, - $help + $help, + $toolbarNoTabs ) { $this->config->SetDefaultFormats($defFormats); @@ -198,8 +204,10 @@ public function SaveCommon($defFormats, $this->config->SetSameTab($sameTab); $this->config->SetLimitGroups($limitGroups); $this->config->SetCustomizationChat($chat); + $this->config->SetCustomizationCompactHeader($compactHeader); $this->config->SetCustomizationFeedback($feedback); $this->config->SetCustomizationHelp($help); + $this->config->SetCustomizationToolbarNoTabs($toolbarNoTabs); return [ ]; diff --git a/js/settings.js b/js/settings.js index 8b08a484..f9de6976 100644 --- a/js/settings.js +++ b/js/settings.js @@ -127,8 +127,10 @@ var limitGroups = limitGroupsString ? limitGroupsString.split("|") : []; var chat = $("#onlyofficeChat").is(":checked"); + var compactHeader = $("#onlyofficeCompactHeader").is(":checked"); var feedback = $("#onlyofficeFeedback").is(":checked"); var help = $("#onlyofficeHelp").is(":checked"); + var toolbarNoTabs = !$("#onlyofficeToolbarNoTabs").is(":checked"); $.ajax({ method: "PUT", @@ -139,8 +141,10 @@ sameTab: sameTab, limitGroups: limitGroups, chat: chat, + compactHeader: compactHeader, feedback: feedback, - help: help + help: help, + toolbarNoTabs: toolbarNoTabs }, success: function onSuccess(response) { $(".section-onlyoffice").removeClass("icon-loading"); diff --git a/lib/appconfig.php b/lib/appconfig.php index c2a3133b..3bbd2cd0 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -116,6 +116,13 @@ class AppConfig { */ private $_customizationChat = "customizationChat"; + /** + * The config key for display the header more compact setting + * + * @var string + */ + private $_customizationCompactHeader = "customizationCompactHeader"; + /** * The config key for the feedback display setting * @@ -130,6 +137,13 @@ class AppConfig { */ private $_customizationHelp = "customizationHelp"; + /** + * The config key for the no tabs setting + * + * @var string + */ + private $_customizationToolbarNoTabs = "customizationToolbarNoTabs"; + /** * The config key for the setting limit groups * @@ -471,6 +485,26 @@ public function GetCustomizationChat() { return $this->config->getAppValue($this->appName, $this->_customizationChat, "true") === "true"; } + /** + * Save compact header setting + * + * @param bool $value - display compact header + */ + public function SetCustomizationCompactHeader($value) { + $this->logger->info("Set compact header display: " . json_encode($value), array("app" => $this->appName)); + + $this->config->setAppValue($this->appName, $this->_customizationCompactHeader, json_encode($value)); + } + + /** + * Get compact header setting + * + * @return bool + */ + public function GetCustomizationCompactHeader() { + return $this->config->getAppValue($this->appName, $this->_customizationCompactHeader, "true") === "true"; + } + /** * Save feedback display setting * @@ -511,6 +545,26 @@ public function GetCustomizationHelp() { return $this->config->getAppValue($this->appName, $this->_customizationHelp, "true") === "true"; } + /** + * Save without tabs setting + * + * @param bool $value - without tabs + */ + public function SetCustomizationToolbarNoTabs($value) { + $this->logger->info("Set without tabs: " . json_encode($value), array("app" => $this->appName)); + + $this->config->setAppValue($this->appName, $this->_customizationToolbarNoTabs, json_encode($value)); + } + + /** + * Get without tabs setting + * + * @return bool + */ + public function GetCustomizationToolbarNoTabs() { + return $this->config->getAppValue($this->appName, $this->_customizationToolbarNoTabs, "true") === "true"; + } + /** * Save the list of groups * diff --git a/templates/settings.php b/templates/settings.php index 899ac2c9..395705c8 100644 --- a/templates/settings.php +++ b/templates/settings.php @@ -136,6 +136,12 @@

+

+ checked="checked" /> + +

+

checked="checked" /> @@ -147,6 +153,12 @@ checked="checked" />

+ +

+ checked="checked" /> + +


From 76a3c72fc2947ff4d6704049e02583fd99febb8c Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 17 Jun 2019 12:11:28 +0300 Subject: [PATCH 18/25] do not clear address settings when saving customization --- js/settings.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/js/settings.js b/js/settings.js index f9de6976..052a3218 100644 --- a/js/settings.js +++ b/js/settings.js @@ -149,11 +149,6 @@ success: function onSuccess(response) { $(".section-onlyoffice").removeClass("icon-loading"); if (response) { - $("#onlyofficeUrl").val(response.documentserver); - $("#onlyofficeInternalUrl").val(response.documentserverInternal); - $("#onlyofficeStorageUrl").val(response.storageUrl); - $("#onlyofficeSecret").val(response.secret); - var message = t(OCA.Onlyoffice.AppName, "Settings have been successfully updated"); OC.Notification.show(message, { timeout: 3 From 9c5aae53badc3a1770f70c0a9fa92b1eafe168f9 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 19 Jun 2019 10:02:52 +0300 Subject: [PATCH 19/25] Fix check method (#94) --- controller/editorcontroller.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controller/editorcontroller.php b/controller/editorcontroller.php index 1d6b5f8e..4c0c9acc 100644 --- a/controller/editorcontroller.php +++ b/controller/editorcontroller.php @@ -536,7 +536,7 @@ public function config($fileId, $filePath = NULL, $token = NULL, $desktop = fals $folderLink = NULL; if (!empty($token)) { - if (method_exists($share, getHideDownload) && $share->getHideDownload()) { + if (method_exists($share, "getHideDownload") && $share->getHideDownload()) { $params["document"]["permissions"] = [ "download" => false, "print" => false From 7d4b6e8da8f38276c5c171935ad0ae257ec4d471 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 19 Jun 2019 10:27:16 +0300 Subject: [PATCH 20/25] ocsid is not supported --- appinfo/info.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/appinfo/info.xml b/appinfo/info.xml index 1f7dd2bb..ce222839 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -1,7 +1,6 @@  onlyoffice - 174798 ONLYOFFICE ONLYOFFICE connector ONLYOFFICE connector enables you to edit Office documents within ONLYOFFICE from the familiar web interface. This will create a new Open in ONLYOFFICE action within the document library for Office documents. This allows multiple users to collaborate in real time and to save back those changes to your file storage. From 914dd38045a3616d1b04dd598d06304ef1fa225e Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 19 Jun 2019 10:54:12 +0300 Subject: [PATCH 21/25] remove the old scheme of adding settings --- settings.php | 43 ------------------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 settings.php diff --git a/settings.php b/settings.php deleted file mode 100644 index 802d01fb..00000000 --- a/settings.php +++ /dev/null @@ -1,43 +0,0 @@ -getContainer(); -$response = $container->query(SettingsController::class)->index(); - -return $response->render(); From 7067f483a1747b6aa8578ccf4fd8b8554d9d1e26 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 19 Jun 2019 11:28:29 +0300 Subject: [PATCH 22/25] replace using OCP\APp --- lib/appconfig.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/appconfig.php b/lib/appconfig.php index a5952bb4..7d37ecf5 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -29,7 +29,6 @@ namespace OCA\Onlyoffice; -use OCP\App; use OCP\IConfig; use OCP\ILogger; @@ -680,7 +679,7 @@ public function SettingsAreSuccessful() { * @return string|bool */ public function checkEncryptionModule() { - if (!App::isEnabled("encryption")) { + if (!\OC::$server->getAppManager()->isInstalled("encryption")) { return false; } if (!\OC::$server->getEncryptionManager()->isEnabled()) { From e6fb3470149c2861ceb6811295f4b142a2ce9906 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Wed, 19 Jun 2019 11:36:43 +0300 Subject: [PATCH 23/25] add discussion link --- appinfo/info.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/appinfo/info.xml b/appinfo/info.xml index ce222839..bfed9234 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -21,6 +21,7 @@ office tools https://www.onlyoffice.com + https://dev.onlyoffice.org/ https://github.com/ONLYOFFICE/onlyoffice-nextcloud/issues https://github.com/ONLYOFFICE/onlyoffice-nextcloud.git https://raw.githubusercontent.com/ONLYOFFICE/onlyoffice-nextcloud/master/screenshots/main.png From c6007cf1a3ef3551cbaa2a69d9d36454d7308e65 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 24 Jun 2019 11:34:33 +0300 Subject: [PATCH 24/25] l10n --- l10n/de.js | 11 ++++++++++- l10n/de.json | 11 ++++++++++- l10n/de_DE.js | 11 ++++++++++- l10n/de_DE.json | 11 ++++++++++- l10n/es.js | 11 ++++++++++- l10n/es.json | 11 ++++++++++- l10n/fr.js | 11 ++++++++++- l10n/fr.json | 11 ++++++++++- l10n/ru.js | 11 ++++++++++- l10n/ru.json | 11 ++++++++++- 10 files changed, 100 insertions(+), 10 deletions(-) diff --git a/l10n/de.js b/l10n/de.js index b578c2c8..daf392b7 100644 --- a/l10n/de.js +++ b/l10n/de.js @@ -45,6 +45,15 @@ OC.L10N.register( "View details" : "Details anzeigen", "Save" : "Speichern", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Mixed Active Content ist nicht möglich. HTTPS-Adresse für Document Server ist erforderlich.", - "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren" + "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren", + "Server settings" : "Servereinstellungen", + "Common settings" : "Allgemeine Einstellungen", + "Editor customization settings" : "Editor-Einstellungen", + "The customization section allows to customize the editor interface" : "Die Anpassungssektion ermöglicht die Anpassung der Editoroberfläche", + "Display Chat menu button" : "Chat-Taste anzeigen", + "Display the header more compact" : "Kompakten Header anzeigen", + "Display Feedback & Support menu button" : "Feedback-& Support-Taste anzeigen", + "Display Help menu button" : "Hilfetaste anzeigen", + "Display toolbar tabs" : "Symbolleiste-Registerkarten anzeigen" }, "nplurals=2; plural=(n != 1);"); diff --git a/l10n/de.json b/l10n/de.json index e29b9cef..1d6d3153 100644 --- a/l10n/de.json +++ b/l10n/de.json @@ -43,6 +43,15 @@ "View details" : "Details anzeigen", "Save" : "Speichern", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Mixed Active Content ist nicht möglich. HTTPS-Adresse für Document Server ist erforderlich.", - "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren" + "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren", + "Server settings" : "Servereinstellungen", + "Common settings" : "Allgemeine Einstellungen", + "Editor customization settings" : "Editor-Einstellungen", + "The customization section allows to customize the editor interface" : "Die Anpassungssektion ermöglicht die Anpassung der Editoroberfläche", + "Display Chat menu button" : "Chat-Taste anzeigen", + "Display the header more compact" : "Kompakten Header anzeigen", + "Display Feedback & Support menu button" : "Feedback-& Support-Taste anzeigen", + "Display Help menu button" : "Hilfetaste anzeigen", + "Display toolbar tabs" : "Symbolleiste-Registerkarten anzeigen" },"pluralForm" :"nplurals=2; plural=(n != 1);" } \ No newline at end of file diff --git a/l10n/de_DE.js b/l10n/de_DE.js index 05c90da6..9fbbd91d 100644 --- a/l10n/de_DE.js +++ b/l10n/de_DE.js @@ -45,6 +45,15 @@ OC.L10N.register( "View details" : "Details anzeigen", "Save" : "Speichern", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Mixed Active Content ist nicht möglich. HTTPS-Adresse für Document Server ist erforderlich.", - "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren" + "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren", + "Server settings" : "Servereinstellungen", + "Common settings" : "Allgemeine Einstellungen", + "Editor customization settings" : "Editor-Einstellungen", + "The customization section allows to customize the editor interface" : "Die Anpassungssektion ermöglicht die Anpassung der Editoroberfläche", + "Display Chat menu button" : "Chat-Taste anzeigen", + "Display the header more compact" : "Kompakten Header anzeigen", + "Display Feedback & Support menu button" : "Feedback-& Support-Taste anzeigen", + "Display Help menu button" : "Hilfetaste anzeigen", + "Display toolbar tabs" : "Symbolleiste-Registerkarten anzeigen" }, "nplurals=2; plural=(n != 1);"); diff --git a/l10n/de_DE.json b/l10n/de_DE.json index 6cf04f71..4ec1dc8f 100644 --- a/l10n/de_DE.json +++ b/l10n/de_DE.json @@ -43,6 +43,15 @@ "View details" : "Details anzeigen", "Save" : "Speichern", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Mixed Active Content ist nicht möglich. HTTPS-Adresse für Document Server ist erforderlich.", - "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren" + "Restrict access to editors to following groups" : "Den Zugriff auf Editoren auf folgende Gruppen gewähren", + "Server settings" : "Servereinstellungen", + "Common settings" : "Allgemeine Einstellungen", + "Editor customization settings" : "Editor-Einstellungen", + "The customization section allows to customize the editor interface" : "Die Anpassungssektion ermöglicht die Anpassung der Editoroberfläche", + "Display Chat menu button" : "Chat-Taste anzeigen", + "Display the header more compact" : "Kompakten Header anzeigen", + "Display Feedback & Support menu button" : "Feedback-& Support-Taste anzeigen", + "Display Help menu button" : "Hilfetaste anzeigen", + "Display toolbar tabs" : "Symbolleiste-Registerkarten anzeigen" },"pluralForm" :"nplurals=2; plural=(n != 1);" } \ No newline at end of file diff --git a/l10n/es.js b/l10n/es.js index e22b794c..fb30dcf8 100644 --- a/l10n/es.js +++ b/l10n/es.js @@ -45,6 +45,15 @@ OC.L10N.register( "View details" : "Ver detalles", "Save" : "Guardar", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Contenido Mixto Activo no está permitido. Se requiere la dirección HTTPS para Servidor de Documentos.", - "Restrict access to editors to following groups" : "Restringir el acceso a editores a siguientes grupos" + "Restrict access to editors to following groups" : "Restringir el acceso a editores a siguientes grupos", + "Server settings" : "Ajustes de servidor", + "Common settings" : "Ajustes comunes", + "Editor customization settings" : "Ajustes del editor", + "The customization section allows to customize the editor interface" : "La sección de personalización permite customizar la interfaz del editor", + "Display Chat menu button" : "Mostrar el botón de Chat", + "Display the header more compact" : "Mostrar el encabezado más compacto", + "Display Feedback & Support menu button" : "Mostrar el botón de Feedback y Soporte", + "Display Help menu button" : "Mostrar el botón de Ayuda", + "Display toolbar tabs" : "Mostrar pestañas de barra de herramientas" }, "nplurals=2; plural=(n != 1);"); diff --git a/l10n/es.json b/l10n/es.json index 9c0922a4..4d9ccf38 100644 --- a/l10n/es.json +++ b/l10n/es.json @@ -43,6 +43,15 @@ "View details" : "Ver detalles", "Save" : "Guardar", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Contenido Mixto Activo no está permitido. Se requiere la dirección HTTPS para Servidor de Documentos.", - "Restrict access to editors to following groups" : "Restringir el acceso a editores a siguientes grupos" + "Restrict access to editors to following groups" : "Restringir el acceso a editores a siguientes grupos", + "Server settings" : "Ajustes de servidor", + "Common settings" : "Ajustes comunes", + "Editor customization settings" : "Ajustes del editor", + "The customization section allows to customize the editor interface" : "La sección de personalización permite customizar la interfaz del editor", + "Display Chat menu button" : "Mostrar el botón de Chat", + "Display the header more compact" : "Mostrar el encabezado más compacto", + "Display Feedback & Support menu button" : "Mostrar el botón de Feedback y Soporte", + "Display Help menu button" : "Mostrar el botón de Ayuda", + "Display toolbar tabs" : "Mostrar pestañas de barra de herramientas" },"pluralForm" :"nplurals=2; plural=(n != 1);" } \ No newline at end of file diff --git a/l10n/fr.js b/l10n/fr.js index 6adddb8b..7d1f9c94 100644 --- a/l10n/fr.js +++ b/l10n/fr.js @@ -45,6 +45,15 @@ OC.L10N.register( "View details" : "Voir les détails", "Save" : "Enregistrer", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Le contenu mixte actif n'est pas autorisé. Une adresse HTTPS pour le serveur de document est requise", - "Restrict access to editors to following groups" : "Restreindre l'accès aux éditeurs pour les groupes suivants" + "Restrict access to editors to following groups" : "Restreindre l'accès aux éditeurs pour les groupes suivants", + "Server settings" : "Paramètres du serveur", + "Common settings" : "Paramètres communs", + "Editor customization settings" : "Paramètres de personnalisation de l'éditeur", + "The customization section allows to customize the editor interface" : "La section de personnalisation permet de personnaliser l'interface de l'éditeur", + "Display Chat menu button" : "Afficher le bouton du menu du chat", + "Display the header more compact" : "Afficher l'en-tête plus compact", + "Display Feedback & Support menu button" : "Afficher le bouton du menu 'Feedback & Support'", + "Display Help menu button" : "Afficher le bouton du menu 'Aide'", + "Display toolbar tabs" : "Afficher les onglets de la barre d'outils" }, "nplurals=2; plural=(n != 1);"); diff --git a/l10n/fr.json b/l10n/fr.json index b129788e..c7ac1466 100644 --- a/l10n/fr.json +++ b/l10n/fr.json @@ -43,6 +43,15 @@ "View details" : "Voir les détails", "Save" : "Enregistrer", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Le contenu mixte actif n'est pas autorisé. Une adresse HTTPS pour le serveur de document est requise", - "Restrict access to editors to following groups" : "Restreindre l'accès aux éditeurs pour les groupes suivants" + "Restrict access to editors to following groups" : "Restreindre l'accès aux éditeurs pour les groupes suivants", + "Server settings" : "Paramètres du serveur", + "Common settings" : "Paramètres communs", + "Editor customization settings" : "Paramètres de personnalisation de l'éditeur", + "The customization section allows to customize the editor interface" : "La section de personnalisation permet de personnaliser l'interface de l'éditeur", + "Display Chat menu button" : "Afficher le bouton du menu du chat", + "Display the header more compact" : "Afficher l'en-tête plus compact", + "Display Feedback & Support menu button" : "Afficher le bouton du menu 'Feedback & Support'", + "Display Help menu button" : "Afficher le bouton du menu 'Aide'", + "Display toolbar tabs" : "Afficher les onglets de la barre d'outils" },"pluralForm" :"nplurals=2; plural=(n != 1);" } diff --git a/l10n/ru.js b/l10n/ru.js index b6ddd3e9..03edecda 100644 --- a/l10n/ru.js +++ b/l10n/ru.js @@ -45,6 +45,15 @@ OC.L10N.register( "View details" : "Подробнее", "Save" : "Сохранить", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Смешанное активное содержимое запрещено. Для Сервера документов необходимо использовать HTTPS-адрес.", - "Restrict access to editors to following groups" : "Дать доступ к редакторам только следующим группам" + "Restrict access to editors to following groups" : "Дать доступ к редакторам только следующим группам", + "Server settings" : "Настройки сервера", + "Common settings" : "Общие настройки", + "Editor customization settings" : "Настройка редактора", + "The customization section allows to customize the editor interface" : "Раздел настройки позволяет изменить интерфейс редактора", + "Display Chat menu button" : "Отображать кнопку чата", + "Display the header more compact" : "Отображать заголовок компактным", + "Display Feedback & Support menu button" : "Отображать кнопку Обратной связи и поддержки", + "Display Help menu button" : "Отображать кнопку справки", + "Display toolbar tabs" : "Отображать вкладки панели инструментов" }, "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); diff --git a/l10n/ru.json b/l10n/ru.json index 58a53d24..c6f751c9 100644 --- a/l10n/ru.json +++ b/l10n/ru.json @@ -43,6 +43,15 @@ "View details" : "Подробнее", "Save" : "Сохранить", "Mixed Active Content is not allowed. HTTPS address for Document Server is required." : "Смешанное активное содержимое запрещено. Для Сервера документов необходимо использовать HTTPS-адрес.", - "Restrict access to editors to following groups" : "Дать доступ к редакторам только следующим группам" + "Restrict access to editors to following groups" : "Дать доступ к редакторам только следующим группам", + "Server settings" : "Настройки сервера", + "Common settings" : "Общие настройки", + "Editor customization settings" : "Настройка редактора", + "The customization section allows to customize the editor interface" : "Раздел настройки позволяет изменить интерфейс редактора", + "Display Chat menu button" : "Отображать кнопку чата", + "Display the header more compact" : "Отображать заголовок компактным", + "Display Feedback & Support menu button" : "Отображать кнопку Обратной связи и поддержки", + "Display Help menu button" : "Отображать кнопку справки", + "Display toolbar tabs" : "Отображать вкладки панели инструментов" },"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" } \ No newline at end of file From f37f62bfadba29317ca7cc73ccf92acd79ab1b22 Mon Sep 17 00:00:00 2001 From: Sergey Linnik Date: Mon, 24 Jun 2019 15:08:54 +0300 Subject: [PATCH 25/25] 2.3.0 --- CHANGELOG.md | 10 ++++++++++ appinfo/info.xml | 2 +- lib/documentservice.php | 1 - 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2a63a8b3..430582f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,15 @@ # Change Log +## 2.3.0 +## Added +- editor customization + +## Changed +- the settings page is splitted into two sections +- support master key encryption +- fix getting domain for desktop +- title in the convertation request + ## 2.1.10 ## Changed - compatible with Nextcloud 16 diff --git a/appinfo/info.xml b/appinfo/info.xml index bfed9234..9ae2f94a 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -6,7 +6,7 @@ ONLYOFFICE connector enables you to edit Office documents within ONLYOFFICE from the familiar web interface. This will create a new Open in ONLYOFFICE action within the document library for Office documents. This allows multiple users to collaborate in real time and to save back those changes to your file storage. agpl Ascensio System SIA - 2.1.10 + 2.3.0 Onlyoffice diff --git a/lib/documentservice.php b/lib/documentservice.php index 25579e11..ba9507ad 100644 --- a/lib/documentservice.php +++ b/lib/documentservice.php @@ -343,7 +343,6 @@ function ProcessCommandServResponceError($errorCode) { * * @return string */ - public function Request($url, $method = "get", $opts = NULL) { $httpClientService = \OC::$server->getHTTPClientService(); $client = $httpClientService->newClient();