PHP Class CartEditField, silvershop-core

Inheritance: extends FormField
Afficher le fichier Open project: burnbright/silverstripe-shop Class Usage Examples

Protected Properties

Свойство Type Description
$cart
$editableItemsCallback
$items
$template

Méthodes publiques

Méthode Description
Field ( array $properties = [] ) Render the cart with editable item fields.
__construct ( $name, $title, $cart )
getItemsList ( ) : SS_List Get the items list being used to produce the cart.
setEditableItemsCallback ( Closure $callback ) Provides a way to modify the editableItems list before it is rendered.
setItemsList ( SS_List $list ) Allow overriding the given items list.
setTemplate ( string $template ) Set tempalte for rendering editable cart.

Méthodes protégées

Méthode Description
editableItems ( ) Add quantity, variation and remove fields to the item set.

Method Details

Field() public méthode

Render the cart with editable item fields.
public Field ( array $properties = [] )
$properties array

__construct() public méthode

public __construct ( $name, $title, $cart )

editableItems() protected méthode

Add quantity, variation and remove fields to the item set.
protected editableItems ( )

getItemsList() public méthode

Get the items list being used to produce the cart.
public getItemsList ( ) : SS_List
Résultat SS_List

setEditableItemsCallback() public méthode

Provides a way to modify the editableItems list before it is rendered.
public setEditableItemsCallback ( Closure $callback )
$callback Closure

setItemsList() public méthode

This helps with formatting, grouping, ordering etc.
public setItemsList ( SS_List $list )
$list SS_List

setTemplate() public méthode

Set tempalte for rendering editable cart.
public setTemplate ( string $template )
$template string

Property Details

$cart protected_oe property

protected $cart

$editableItemsCallback protected_oe property

protected $editableItemsCallback

$items protected_oe property

protected $items

$template protected_oe property

protected $template