@brightspace-hmc/siren-sdk
Advanced tools
Comparing version 2.24.0 to 2.24.1
{ | ||
"name": "@brightspace-hmc/siren-sdk", | ||
"version": "2.24.0", | ||
"version": "2.24.1", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "", |
@@ -13,5 +13,9 @@ /** | ||
} | ||
return this._entity.getSubEntitiesByRel(Rels.IPSIS.SISCourseMerge.courseMergeOffering); | ||
return this._entity.entities; | ||
} | ||
prependCourseMergeOfferings(previousCourseMergeOfferingCollectionEntity) { | ||
this._entity.entities.unshift(...previousCourseMergeOfferingCollectionEntity._entity.entities); | ||
} | ||
userOwnedByMultipleSourceSystems() { | ||
@@ -37,2 +41,13 @@ return this._entity?.properties?.userOwnedByMultipleSourceSystems; | ||
loadMorePageSize() { | ||
const pageSize = this._pagingInfo()?.pageSize; | ||
const totalCount = this.totalCount() ?? 0; | ||
const courseMergeOfferingsLength = this.courseMergeOfferings()?.length ?? 0; | ||
// if pageSize is larger than the number remaining items, return the number of remaining items to be loaded | ||
if (totalCount < courseMergeOfferingsLength + (pageSize ?? 0)) { | ||
return totalCount - courseMergeOfferingsLength; | ||
} | ||
return pageSize; | ||
} | ||
_pagingInfo() { | ||
@@ -39,0 +54,0 @@ return this._entity?.properties?.pagingInfo; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
338863
9321