Skip to content

Commit

Permalink
Merge pull request #554 from SEED-platform/553-fix-selected-buildings
Browse files Browse the repository at this point in the history
Clear out selected_buildings when select_or_deselect_all_buildings
  • Loading branch information
mmclark committed Dec 14, 2015
2 parents e9afb02 + 0ce6285 commit d1f595b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion seed/static/seed/js/services/search_service.js
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,7 @@ angular.module('BE.seed.service.search', [])
* should **always** be called before load_state_from_selected_buildings.
*/
search_service.select_or_deselect_all_buildings = function() {
this.selected_buildings = [];
for (var i = 0; i < this.buildings.length; i++) {
this.buildings[i].checked = this.select_all_checkbox;
}
Expand All @@ -334,7 +335,6 @@ angular.module('BE.seed.service.search', [])
* checked
*/
search_service.select_all_changed = function(){
this.selected_buildings = [];
this.select_or_deselect_all_buildings();
};

Expand Down

0 comments on commit d1f595b

Please sign in to comment.