musora-content-services 1.0.243 → 1.0.244
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +2 -0
- package/link_mcs.sh +0 -0
- package/package.json +1 -1
- package/src/contentMetaData.js +0 -1
- package/src/services/sanity.js +3 -3
- package/test/sanityQueryService.test.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [1.0.244](https://github.com/railroadmedia/musora-content-services/compare/v1.0.243...v1.0.244) (2024-12-18)
|
|
6
|
+
|
|
5
7
|
### [1.0.243](https://github.com/railroadmedia/musora-content-services/compare/v1.0.242...v1.0.243) (2024-12-18)
|
|
6
8
|
|
|
7
9
|
### [1.0.242](https://github.com/railroadmedia/musora-content-services/compare/v1.0.241...v1.0.242) (2024-12-17)
|
package/link_mcs.sh
CHANGED
|
File without changes
|
package/package.json
CHANGED
package/src/contentMetaData.js
CHANGED
|
@@ -241,7 +241,6 @@ const commonMetadata ={
|
|
|
241
241
|
description: 'Here\'s a list of all lessons recently added to Drumeo. Browse on your own or use search to find whatever it is you\'d like to learn!',
|
|
242
242
|
allowableFilters: ['type'],
|
|
243
243
|
sortBy: '-published_on',
|
|
244
|
-
shortname: 'Lessons',
|
|
245
244
|
tabs: [
|
|
246
245
|
{
|
|
247
246
|
name: 'Lessons',
|
package/src/services/sanity.js
CHANGED
|
@@ -1268,7 +1268,7 @@ export async function fetchRelatedMethodLessons(railContentId, brand) {
|
|
|
1268
1268
|
*/
|
|
1269
1269
|
export async function fetchAllPacks(brand, sort = "-published_on", searchTerm = "", page = 1, limit = 10) {
|
|
1270
1270
|
const sortOrder = getSortOrder(sort, brand);
|
|
1271
|
-
const filter = `_type == 'pack' && brand == '${brand}' && title match "${searchTerm}*"`
|
|
1271
|
+
const filter = `(_type == 'pack' || _type == 'semester-pack') && brand == '${brand}' && title match "${searchTerm}*"`
|
|
1272
1272
|
const filterParams = {};
|
|
1273
1273
|
const fields = getFieldsForContentType('pack');
|
|
1274
1274
|
const start = (page - 1) * limit;
|
|
@@ -1293,8 +1293,8 @@ export async function fetchAllPacks(brand, sort = "-published_on", searchTerm =
|
|
|
1293
1293
|
* @param {string} railcontentId - The Railcontent ID of the pack.
|
|
1294
1294
|
* @returns {Promise<Array<Object>|null>} - The fetched pack content data or null if not found.
|
|
1295
1295
|
*/
|
|
1296
|
-
export async function fetchPackAll(railcontentId) {
|
|
1297
|
-
return fetchByRailContentId(railcontentId,
|
|
1296
|
+
export async function fetchPackAll(railcontentId, type = 'pack') {
|
|
1297
|
+
return fetchByRailContentId(railcontentId, type);
|
|
1298
1298
|
}
|
|
1299
1299
|
|
|
1300
1300
|
export async function fetchLiveEvent(brand) {
|
|
@@ -678,8 +678,8 @@ describe('Sanity Queries', function () {
|
|
|
678
678
|
});
|
|
679
679
|
|
|
680
680
|
test('fetchTopLeveldrafts', async () => {
|
|
681
|
-
let id = await fetchTopLevelParentId(
|
|
682
|
-
expect(id).toBe(
|
|
681
|
+
let id = await fetchTopLevelParentId(401999);
|
|
682
|
+
expect(id).toBe(401999);
|
|
683
683
|
});
|
|
684
684
|
|
|
685
685
|
test('fetchCommentData', async()=>{
|