@plentymarkets/shop-api / categoryGetters
Variable: categoryGetters ​
constcategoryGetters:object
Defined in: getters/categoryGetters.ts:149
Type Declaration ​
getCategoryDescription1 ​
getCategoryDescription1: (
category) =>string
Returns the first long description of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The first description string, or an empty string if not set.
getCategoryDescription2 ​
getCategoryDescription2: (
category) =>string
Returns the second long description of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The second description string, or an empty string if not set.
getCategoryDetails ​
getCategoryDetails: (
category) =>CategoryDetails|null
Returns the first localised details entry of a category.
Parameters ​
category ​
The category object.
Returns ​
CategoryDetails | null
The first CategoryDetails entry, or null if none exist.
getCategoryName ​
getCategoryName: (
category) =>string
Returns the display name of the category from its first details entry.
Parameters ​
category ​
The category object.
Returns ​
string
The category name string, or an empty string if details are not available.
getCategoryRight ​
getCategoryRight: (
category) =>string
Returns the access right of the category (e.g. "all", "customer").
Parameters ​
category ​
The category object.
Returns ​
string
The right string, or an empty string if not set.
getCategoryRobots ​
getCategoryRobots: (
category) =>string
Returns the robots meta tag setting for the category.
Parameters ​
category ​
The category object.
Returns ​
string
The robots string (e.g. "ALL", "NOINDEX"), or an empty string if not set.
getCategoryShortDescription ​
getCategoryShortDescription: (
category) =>string
Returns the short description of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The short description string, or an empty string if not set.
getCategoryType ​
getCategoryType: (
category) =>string
Returns the type of the category (e.g. "item", "content", "container").
Parameters ​
category ​
The category object.
Returns ​
string
The category type string, or an empty string if not set.
getId ​
getId: (
category) =>number
Returns the numeric ID of a category.
Parameters ​
category ​
The category object.
Returns ​
number
The category ID, or 0 if not set.
getMetaDescription ​
getMetaDescription: (
category) =>string
Returns the SEO meta description of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The meta description string, or an empty string if not set.
getMetaKeywords ​
getMetaKeywords: (
category) =>string
Returns the SEO meta keywords of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The meta keywords string, or an empty string if not set.
getMetaTitle ​
getMetaTitle: (
category) =>string
Returns the SEO meta title of the category.
Parameters ​
category ​
The category object.
Returns ​
string
The meta title string, or an empty string if not set.
getParentId ​
getParentId: (
category) =>number
Returns the numeric ID of the parent category.
Parameters ​
category ​
The category object.
Returns ​
number
The parent category ID, or 0 if not set.
getSubCategories ​
getSubCategories: (
category) =>SubCategory[]
Parameters ​
category ​
Returns ​
getSubCategoryId ​
getSubCategoryId: (
subcategory) =>number
Parameters ​
subcategory ​
Returns ​
number
getSubCategoryItemCount ​
getSubCategoryItemCount: (
subcategory) =>number
Parameters ​
subcategory ​
Returns ​
number
getSubCategoryName ​
getSubCategoryName: (
subcategory) =>string
Parameters ​
subcategory ​
Returns ​
string
getSubCategoryNameUrl ​
getSubCategoryNameUrl: (
subcategory) =>string
Parameters ​
subcategory ​
Returns ​
string
hasCustomerRight ​
hasCustomerRight: (
category) =>boolean
Returns whether the category requires a customer login to access.
Parameters ​
category ​
The category object.
Returns ​
boolean
true if the category right is "customer", otherwise false.