@acceleratxr/core_sdk / Product
Class: Product#
Describes a single product that can be purchased by a customer.
REQUIRES: Purchasing Services
author Jean-Philippe Steinmetz info@acceleratxr.com
Hierarchy#
-
↳ Product
Index#
Constructors#
Properties#
Accessors#
Object literals#
Constructors#
constructor#
+ new Product(other?: any): Product
Overrides EntityBase.constructor
Defined in src/models/Product.ts:187
Parameters:#
Name |
Type |
|---|---|
|
any |
Returns: Product
Properties#
background#
• background: string = “”
Defined in src/models/Product.ts:55
The URL to the background media or CSS style to display on the product page.
categories#
• categories: Array<string> = []
Defined in src/models/Product.ts:60
The list of product category identifiers that this product belongs to.
currency#
• currency: Currency = Currency.USD
Defined in src/models/Product.ts:81
The form of currency pertaining to the price.
data#
• data: any = undefined
Defined in src/models/Product.ts:172
An arbitrary map of metadata associated with this product.
dateCreated#
• dateCreated: Date = new Date()
Inherited from EntityBase.dateCreated
Defined in src/EntityBase.ts:18
The date and time that the object was created.
dateModified#
• dateModified: Date = new Date()
Inherited from EntityBase.dateModified
Defined in src/EntityBase.ts:23
The date and time that the object was last modified.
defaultLaunchProfile#
• defaultLaunchProfile: string = “”
Defined in src/models/Product.ts:182
The default LaunchProfile uid to launch the product with.
description#
• description: string = “”
Defined in src/models/Product.ts:86
A textual description of the product.
featured#
• featured: number = -1
Defined in src/models/Product.ts:177
The featured display index of the product, if any. If product is not featured, index is set to -1.
features#
• features: any = undefined
Defined in src/models/Product.ts:91
The map of feature uid’s to a quantity value that the product offers.
icon#
• icon: string = “”
Defined in src/models/Product.ts:96
The icon to display when showing the product description.
launchProfiles#
• launchProfiles: Array<string> = []
Defined in src/models/Product.ts:187
The list of LaunchProfiles available to the product.
license#
• license: ProductLicense = ProductLicense.PERPETUAL
Defined in src/models/Product.ts:106
The length of time that the product license is good for.
logo#
• logo: string = “”
Defined in src/models/Product.ts:101
The image to display when viewing the product in a table or grid.
msrp#
• msrp: number = 0
Defined in src/models/Product.ts:111
The manufacturer suggested retail price of the product.
name#
• name: string = “”
Defined in src/models/Product.ts:45
The unique name of the product.
parentUid#
• parentUid: string | null = null
Defined in src/models/Product.ts:117
An optional uid of the parent that this product is a child of. A child product may represent an add-on, expansion pack, special bundle or other.
price#
• price: number = 0
Defined in src/models/Product.ts:122
The amount of money that the product costs to purchase, in cents. (e.g. $19.99 = 1999)
requires#
• requires: Array<string> = []
Defined in src/models/Product.ts:127
The list of other product or category identifiers that must be purchased before this product can be acquired.
reserved#
• reserved: number = 0
Defined in src/models/Product.ts:132
The number of units that have been reserved for purchasing through pending orders.
roles#
• roles: Array<string> = []
Defined in src/models/Product.ts:137
A list of roles that users must have in order to view/buy this product.
slideshow#
• slideshow: Array<string> = []
Defined in src/models/Product.ts:142
A list of media URLs to display at the top of the product information page.
sold#
• sold: number = 0
Defined in src/models/Product.ts:147
The number of units of this product that have been sold.
summary#
• summary: string = “”
Defined in src/models/Product.ts:152
A brief textual overview of the product.
title#
• title: string = “”
Defined in src/models/Product.ts:50
The name to display to the user.
type#
• type: ProductType = ProductType.OTHER
Defined in src/models/Product.ts:162
The type that determines the of the product.
uid#
• uid: string = uuid.v4()
Inherited from EntityBase.uid
Defined in src/EntityBase.ts:13
The universally unique identifier of the object.
units#
• units: number = -1
Defined in src/models/Product.ts:167
The maximum number of units of this product that are for sale. A negative value indicates an unlimited quantity.
version#
• version: number = 0
Inherited from EntityBase.version
Defined in src/EntityBase.ts:28
The optimistic locking version of the object.
Accessors#
ClassName#
• Staticget ClassName(): string
Defined in src/models/Product.ts:40
Returns: string
Object literals#
cover#
▪ cover: object
Defined in src/models/Product.ts:65
The set of cover images to use when showing the product.
Properties:#
Name |
Type |
Value |
Description |
|---|---|---|---|
|
string |
“” |
The cover image of the format. 10:3 3000x900px |
|
string |
“” |
The cover image of the format landscape. 16:9 2560x1440px |
|
string |
“” |
The cover image of the format mini landscape. 3:1 1080x360px |
|
string |
“” |
The cover image of the format portrait. 7:10 1008x1440px |
|
string |
“” |
The cover image of the format square. 1:1 1440x1440px |