phpDocumentor

OrderListGeneratorInterface

Interface OrderListGeneratorInterface

Tags
category

System

subpackage

Interfaces

Table of Contents

filterOrderList()  : OrderListItemCollection
Filter order list items by the provided parameters.
filterOrderListCount()  : int
Get the filtered orders count.
getOrderListByConditions()  : OrderListItemCollection
Get Order List Items
getOrderListByKeyword()  : OrderListItemCollection
Filters records by a single keyword string.
getOrderListByKeywordCount()  : int
Get count of orders filtered by keyword
getOrderListCount()  : int
Get the total count of all orders

Methods

filterOrderList()

Filter order list items by the provided parameters.

public filterOrderList(array<string|int, mixed> $filterParameters[, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : OrderListItemCollection

The following slug names need to be used:

  • number => orders.orders_id
  • customer => orders.customers_lastname orders.customers_firstname
  • group => orders.customers_status_name
  • sum => orders_total.value
  • payment => orders.payment_method
  • shipping => orders.shipping_method
  • countryIsoCode => orders.delivery_country_iso_code_2
  • date => orders.date_purchased
  • status => orders_status.orders_status_name
  • invoiceNumber => invoices.invoice_number
Parameters
$filterParameters : array<string|int, mixed>

Contains the column slug-names and their values.

$pager : Pager|null = null

(Optional) Pager object with pagination information

$sorters : array<string|int, mixed> = []

(Optional) array of Sorter objects with data sorting information

Return values
OrderListItemCollection

filterOrderListCount()

Get the filtered orders count.

public filterOrderListCount(array<string|int, mixed> $filterParameters) : int

This number is useful for pagination functionality where the app needs to know the number of the filtered rows.

Parameters
$filterParameters : array<string|int, mixed>
Tags
throws
BadMethodCallException
Return values
int

getOrderListByConditions()

Get Order List Items

public getOrderListByConditions([string|array<string|int, mixed> $conditions = [] ][, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : OrderListItemCollection

Returns an order list item collection.

Parameters
$conditions : string|array<string|int, mixed> = []

Provide a WHERE clause string or an associative array (actually any parameter that is acceptable by the "where" method of the CI_DB_query_builder method).

$pager : Pager|null = null

(Optional) Pager object with pagination information

$sorters : array<string|int, mixed> = []

(Optional) array of Sorter objects with data sorting information

Tags
throws
InvalidArgumentException

If the result rows contain invalid values.

Return values
OrderListItemCollection

getOrderListByKeyword()

Filters records by a single keyword string.

public getOrderListByKeyword(StringType $keyword[, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : OrderListItemCollection
Parameters
$keyword : StringType

Keyword string to be used for searching in order records.

$pager : Pager|null = null

(Optional) Pager object with pagination information

$sorters : array<string|int, mixed> = []

(Optional) array of Sorter objects with data sorting information

Return values
OrderListItemCollection

Order list item collection.

getOrderListByKeywordCount()

Get count of orders filtered by keyword

public getOrderListByKeywordCount(StringType $keyword) : int
Parameters
$keyword : StringType

Keyword string to be used for searching in order records.

Return values
int

Search results