Browse Source

Remove unrequired route

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
tags/1.1.22
Lukas Reschke 3 years ago
parent
commit
aa89c908a7
No account linked to committer's email address
3 changed files with 3 additions and 21 deletions
  1. 0
    1
      appinfo/routes.php
  2. 3
    8
      js/viewer/viewer.js
  3. 0
    12
      lib/Controller/SettingsController.php

+ 0
- 1
appinfo/routes.php View File

@@ -25,6 +25,5 @@ return [

//settings
['name' => 'settings#setSettings', 'url' => 'ajax/admin.php', 'verb' => 'POST'],
['name' => 'settings#getSettings', 'url' => 'ajax/settings.php', 'verb' => 'GET'],
]
];

+ 3
- 8
js/viewer/viewer.js View File

@@ -131,8 +131,8 @@ var odfViewer = {
$('#richdocumentsframe').remove();
},

registerFilesMenu: function(response) {
var ooxml = response.doc_format === 'ooxml';
registerFilesMenu: function() {
var ooxml = false;

var docExt, spreadsheetExt, presentationExt;
var docMime, spreadsheetMime, presentationMime;
@@ -220,12 +220,7 @@ $(document).ready(function() {
&& typeof OCA.Files.fileActions !== 'undefined'
) {
odfViewer.register();

$.get(
OC.filePath('richdocuments', 'ajax', 'settings.php'),
{},
odfViewer.registerFilesMenu
);
odfViewer.registerFilesMenu();
}
});


+ 0
- 12
lib/Controller/SettingsController.php View File

@@ -52,18 +52,6 @@ class SettingsController extends Controller{
);
}

/**
* @NoAdminRequired
*
* @return JSONResponse
*/
public function getSettings() {
return new JSONResponse([
'doc_format' => $this->appConfig->getAppValue('doc_format'),
'wopi_url' => $this->appConfig->getAppValue('wopi_url'),
]);
}

/**
* @param string $wopi_url
* @param string $doc_format

Loading…
Cancel
Save