File

projects/storefrontlib/cms-components/product/product-list/container/product-list.model.ts

Description

Contains search related data for querying the backend API.

Index

Properties

Properties

currentPage
currentPage: number
Type : number
Optional

The current page of the search result.

pageSize
pageSize: number
Type : number
Optional

The number of items in the search results.

query
query: string
Type : string
Optional

Contains the search text that is used to query the backend API.

sortCode
sortCode: string
Type : string
Optional

The sort code that is used to sort the items in the search result.

export interface ProductListRouteParams {
  /**
   * The query parameter which used to query the backend API.
   */
  query?: string;

  /**
   * The category code which is used to query the backend API.
   */
  categoryCode?: string;

  /**
   * The brand code is actually a category code,  which is used to
   * query the backend API.
   */
  brandCode?: string;
}

/**
 * Contains search related data for querying the backend API.
 */
export interface SearchCriteria {
  /**
   * Contains the search text that is used to query the backend API.
   */
  query?: string;

  /**
   * The current page of the search result.
   */
  currentPage?: number;

  /**
   * The number of items in the search results.
   */
  pageSize?: number;

  /**
   * The sort code that is used to sort the items in the search result.
   */
  // TODO: Should we change it it `sort`?
  sortCode?: string;
}

result-matching ""

    No results matching ""