Skip to content
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

Adds railcontent_id to group by fetch all. #74

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

DidierF
Copy link
Contributor

@DidierF DidierF commented Oct 8, 2024

No description provided.

Copy link
Contributor

@roxanariza roxanariza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your updates look good!
For group_by(artist/genre) the railcontent_id will be null always, but I supposed that you want the response structure to be the same; so I am fine with this.

I am not sure why we need "instructor" and "coaches" on fetchLessonContent. Are duplicate data, but with different fields

@@ -518,6 +518,7 @@ export async function fetchAll(brand, type, {
const lessonsFilter = `_type == '${type}' && brand == '${brand}' && ^._id == ${groupBy}._ref ${searchFilter} ${includedFieldsFilter} ${progressFilter}`;
entityFieldsString = `
'id': _id,
railcontent_id,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In this case (grouped by artist), the railcontent_id will always be null.

src/services/sanity.js Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants