Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/issuetemplate.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Controller/APIController.php3
-rw-r--r--lib/IDetail.php1
-rw-r--r--lib/Sections/ServerSection.php21
-rw-r--r--templates/settings-admin.php1
4 files changed, 14 insertions, 12 deletions
diff --git a/lib/Controller/APIController.php b/lib/Controller/APIController.php
index 991e708..ec4a9ae 100644
--- a/lib/Controller/APIController.php
+++ b/lib/Controller/APIController.php
@@ -111,6 +111,9 @@ class APIController extends Controller {
case IDetail::TYPE_SINGLE_LINE:
return 'input';
break;
+ case IDetail::TYPE_BOOLEAN:
+ return 'checkbox';
+ break;
default:
return 'textArea';
break;
diff --git a/lib/IDetail.php b/lib/IDetail.php
index f05c9fb..b0af18b 100644
--- a/lib/IDetail.php
+++ b/lib/IDetail.php
@@ -29,6 +29,7 @@ interface IDetail {
const TYPE_MULTI_LINE_PREFORMAT = 2;
const TYPE_COLLAPSIBLE = 3;
const TYPE_COLLAPSIBLE_PREFORMAT = 4;
+ const TYPE_BOOLEAN = 5;
/**
* Returns a unique identifier for the detail value
diff --git a/lib/Sections/ServerSection.php b/lib/Sections/ServerSection.php
index 354cdb8..c823d13 100644
--- a/lib/Sections/ServerSection.php
+++ b/lib/Sections/ServerSection.php
@@ -58,7 +58,7 @@ class ServerSection extends Section {
$this->createDetail('Operating system', $this->getOsVersion());
$this->createDetail('Webserver', $this->getWebserver());
$this->createDetail('Database', $this->getDatabaseInfo());
- $this->createDetail('PHP version', $this->getPhpVersion());
+ $this->createDetail('PHP version', $this->getPhpVersion(), IDetail::TYPE_MULTI_LINE);
$this->createDetail('Nextcloud version', $this->getNextcloudVersion());
$this->createDetail('Updated from an older Nextcloud/ownCloud or fresh install', '');
$this->createDetail('Where did you install Nextcloud from', $this->getInstallMethod());
@@ -68,19 +68,16 @@ class ServerSection extends Section {
$this->createDetail('Configuration (config/config.php)', print_r(json_encode($this->getConfig(), JSON_PRETTY_PRINT), true), IDetail::TYPE_COLLAPSIBLE_PREFORMAT);
$this->createDetail('Are you using external storage, if yes which one', 'local/smb/sftp/...');
- $this->createDetail('Are you using encryption', $this->getEncryptionInfo());
+ $this->createDetail('Are you using encryption', $this->getEncryptionInfo() === 'yes' ? true : false, IDetail::TYPE_BOOLEAN);
$this->createDetail('Are you using an external user-backend, if yes which one', 'LDAP/ActiveDirectory/Webdav/...');
- $this->createDetail('LDAP configuration (delete this part if not used)', 'With access to your command line run e.g.:
-sudo -u www-data php occ ldap:show-config
-from within your Nextcloud installation folder
-
-Without access to your command line download the data/owncloud.db to your local
-computer or access your SQL server remotely and run the select query:
-SELECT * FROM `oc_appconfig` WHERE `appid` = \'user_ldap\';
-
-
-Eventually replace sensitive data as the name/IP-address of your LDAP server or groups.', IDetail::TYPE_COLLAPSIBLE_PREFORMAT);
+ if($this->appManager->isEnabledForUser('user_ldap')) {
+ $ldap = '';
+ foreach ($this->config->getAppKeys('user_ldap') as $key) {
+ $ldap .= $key . ': ' . $this->config->getAppValue('user_ldap', $key);
+ }
+ $this->createDetail('LDAP configuration (delete this par if not used)', $ldap, IDetail::TYPE_COLLAPSIBLE_PREFORMAT);
+ }
}
private function getWebserver() {
if (isset($_SERVER['SERVER_SOFTWARE']) && !empty($_SERVER['SERVER_SOFTWARE'])) {
diff --git a/templates/settings-admin.php b/templates/settings-admin.php
index 575c384..79aaca6 100644
--- a/templates/settings-admin.php
+++ b/templates/settings-admin.php
@@ -46,6 +46,7 @@
</tab-content>
</form-wizard>
+ <h3>Debug output</h3>
<pre v-if="model" v-html="prettyJSON(model)"></pre>
</div>