@contrail/types
Advanced tools
Comparing version 3.0.56 to 3.0.57
@@ -31,5 +31,22 @@ "use strict"; | ||
} | ||
const validCopyPropertyTypes = [ | ||
type_properties_1.PropertyType.Text, | ||
type_properties_1.PropertyType.String, | ||
type_properties_1.PropertyType.Number, | ||
type_properties_1.PropertyType.Currency, | ||
type_properties_1.PropertyType.Percent, | ||
type_properties_1.PropertyType.Date, | ||
type_properties_1.PropertyType.Boolean, | ||
type_properties_1.PropertyType.MultiSelect, | ||
type_properties_1.PropertyType.SingleSelect, | ||
type_properties_1.PropertyType.ObjectReference, | ||
type_properties_1.PropertyType.TypeReference, | ||
type_properties_1.PropertyType.UserList, | ||
type_properties_1.PropertyType.SizeRange, | ||
]; | ||
const propertiesToCopy = entityType.typeProperties.filter(property => (property.copyBehavior === type_properties_1.CopyBehavior.Copy || !property.copyBehavior) && | ||
property.propertyLevel && | ||
[typeLevel, 'overridable', 'all'].includes(property.propertyLevel) && | ||
property.propertyType && | ||
validCopyPropertyTypes.includes(property.propertyType) && | ||
!property.isUniqueProperty); | ||
@@ -39,2 +56,4 @@ const propertiesToDefault = entityType.typeProperties.filter(property => property.copyBehavior === type_properties_1.CopyBehavior.Default && | ||
[typeLevel, 'overridable', 'all'].includes(property.propertyLevel) && | ||
property.propertyType && | ||
validCopyPropertyTypes.includes(property.propertyType) && | ||
!property.isUniqueProperty); | ||
@@ -41,0 +60,0 @@ const propertiesToIgnore = [...new Set(...propertySlugsToIgnore, 'id', 'roles', 'specifiedId')]; |
{ | ||
"name": "@contrail/types", | ||
"version": "3.0.56", | ||
"version": "3.0.57", | ||
"description": "Types Utility module", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
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
77547
1835