-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/catalogue toggle sort filter bar #1165
Feature/catalogue toggle sort filter bar #1165
Conversation
@@ -1,5 +1,5 @@ | |||
<template name="favourite"> | |||
{{#if isBookmarked}} | |||
{{#if isBookmarked }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add spaces here, e.g. {{ # if isBookmarked }}
👍 |
What happened to the sorting feature here? |
@@ -33,7 +33,7 @@ Meteor.publish('catalogue', function (options) { | |||
}; | |||
|
|||
// Set up query options with sort settings | |||
queryOptions.sort[sortBy] = sortDirection; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@NNN this syntax was probably necessary to make the sort feature work. In effect, we are trying to create an object key from a variable, so square bracket notation is required.
Reference
// Subscribe to API Backends with catalogue settings | ||
instance.subscribe("catalogue", subscriptionOptions); | ||
instance.subscribe("catalogueRatings"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The catalogueRatings
subscription does not need to be inside of the autorun. Only the subscription that changes needs to be defined here. E.g. the catalogue
subscription, since the subscription options change dynamically.
It looks like there was a regression added in the following commit: I.e. the code was switched from object bracket notation to dot notation. The bracket notation was important in this case. |
Closes #1127