Skip to content

uStoreProvider services categories

Oren levy edited this page Mar 28, 2024 · 1 revision

Classes

Categories

Represent the categories logic and API in the system

Typedefs

GUID : string

globally unique identifier

CategoryModel : Object

Provides information about a category of products.

CategoryListModel : Object

Provides a list of product categories according to the pagination.

SeoConfigurationModel : Object

Provides information about the SEO configuration of a category or product.

CategoryExtendedModel : Object

Provides information about a category, including additional data such as SEO configuration.

CategoryTreeNodeModel : Object

Node representation in a product category tree.

CategoryTreeModel : Object

Node representation in a product category tree.

Categories

Represent the categories logic and API in the system

Kind: global class

categories.loadCategoriesTree([depth]) ⇒ CategoryTreeModel

Set state.categories with the first level categories group.

Kind: instance method of Categories
Returns: CategoryTreeModel - - The tree of categories

Param Type Default Description
[depth] number 1 Indicates the maximum depth of the tree to return. By default (1), returns root categories only.

categories.loadSubCategories(categoryFriendlyID, [pageNumber], [pageSize]) ⇒ Array.<CategoryModel>

Set state.subCategories with the sub-categories of the given category model as CategoryModel in the store, using paging.

Kind: instance method of Categories
Returns: Array.<CategoryModel> - Array of sub categories in a specific page

Param Type Default Description
categoryFriendlyID string the category friendly ID
[pageNumber] number The 1-based number of the page.
[pageSize] number The amount of the categories in one page.

categories.loadCurrentCategory(categoryFriendlyID) ⇒ CategoryExtendedModel

Set state.currentCategory with the requested category by friendlyID using model CategoryExtendedModel

Kind: instance method of Categories
Returns: CategoryExtendedModel - - A category model

Param Type Description
categoryFriendlyID string the category friendly ID

GUID : string

globally unique identifier

Kind: global typedef

CategoryModel : Object

Provides information about a category of products.

Kind: global typedef
Properties

Name Type Description
ID GUID The unique ID of the category.
FriendlyID number The friendly ID of the category.
Name string The name of the category.
Description string The description of the category.
HasProducts boolean Indicates whether the category contains at least one online product.
HasSubCategories boolean Indicates whether the category contains at least one sub-category, of any level, that has an online product.
ImageUrl string The URL of the category image.

CategoryListModel : Object

Provides a list of product categories according to the pagination.

Kind: global typedef
Properties

Name Type Description
Categories Array.<CategoryModel> The list of the product categories according to the pagination.
Count number The total number of product categories without pagination.

SeoConfigurationModel : Object

Provides information about the SEO configuration of a category or product.

Kind: global typedef
Properties

Name Type Description
Title string The title of a webpage.
Description string The description of a webpage.

CategoryExtendedModel : Object

Provides information about a category, including additional data such as SEO configuration.

Kind: global typedef
Properties

Name Type Description
SeoConfiguration SeoConfigurationModel The SEO configuration.
ID GUID The unique ID of the category.
FriendlyID number The friendly ID of the category.
Name string The name of the category.
Description string The description of the category.
HasProducts boolean Indicates whether the category contains at least one online product.
HasSubCategories boolean Indicates whether the category contains at least one sub-category, of any level, that has an online product.
ImageUrl string The URL of the category image.

CategoryTreeNodeModel : Object

Node representation in a product category tree.

Kind: global typedef
Properties

Name Type Description
Category CategoryModel The product category of the node.
SubCategories Array.<CategoryTreeNodeModel> The sub-categories (child nodes) of the node.

CategoryTreeModel : Object

Node representation in a product category tree.

Kind: global typedef
Properties

Name Type Description
Categories CategoryTreeNodeModel The list of top level (root) categories.

Clone this wiki locally