Skip to content

Commit f7c721a

Browse files
authored
Merge pull request #77 from cableman/hotfix/loop-468
Hotfix/loop 468
2 parents e841699 + beb6847 commit f7c721a

File tree

3 files changed

+6
-8
lines changed

3 files changed

+6
-8
lines changed

modules/loop_search_node/js/loopSearchBoxController.js

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ angular.module('searchBoxApp').controller('loopSearchBoxController', ['CONFIG',
1313
$scope.searchBtnText = 'Search';
1414
$scope.searching = false;
1515
$scope.selectedFilterCount = 0;
16-
$scope.filterActive = 'docs';
17-
$scope.sortActive = 'default';
16+
$scope.filterActive = 'all';
17+
$scope.sortActive = 'desc';
1818
$scope.showSort = false;
1919
$scope.newSubjects = false;
2020

@@ -140,10 +140,8 @@ angular.module('searchBoxApp').controller('loopSearchBoxController', ['CONFIG',
140140
// Init the query object.
141141
$scope.query = {
142142
'text': '',
143-
'filters': {
144-
'taxonomy': {
145-
'type': documentFilter
146-
}
143+
'sort': {
144+
'created': $scope.sortActive
147145
}
148146
};
149147

modules/loop_search_node/loop_search_node.module

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ function _loop_search_node_box_settings() {
203203
'options' => array(
204204
'match_type' => 'best_fields',
205205
'match_operator' => 'and',
206-
'cache_expire' => 300,
206+
'cache_expire' => 0,
207207
'size' => 8,
208208
'initial_query_enable' => 0,
209209
'initial_query_text' => '',

themes/loop/templates/search/angular/search.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@
4141

4242
<div class="search-filters">
4343
<div class="search-filters--type">
44+
<span class="search-filters--label" data-ng-class="{'is-active': filterActive==='all'}" data-ng-click="filterType('all')">{{ Drupal.t('All', {}, { 'context': 'angular' }) }}</span>
4445
<span class="search-filters--label" data-ng-class="{'is-active': filterActive==='docs'}" data-ng-click="filterType('docs')">{{ Drupal.t('Documents', {}, { 'context': 'angular' }) }}</span>
4546
<span class="search-filters--label" data-ng-class="{'is-active': filterActive==='post'}" data-ng-click="filterType('post')">{{ Drupal.t('Posts', {}, { 'context': 'angular' }) }}</span>
46-
<span class="search-filters--label" data-ng-class="{'is-active': filterActive==='all'}" data-ng-click="filterType('all')">{{ Drupal.t('All', {}, { 'context': 'angular' }) }}</span>
4747
</div>
4848

4949
<span class="search-filters--subject-wrapper" data-ng-class="{'is-active': isFiltersShown}" data-ng-click="toggleFilter()">

0 commit comments

Comments
 (0)