commit
0f01c190ef
@ -58,12 +58,12 @@ class DocumentController extends Controller{
|
|||||||
'uploadMaxFilesize' => $maxUploadFilesize,
|
'uploadMaxFilesize' => $maxUploadFilesize,
|
||||||
'uploadMaxHumanFilesize' => \OCP\Util::humanFileSize($maxUploadFilesize),
|
'uploadMaxHumanFilesize' => \OCP\Util::humanFileSize($maxUploadFilesize),
|
||||||
'allowShareWithLink' => $this->settings->getAppValue('core', 'shareapi_allow_links', 'yes'),
|
'allowShareWithLink' => $this->settings->getAppValue('core', 'shareapi_allow_links', 'yes'),
|
||||||
|
'wopi_url' => $this->settings->getAppValue('richdocuments', 'wopi_url'),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$policy = new ContentSecurityPolicy();
|
$policy = new ContentSecurityPolicy();
|
||||||
//$policy->addAllowedChildSrcDomain('\'self\' http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js http://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.12/jquery.mousewheel.min.js \'unsafe-eval\'');
|
+ $policy->addAllowedScriptDomain('\'self\' http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js http://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.12/jquery.mousewheel.min.js \'unsafe-eval\' ' . $this->settings->getAppValue('richdocuments', 'wopi_url'));
|
||||||
$policy->addAllowedScriptDomain('\'self\' http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js http://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.12/jquery.mousewheel.min.js \'unsafe-eval\'');
|
+ $policy->addAllowedFrameDomain('\'self\' http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js http://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.12/jquery.mousewheel.min.js \'unsafe-eval\' ' . $this->settings->getAppValue('richdocuments', 'wopi_url'));
|
||||||
$policy->addAllowedFrameDomain('\'self\' http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js http://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.12/jquery.mousewheel.min.js \'unsafe-eval\'');
|
|
||||||
$policy->addAllowedConnectDomain('ws://' . $_SERVER['SERVER_NAME'] . ':9980');
|
$policy->addAllowedConnectDomain('ws://' . $_SERVER['SERVER_NAME'] . ':9980');
|
||||||
$policy->addAllowedImageDomain('*');
|
$policy->addAllowedImageDomain('*');
|
||||||
$policy->allowInlineScript(true);
|
$policy->allowInlineScript(true);
|
||||||
|
@ -22,18 +22,18 @@ use OCA\Richdocuments\Converter;
|
|||||||
use OCA\Richdocuments\Filter;
|
use OCA\Richdocuments\Filter;
|
||||||
|
|
||||||
class SettingsController extends Controller{
|
class SettingsController extends Controller{
|
||||||
|
|
||||||
private $userId;
|
private $userId;
|
||||||
private $l10n;
|
private $l10n;
|
||||||
private $appConfig;
|
private $appConfig;
|
||||||
|
|
||||||
public function __construct($appName, IRequest $request, IL10N $l10n, AppConfig $appConfig, $userId){
|
public function __construct($appName, IRequest $request, IL10N $l10n, AppConfig $appConfig, $userId){
|
||||||
parent::__construct($appName, $request);
|
parent::__construct($appName, $request);
|
||||||
$this->userId = $userId;
|
$this->userId = $userId;
|
||||||
$this->l10n = $l10n;
|
$this->l10n = $l10n;
|
||||||
$this->appConfig = $appConfig;
|
$this->appConfig = $appConfig;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @NoAdminRequired
|
* @NoAdminRequired
|
||||||
*/
|
*/
|
||||||
@ -43,47 +43,48 @@ class SettingsController extends Controller{
|
|||||||
'mimes' => Filter::getAll()
|
'mimes' => Filter::getAll()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @NoAdminRequired
|
* @NoAdminRequired
|
||||||
* @NoCSRFRequired
|
* @NoCSRFRequired
|
||||||
*/
|
*/
|
||||||
public function personalIndex(){
|
public function personalIndex(){
|
||||||
return new TemplateResponse(
|
return new TemplateResponse(
|
||||||
$this->appName,
|
$this->appName,
|
||||||
'personal',
|
'personal',
|
||||||
[ 'save_path' => $this->appConfig->getUserValue($this->userId, 'save_path') ],
|
[ 'save_path' => $this->appConfig->getUserValue($this->userId, 'save_path') ],
|
||||||
'blank'
|
'blank'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @NoCSRFRequired
|
* @NoCSRFRequired
|
||||||
*/
|
*/
|
||||||
public function settingsIndex(){
|
public function settingsIndex(){
|
||||||
return new TemplateResponse(
|
return new TemplateResponse(
|
||||||
$this->appName,
|
$this->appName,
|
||||||
'settings',
|
'settings',
|
||||||
[ 'unstable' => $this->appConfig->getAppValue('unstable') ],
|
[ 'unstable' => $this->appConfig->getAppValue('unstable') ],
|
||||||
'blank'
|
'blank'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @NoCSRFRequired
|
* @NoCSRFRequired
|
||||||
*/
|
*/
|
||||||
public function adminIndex(){
|
public function adminIndex(){
|
||||||
return new TemplateResponse(
|
return new TemplateResponse(
|
||||||
$this->appName,
|
$this->appName,
|
||||||
'admin',
|
'admin',
|
||||||
[
|
[
|
||||||
'converter' => $this->appConfig->getAppValue('converter'),
|
'converter' => $this->appConfig->getAppValue('converter'),
|
||||||
|
'wopi_url' => $this->appConfig->getAppValue('wopi_url'),
|
||||||
'converter_url' => $this->appConfig->getAppValue('converter_url'),
|
'converter_url' => $this->appConfig->getAppValue('converter_url'),
|
||||||
],
|
],
|
||||||
'blank'
|
'blank'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @NoAdminRequired
|
* @NoAdminRequired
|
||||||
*/
|
*/
|
||||||
@ -95,7 +96,7 @@ class SettingsController extends Controller{
|
|||||||
if (\OC\Files\Filesystem::file_exists($savePath) === false ){
|
if (\OC\Files\Filesystem::file_exists($savePath) === false ){
|
||||||
$status = \OC\Files\Filesystem::mkdir($savePath);
|
$status = \OC\Files\Filesystem::mkdir($savePath);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($status){
|
if ($status){
|
||||||
$this->appConfig->setUserValue($this->userId, 'save_path', $savePath);
|
$this->appConfig->setUserValue($this->userId, 'save_path', $savePath);
|
||||||
$response = array(
|
$response = array(
|
||||||
@ -112,33 +113,37 @@ class SettingsController extends Controller{
|
|||||||
}
|
}
|
||||||
return $response;
|
return $response;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function setUnstable($unstable){
|
public function setUnstable($unstable){
|
||||||
if (!is_null($unstable)){
|
if (!is_null($unstable)){
|
||||||
$this->appConfig->setAppValue('unstable', $unstable);
|
$this->appConfig->setAppValue('unstable', $unstable);
|
||||||
}
|
}
|
||||||
return array('status' => 'success');
|
return array('status' => 'success');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function setConverter($converter, $url){
|
public function setConverter($converter, $wopi_url, $url){
|
||||||
if (!is_null($converter)){
|
if (!is_null($converter)){
|
||||||
$this->appConfig->setAppValue('converter', $converter);
|
$this->appConfig->setAppValue('converter', $converter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!is_null($wopi_url)){
|
||||||
|
$this->appConfig->setAppValue('wopi_url', $wopi_url);
|
||||||
|
}
|
||||||
|
|
||||||
if (!is_null($url)){
|
if (!is_null($url)){
|
||||||
$this->appConfig->setAppValue('converter_url', $url);
|
$this->appConfig->setAppValue('converter_url', $url);
|
||||||
}
|
}
|
||||||
|
|
||||||
$response = array(
|
$response = array(
|
||||||
'status' => 'success',
|
'status' => 'success',
|
||||||
'data' => array('message' => (string) $this->l10n->t('Saved'))
|
'data' => array('message' => (string) $this->l10n->t('Saved'))
|
||||||
);
|
);
|
||||||
|
|
||||||
$currentConverter = $this->appConfig->getAppValue('converter');
|
$currentConverter = $this->appConfig->getAppValue('converter');
|
||||||
if ($currentConverter == 'external'){
|
if ($currentConverter == 'external'){
|
||||||
if (!Converter::checkConnection()){
|
if (!Converter::checkConnection()){
|
||||||
\OC::$server->getLogger()->warning(
|
\OC::$server->getLogger()->warning(
|
||||||
'Bad response from Format Filter Server',
|
'Bad response from Format Filter Server',
|
||||||
['app' => $this->appName]
|
['app' => $this->appName]
|
||||||
);
|
);
|
||||||
$response = array(
|
$response = array(
|
||||||
@ -150,7 +155,7 @@ class SettingsController extends Controller{
|
|||||||
} elseif ($currentConverter === 'local') {
|
} elseif ($currentConverter === 'local') {
|
||||||
try {
|
try {
|
||||||
if (!Converter::testConversion()){
|
if (!Converter::testConversion()){
|
||||||
$response = array(
|
$response = array(
|
||||||
'status' => 'error',
|
'status' => 'error',
|
||||||
'data'=>
|
'data'=>
|
||||||
array('message' => (string) $this->l10n->t('Conversion failed. Check log for details.') )
|
array('message' => (string) $this->l10n->t('Conversion failed. Check log for details.') )
|
||||||
@ -163,7 +168,7 @@ class SettingsController extends Controller{
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return $response;
|
return $response;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
17
js/admin.js
17
js/admin.js
@ -1,32 +1,33 @@
|
|||||||
/*global OC, $ */
|
/*global OC, $ */
|
||||||
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
var documentsSettings = {
|
var documentsSettings = {
|
||||||
save : function() {
|
save : function() {
|
||||||
$('#docs_apply').attr('disabled', true);
|
$('#docs_apply').attr('disabled', true);
|
||||||
var data = {
|
var data = {
|
||||||
converter : $('[name="docs_converter"]:checked').val()
|
converter : $('[name="docs_converter"]:checked').val(),
|
||||||
};
|
wopi_url : $('#wopi_url').val()
|
||||||
|
};
|
||||||
|
|
||||||
if (data.converter === 'external'){
|
if (data.converter === 'external'){
|
||||||
data.url = $('#docs_url').val();
|
data.url = $('#docs_url').val();
|
||||||
}
|
}
|
||||||
|
|
||||||
OC.msg.startAction('#documents-admin-msg', t('richdocuments', 'Saving...'));
|
OC.msg.startAction('#documents-admin-msg', t('richdocuments', 'Saving...'));
|
||||||
$.post(
|
$.post(
|
||||||
OC.filePath('richdocuments', 'ajax', 'admin.php'),
|
OC.filePath('richdocuments', 'ajax', 'admin.php'),
|
||||||
data,
|
data,
|
||||||
documentsSettings.afterSave
|
documentsSettings.afterSave
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
afterSave : function(response){
|
afterSave : function(response){
|
||||||
$('#docs_apply').attr('disabled', false);
|
$('#docs_apply').attr('disabled', false);
|
||||||
OC.msg.finishedAction('#documents-admin-msg', response);
|
OC.msg.finishedAction('#documents-admin-msg', response);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
$('#docs_converter_external, #docs_converter_local, #docs_converter_off').on('click', function(){
|
$('#docs_converter_external, #docs_converter_local, #docs_converter_off').on('click', function(){
|
||||||
$('#docs_extra').toggle($('[name="docs_converter"]:checked').val() === 'external');
|
$('#docs_extra').toggle($('[name="docs_converter"]:checked').val() === 'external');
|
||||||
});
|
});
|
||||||
|
@ -179,22 +179,28 @@ var documentsMain = {
|
|||||||
$(document.body).prepend(documentsMain.UI.container);
|
$(document.body).prepend(documentsMain.UI.container);
|
||||||
|
|
||||||
$('title').text(title + ' - ' + documentsMain.UI.mainTitle);
|
$('title').text(title + ' - ' + documentsMain.UI.mainTitle);
|
||||||
var viewer = window.location.protocol + '//' + window.location.host + '/loleaflet/dist/loleaflet.html?' +
|
|
||||||
'file_path=' + documentsMain.url +
|
|
||||||
'&host=' + 'ws://' + window.location.hostname + ':9980' +
|
|
||||||
'&permission=' + 'view' +
|
|
||||||
'×tamp=' + '';
|
|
||||||
|
|
||||||
var frame = '<iframe id="loleafletframe" allowfullscreen style="width:100%;height:100%;position:absolute;" src="' + viewer + '" sandbox="allow-scripts allow-same-origin allow-popups allow-modals"/>';
|
// TODO. wopiurl = get from discovery xml
|
||||||
|
var wopiurl = $('#wopi-url').val() + '/loleaflet/dist/loleaflet.html';
|
||||||
|
var wopisrc = documentsMain.url;
|
||||||
|
var action = wopiurl + '?' + wopisrc;
|
||||||
|
var token = oc_requesttoken;
|
||||||
|
|
||||||
|
var form = '<form id="loleafletform" name="loleafletform" target="loleafletframe" action="' + action + '" method="post">' +
|
||||||
|
'<input name="access_token" value="' + token + '" type="hidden"/></form>';
|
||||||
|
var frame = '<iframe id="loleafletframe" name= "loleafletframe" allowfullscreen style="width:100%;height:100%;position:absolute;"/>';
|
||||||
|
|
||||||
|
$('#mainContainer').append(form);
|
||||||
$('#mainContainer').append(frame);
|
$('#mainContainer').append(frame);
|
||||||
documentsMain.overlay.documentOverlay('hide');
|
documentsMain.overlay.documentOverlay('hide');
|
||||||
$('#loleafletframe').load(function(){
|
$('#loleafletframe').load(function(){
|
||||||
var iframe = $('#loleafletframe').contents();
|
// avoid Blocked a frame with origin different domains
|
||||||
|
|
||||||
|
/*var iframe = $('#loleafletframe').contents();
|
||||||
iframe.find('#tb_toolbar-up_item_close').click(function() {
|
iframe.find('#tb_toolbar-up_item_close').click(function() {
|
||||||
documentsMain.onClose();
|
documentsMain.onClose();
|
||||||
});
|
});*/
|
||||||
var frameWindow = $('#loleafletframe')[0].contentWindow;
|
/*var frameWindow = $('#loleafletframe')[0].contentWindow;
|
||||||
(function() {
|
(function() {
|
||||||
cloudSuiteOnClick = frameWindow.onClick;
|
cloudSuiteOnClick = frameWindow.onClick;
|
||||||
frameWindow.onClick = function() {
|
frameWindow.onClick = function() {
|
||||||
@ -203,8 +209,9 @@ var documentsMain = {
|
|||||||
cloudSuiteOnClick.apply(this, arguments);
|
cloudSuiteOnClick.apply(this, arguments);
|
||||||
frameWindow.map.options.doc = documentsMain.url;
|
frameWindow.map.options.doc = documentsMain.url;
|
||||||
};
|
};
|
||||||
})();
|
})();*/
|
||||||
});
|
});
|
||||||
|
$('#loleafletform').submit();
|
||||||
},
|
},
|
||||||
|
|
||||||
hideEditor : function(){
|
hideEditor : function(){
|
||||||
@ -499,25 +506,12 @@ var documentsMain = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
loadDocument: function() {
|
loadDocument: function() {
|
||||||
var url = OC.generateUrl('apps/richdocuments/load/{file_id}', {file_id: documentsMain.fileId});
|
// Provides access to information about a file and allows
|
||||||
$.post(
|
// for file-level operations.
|
||||||
url,
|
// HTTP://server/<...>/wopi*/files/<id>
|
||||||
{},
|
var url = window.location.protocol + '//' + window.location.host + OC.generateUrl('apps/documents/wopi/files/{file_id}', {file_id: documentsMain.fileId}, false);
|
||||||
function(result) {
|
documentsMain.url = 'WOPISrc=' + encodeURIComponent(url);
|
||||||
if (result && result.status === 'error') {
|
documentsMain.UI.showEditor(documentsMain.fileName);
|
||||||
if (result.message){
|
|
||||||
documentsMain.IU.notify(result.message);
|
|
||||||
}
|
|
||||||
documentsMain.onEditorShutdown(t('richdocuments', 'Failed to load this document. Please check if it can be opened with an external editor. This might also mean it has been unshared or deleted recently.'));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
documentsMain.url = 'file://' + result.filename;
|
|
||||||
documentsMain.baseName = result.basename;
|
|
||||||
|
|
||||||
documentsMain.UI.showEditor(documentsMain.fileName);
|
|
||||||
}
|
|
||||||
);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
saveDocumentBack: function() {
|
saveDocumentBack: function() {
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
* This file is licensed under the Affero General Public License version 3 or
|
* This file is licensed under the Affero General Public License version 3 or
|
||||||
* later.
|
* later.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
namespace OCA\Richdocuments;
|
namespace OCA\Richdocuments;
|
||||||
|
|
||||||
use \OCP\IConfig;
|
use \OCP\IConfig;
|
||||||
@ -18,15 +18,16 @@ use \OCP\IConfig;
|
|||||||
private $defaults = [
|
private $defaults = [
|
||||||
'converter' => 'off',
|
'converter' => 'off',
|
||||||
'converter_url' => 'http://localhost:16080',
|
'converter_url' => 'http://localhost:16080',
|
||||||
'unstable' => 'false'
|
'unstable' => 'false',
|
||||||
|
'wopi_url' => 'htpp://localhost'
|
||||||
];
|
];
|
||||||
|
|
||||||
private $config;
|
private $config;
|
||||||
|
|
||||||
public function __construct(IConfig $config) {
|
public function __construct(IConfig $config) {
|
||||||
$this->config = $config;
|
$this->config = $config;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Can we convert anything to odt?
|
* Can we convert anything to odt?
|
||||||
* @return bool
|
* @return bool
|
||||||
@ -34,7 +35,7 @@ use \OCP\IConfig;
|
|||||||
public function isConverterEnabled(){
|
public function isConverterEnabled(){
|
||||||
return $this->getAppValue('converter') !== 'off';
|
return $this->getAppValue('converter') !== 'off';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get a value by key
|
* Get a value by key
|
||||||
* @param string $key
|
* @param string $key
|
||||||
@ -57,7 +58,7 @@ use \OCP\IConfig;
|
|||||||
public function setAppValue($key, $value) {
|
public function setAppValue($key, $value) {
|
||||||
return $this->config->setAppValue($this->appName, $key, $value);
|
return $this->config->setAppValue($this->appName, $key, $value);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get a value by key for a user
|
* Get a value by key for a user
|
||||||
* @param string $userId
|
* @param string $userId
|
||||||
@ -83,4 +84,4 @@ use \OCP\IConfig;
|
|||||||
return $this->config->setAppValue($userId, $this->appName, $key, $value);
|
return $this->config->setAppValue($userId, $this->appName, $key, $value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,34 +5,39 @@ script('richdocuments', 'admin');
|
|||||||
<h2><?php p($l->t('Documents')) ?></h2>
|
<h2><?php p($l->t('Documents')) ?></h2>
|
||||||
<p><?php p($l->t('MS Word support (requires openOffice/libreOffice)')) ?></p>
|
<p><?php p($l->t('MS Word support (requires openOffice/libreOffice)')) ?></p>
|
||||||
<p>
|
<p>
|
||||||
<input type="radio" name="docs_converter" value="local" id="docs_converter_local"
|
<input type="radio" name="docs_converter" value="local" id="docs_converter_local"
|
||||||
<?php print_unescaped($_['converter']=='local' ? 'checked="checked"' : '') ?>
|
<?php print_unescaped($_['converter']=='local' ? 'checked="checked"' : '') ?>
|
||||||
/>
|
/>
|
||||||
<label for="docs_converter_local"><?php p($l->t('Local')) ?></label><br>
|
<label for="docs_converter_local"><?php p($l->t('Local')) ?></label><br>
|
||||||
<em><?php p($l->t('openOffice/libreOffice is installed on this server. Path to binary is provided via preview_libreoffice_path in config.php')) ?></em>
|
<em><?php p($l->t('openOffice/libreOffice is installed on this server. Path to binary is provided via preview_libreoffice_path in config.php')) ?></em>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<input type="radio" name="docs_converter" value="external" id="docs_converter_external"
|
<input type="radio" name="docs_converter" value="external" id="docs_converter_external"
|
||||||
<?php print_unescaped($_['converter']=='external' ? 'checked="checked"' : '') ?>
|
<?php print_unescaped($_['converter']=='external' ? 'checked="checked"' : '') ?>
|
||||||
/>
|
/>
|
||||||
<label for="docs_converter_external"><?php p($l->t('External')) ?></label><br>
|
<label for="docs_converter_external"><?php p($l->t('External')) ?></label><br>
|
||||||
<em><?php p($l->t('openOffice/libreOffice is installed on external server running a format filter server')) ?></em>
|
<em><?php p($l->t('openOffice/libreOffice is installed on external server running a format filter server')) ?></em>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<input type="radio" name="docs_converter" value="off" id="docs_converter_off"
|
<input type="radio" name="docs_converter" value="off" id="docs_converter_off"
|
||||||
<?php print_unescaped($_['converter']=='off' ? 'checked="checked"' : '') ?>
|
<?php print_unescaped($_['converter']=='off' ? 'checked="checked"' : '') ?>
|
||||||
/>
|
/>
|
||||||
<label for="docs_converter_off"><?php p($l->t('Disabled')) ?></label><br>
|
<label for="docs_converter_off"><?php p($l->t('Disabled')) ?></label><br>
|
||||||
<em><?php p($l->t('No MS Word support')) ?></em>
|
<em><?php p($l->t('No MS Word support')) ?></em>
|
||||||
</p>
|
</p>
|
||||||
<div id="docs_extra" <?php print_unescaped($_['converter']!=='external' ? 'style="display:none"' : '') ?>>
|
<div id="docs_extra" <?php print_unescaped($_['converter']!=='external' ? 'style="display:none"' : '') ?>>
|
||||||
<input type="text" name="docs_url" id="docs_url"
|
<input type="text" name="docs_url" id="docs_url"
|
||||||
value="<?php p($_['converter_url'])?>"
|
value="<?php p($_['converter_url'])?>"
|
||||||
original-title="<?php p($l->t('scheme://domain.tld[:port]')) ?>"
|
original-title="<?php p($l->t('scheme://domain.tld[:port]')) ?>"
|
||||||
style="width:250px;"
|
style="width:250px;"
|
||||||
/>
|
/>
|
||||||
<br /><em><?php p($l->t('Server URL')) ?></em>
|
<br /><em><?php p($l->t('Server URL')) ?></em>
|
||||||
</div>
|
</div>
|
||||||
|
<br />
|
||||||
|
<div id="wopi_client">
|
||||||
|
<input type="text" name="wopi_url" id="wopi_url" value="<?php p($_['wopi_url'])?>" style="width:250px;">
|
||||||
|
<br /><em><?php p($l->t('WOPI Client')) ?></em>
|
||||||
|
</div>
|
||||||
<br /><button type="button" id="docs_apply"><?php p($l->t('Apply and test')) ?></button>
|
<br /><button type="button" id="docs_apply"><?php p($l->t('Apply and test')) ?></button>
|
||||||
<span id="documents-admin-msg" class="msg"></span>
|
<span id="documents-admin-msg" class="msg"></span>
|
||||||
</div>
|
</div>
|
||||||
|
@ -13,7 +13,7 @@ script('files', 'jquery.fileupload');
|
|||||||
<li class="add-document">
|
<li class="add-document">
|
||||||
<a class="icon-add add-odt svg" target="_blank" href="">
|
<a class="icon-add add-odt svg" target="_blank" href="">
|
||||||
<label><?php p($l->t('New Document')) ?></label>
|
<label><?php p($l->t('New Document')) ?></label>
|
||||||
</a>
|
</a>
|
||||||
<a class="icon-add add-ods svg" target="_blank" href="">
|
<a class="icon-add add-ods svg" target="_blank" href="">
|
||||||
<label><?php p($l->t('New Spreadsheet')) ?></label>
|
<label><?php p($l->t('New Spreadsheet')) ?></label>
|
||||||
</a>
|
</a>
|
||||||
@ -50,6 +50,7 @@ script('files', 'jquery.fileupload');
|
|||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
<input type="hidden" id="wopi-url" name="wopi-url" value="<?php p($_['wopi_url']) ?>" />
|
||||||
<input type="hidden" id="webodf-unstable" value="<?php p($_['useUnstable']) ?>" />
|
<input type="hidden" id="webodf-unstable" value="<?php p($_['useUnstable']) ?>" />
|
||||||
<?php if ($_['enable_previews']): ?>
|
<?php if ($_['enable_previews']): ?>
|
||||||
<input type="hidden" id="previews_enabled" value="<?php p($_['enable_previews']) ?>" />
|
<input type="hidden" id="previews_enabled" value="<?php p($_['enable_previews']) ?>" />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user