Move encryption settings to security

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2018-08-01 09:40:21 +02:00
parent 10de5f219c
commit 03971d3695
No known key found for this signature in database
GPG Key ID: 4C614C6ED2CDE6DF
4 changed files with 7 additions and 10 deletions

View File

@ -110,7 +110,7 @@ class Admin implements ISettings {
* @return string the section ID, e.g. 'sharing'
*/
public function getSection() {
return 'encryption';
return 'security';
}
/**
@ -121,7 +121,7 @@ class Admin implements ISettings {
* E.g.: 70
*/
public function getPriority() {
return 5;
return 11;
}
}

View File

@ -77,7 +77,7 @@ class Encryption implements ISettings {
* @return string the section ID, e.g. 'sharing'
*/
public function getSection() {
return 'encryption';
return 'security';
}
/**
@ -88,6 +88,6 @@ class Encryption implements ISettings {
* E.g.: 70
*/
public function getPriority() {
return 0;
return 10;
}
}

View File

@ -230,7 +230,6 @@ class Manager implements IManager {
1 => [new Section('server', $this->l->t('Basic settings'), 0, $this->url->imagePath('core', 'actions/settings-dark.svg'))],
5 => [new Section('sharing', $this->l->t('Sharing'), 0, $this->url->imagePath('core', 'actions/share.svg'))],
10 => [new Section('security', $this->l->t('Security'), 0, $this->url->imagePath('core', 'actions/password.svg'))],
45 => [new Section('encryption', $this->l->t('Encryption'), 0, $this->url->imagePath('core', 'actions/password.svg'))],
50 => [new Section('groupware', $this->l->t('Groupware'), 0, $this->url->imagePath('core', 'places/contacts.svg'))],
98 => [new Section('additional', $this->l->t('Additional settings'), 0, $this->url->imagePath('core', 'actions/settings-dark.svg'))],
];
@ -270,7 +269,7 @@ class Manager implements IManager {
$form = new Admin\Mail($this->config);
$forms[$form->getPriority()] = [$form];
}
if ($section === 'encryption') {
if ($section === 'security') {
/** @var ISettings $form */
$form = new Admin\Encryption($this->encryptionManager, $this->userManager);
$forms[$form->getPriority()] = [$form];

View File

@ -115,7 +115,7 @@ class ManagerTest extends TestCase {
$this->manager->registerSection('admin', \OCA\WorkflowEngine\Settings\Section::class);
$this->url->expects($this->exactly(7))
$this->url->expects($this->exactly(6))
->method('imagePath')
->willReturnMap([
['settings', 'admin.svg', '0'],
@ -131,7 +131,6 @@ class ManagerTest extends TestCase {
1 => [new Section('server', 'Basic settings', 0, '1')],
5 => [new Section('sharing', 'Sharing', 0, '2')],
10 => [new Section('security', 'Security', 0, '3')],
45 => [new Section('encryption', 'Encryption', 0, '3')],
50 => [new Section('groupware', 'Groupware', 0, '5')],
55 => [\OC::$server->query(\OCA\WorkflowEngine\Settings\Section::class)],
98 => [new Section('additional', 'Additional settings', 0, '1')],
@ -168,7 +167,7 @@ class ManagerTest extends TestCase {
->method('t')
->will($this->returnArgument(0));
$this->url->expects($this->exactly(7))
$this->url->expects($this->exactly(6))
->method('imagePath')
->willReturnMap([
['settings', 'admin.svg', '0'],
@ -184,7 +183,6 @@ class ManagerTest extends TestCase {
1 => [new Section('server', 'Basic settings', 0, '1')],
5 => [new Section('sharing', 'Sharing', 0, '2')],
10 => [new Section('security', 'Security', 0, '3')],
45 => [new Section('encryption', 'Encryption', 0, '3')],
50 => [new Section('groupware', 'Groupware', 0, '5')],
98 => [new Section('additional', 'Additional settings', 0, '1')],
], $this->manager->getAdminSections());