Fix ordering of channels
As channels aren't added right away (but as soon as the info was received from the server), somehow the orderBy didn't do its job.
This commit is contained in:
parent
c03dc77e49
commit
c4d29a7eb0
2 changed files with 3 additions and 2 deletions
|
@ -224,7 +224,7 @@ $ openssl req -nodes -newkey rsa:2048 -keyout relay.pem -x509 -days 365 -out rel
|
||||||
<input class="form-control monospace" type="text" id="bufferFilter" ng-model="search" ng-keydown="handleSearchBoxKey($event)" placeholder="Search">
|
<input class="form-control monospace" type="text" id="bufferFilter" ng-model="search" ng-keydown="handleSearchBoxKey($event)" placeholder="Search">
|
||||||
</form>
|
</form>
|
||||||
</li>
|
</li>
|
||||||
<li class="buffer" ng-class="{'active': content.active }" ng-repeat="(key, content) in buffers | toArray | filter:{fullName:search} | filter:hasUnread | orderBy:'content.number':true">
|
<li class="buffer" ng-class="{'active': content.active }" ng-repeat="(key, content) in buffers | toArray | filter:{fullName:search} | filter:hasUnread | orderBy:predicate">
|
||||||
<a href="#" ng-click="setActiveBuffer(content.id)" title="{{ content.fullName }}">
|
<a href="#" ng-click="setActiveBuffer(content.id)" title="{{ content.fullName }}">
|
||||||
<span class="badge pull-right" ng-hide="content.notification" ng-if="content.unread" ng-bind="content.unread"></span>
|
<span class="badge pull-right" ng-hide="content.notification" ng-if="content.unread" ng-bind="content.unread"></span>
|
||||||
<span class="badge pull-right danger" ng-show="content.notification" ng-bind="content.notification"></span>
|
<span class="badge pull-right danger" ng-show="content.notification" ng-bind="content.notification"></span>
|
||||||
|
@ -236,7 +236,7 @@ $ openssl req -nodes -newkey rsa:2048 -keyout relay.pem -x509 -days 365 -out rel
|
||||||
<div id="bufferlines" class="monospace" ng-class="{'withnicklist': showNicklist}">
|
<div id="bufferlines" class="monospace" ng-class="{'withnicklist': showNicklist}">
|
||||||
<div id="nicklist" ng-show="showNicklist" class="vertical-line-left">
|
<div id="nicklist" ng-show="showNicklist" class="vertical-line-left">
|
||||||
<ul class="nicklistgroup list-unstyled" ng-repeat="group in activeBuffer().nicklist">
|
<ul class="nicklistgroup list-unstyled" ng-repeat="group in activeBuffer().nicklist">
|
||||||
<li class="" ng-repeat="nick in group.nicks|orderBy:'nick.name'">
|
<li class="" ng-repeat="nick in group.nicks|orderBy:name">
|
||||||
<a ng-click="nickAction(nick)"><span ng-class="nick.prefixClasses">{{nick.prefix}}</span><span ng-class="nick.nameClasses">{{nick.name}}</span></a>
|
<a ng-click="nickAction(nick)"><span ng-class="nick.prefixClasses">{{nick.prefix}}</span><span ng-class="nick.nameClasses">{{nick.name}}</span></a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -315,6 +315,7 @@ weechat.factory('connection', ['$q', '$rootScope', '$log', '$store', 'handlers',
|
||||||
models.setActiveBuffer(buffer.id);
|
models.setActiveBuffer(buffer.id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
$rootScope.predicate = 'number';
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue