Fix javascript error

This commit is contained in:
Raimund Schlüßler 2017-09-03 11:40:39 +02:00
parent 73736f33e1
commit 92293b1a26
No known key found for this signature in database
GPG key ID: 036FA7EB1A599178
3 changed files with 13 additions and 13 deletions

View file

@ -361,17 +361,17 @@
switch (_$scope.settingsmodel.getById('various').sortOrder) {
case 'due':
case 'start':
return 'calendar';
return 'ico-calendar';
case 'priority':
return 'star';
return 'ico-star';
case 'alphabetically':
return 'alphabetically';
return 'ico-alphabetically';
case 'manual':
return 'manual';
return 'ico-manual';
default:
return 'menu';
return 'ico-menu';
}
}
};
this._$scope.setSortOrder = function($event, order) {
_$scope.settingsmodel.getById('various').sortDirection = (_$scope.settingsmodel.getById('various').sortOrder === order) ? +!_$scope.settingsmodel.getById('various').sortDirection : 0;

View file

@ -1271,17 +1271,17 @@ angular.module('Tasks').controller('SettingsController', [
switch (_$scope.settingsmodel.getById('various').sortOrder) {
case 'due':
case 'start':
return 'calendar';
return 'ico-calendar';
case 'priority':
return 'star';
return 'ico-star';
case 'alphabetically':
return 'alphabetically';
return 'ico-alphabetically';
case 'manual':
return 'manual';
return 'ico-manual';
default:
return 'menu';
return 'ico-menu';
}
}
};
this._$scope.setSortOrder = function($event, order) {
_$scope.settingsmodel.getById('various').sortDirection = (_$scope.settingsmodel.getById('various').sortOrder === order) ? +!_$scope.settingsmodel.getById('various').sortDirection : 0;

View file

@ -159,7 +159,7 @@
<div class="app-navigation-entry-utils">
<div class="app-navigation-entry-utils-menu-button" title="<?php p($l->t('Change sort order')); ?>">
<button class="sortorder-dropdown-button">
<span class="icon ico-{{ getSortOrderIcon() }}"></span>
<span class="icon" ng-class="getSortOrderIcon()"></span>
<span class="icon sort-indicator" ng-class="{'ico-sort-up': settingsmodel.getById('various').sortDirection, 'ico-sort-down': !settingsmodel.getById('various').sortDirection}"></span>
</button>
</div>