Selaa lähdekoodia

load file sorting mode from the db

tags/v9.1.0beta1
Christoph Wurst 8 vuotta sitten
vanhempi
commit
3f492dd826

+ 1
- 0
apps/files/controller/viewcontroller.php Näytä tiedosto

@@ -213,6 +213,7 @@ class ViewController extends Controller {
$params['mailNotificationEnabled'] = $this->config->getAppValue('core', 'shareapi_allow_mail_notification', 'no');
$params['mailPublicNotificationEnabled'] = $this->config->getAppValue('core', 'shareapi_allow_public_notification', 'no');
$params['allowShareWithLink'] = $this->config->getAppValue('core', 'shareapi_allow_links', 'yes');
$params['defaultFileSorting'] = $this->config->getAppValue('files', 'file_sorting', 'name');
$params['appNavigation'] = $nav;
$params['appContents'] = $contentItems;
$this->navigationManager->setActiveEntry('files_index');

+ 2
- 1
apps/files/js/app.js Näytä tiedosto

@@ -72,7 +72,8 @@
fileActions: fileActions,
allowLegacyActions: true,
scrollTo: urlParams.scrollto,
filesClient: OC.Files.getClient()
filesClient: OC.Files.getClient(),
sorting: $('#defaultFileSorting').val()
}
);
this.files.initialize();

+ 5
- 1
apps/files/js/filelist.js Näytä tiedosto

@@ -239,7 +239,11 @@

this.fileSummary = this._createSummary();

this.setSort('name', 'asc');
if (options.sorting) {
this.setSort(options.sorting, 'asc');
} else {
this.setSort('name', 'asc');
}

var breadcrumbOptions = {
onClick: _.bind(this._onClickBreadCrumb, this),

+ 1
- 0
apps/files/templates/index.php Näytä tiedosto

@@ -18,4 +18,5 @@
<input type="hidden" name="mailNotificationEnabled" id="mailNotificationEnabled" value="<?php p($_['mailNotificationEnabled']) ?>" />
<input type="hidden" name="mailPublicNotificationEnabled" id="mailPublicNotificationEnabled" value="<?php p($_['mailPublicNotificationEnabled']) ?>" />
<input type="hidden" name="allowShareWithLink" id="allowShareWithLink" value="<?php p($_['allowShareWithLink']) ?>" />
<input type="hidden" name="defaultFileSorting" id="defaultFileSorting" value="<?php p($_['defaultFileSorting']) ?>" />
<?php endif;

Loading…
Peruuta
Tallenna