Commit f58d920b by Andy Armstrong

Hide the navigation bar when sorting won't work

parent 9bbf9639
...@@ -100,7 +100,8 @@ ...@@ -100,7 +100,8 @@
this.threadListView = new DiscussionThreadListView({ this.threadListView = new DiscussionThreadListView({
el: this.$('.inline-threads'), el: this.$('.inline-threads'),
collection: self.discussion, collection: self.discussion,
courseSettings: self.course_settings courseSettings: self.course_settings,
hideRefineBar: true // TODO: re-enable the search/filter bar when it works correctly
}); });
this.threadListView.render(); this.threadListView.render();
......
...@@ -91,6 +91,7 @@ ...@@ -91,6 +91,7 @@
DiscussionThreadListView.prototype.initialize = function(options) { DiscussionThreadListView.prototype.initialize = function(options) {
var self = this; var self = this;
this.courseSettings = options.courseSettings; this.courseSettings = options.courseSettings;
this.hideRefineBar = options.hideRefineBar;
this.supportsActiveThread = options.supportsActiveThread; this.supportsActiveThread = options.supportsActiveThread;
this.displayedCollection = new Discussion(this.collection.models, { this.displayedCollection = new Discussion(this.collection.models, {
pages: this.collection.pages pages: this.collection.pages
...@@ -221,6 +222,9 @@ ...@@ -221,6 +222,9 @@
} }
this.showMetadataAccordingToSort(); this.showMetadataAccordingToSort();
this.renderMorePages(); this.renderMorePages();
if (this.hideRefineBar) {
this.$('.forum-nav-refine-bar').addClass('is-hidden');
}
this.trigger('threads:rendered'); this.trigger('threads:rendered');
}; };
......
...@@ -38,7 +38,8 @@ ...@@ -38,7 +38,8 @@
this.discussionThreadListView = new DiscussionThreadListView({ this.discussionThreadListView = new DiscussionThreadListView({
collection: this.discussion, collection: this.discussion,
el: this.$('.inline-threads'), el: this.$('.inline-threads'),
courseSettings: this.courseSettings courseSettings: this.courseSettings,
hideRefineBar: true // TODO: re-enable the search/filter bar when it works correctly
}).render(); }).render();
this.discussionThreadListView.on('thread:selected', _.bind(this.navigateToThread, this)); this.discussionThreadListView.on('thread:selected', _.bind(this.navigateToThread, this));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment