swipestripe
[ class tree: swipestripe ] [ index: swipestripe ] [ all elements ]

Class: CartQuantityField

Source Location: /code/form/CartQuantityField.php

Class Overview

TextField
   |
   --CartQuantityField

Quantity field for displaying each Item in an Order on the CartPage.


Author(s):

Version:

  • 1.0

Copyright:

  • Copyright (c) 2011, Frank Mullenger

Variables

Methods



Class Details

[line 11]
Quantity field for displaying each Item in an Order on the CartPage.



Tags:

author:  Frank Mullenger <frankmullenger@gmail.com>
version:  1.0
copyright:  Copyright (c) 2011, Frank Mullenger


[ Top ]


Class Variables

$item =

[line 25]

Current Item represented by this field.



Tags:

access:  protected

Type:   Item


[ Top ]

$template =  "CartQuantityField"

[line 18]

Template for rendering the field



Tags:

access:  protected

Type:   String


[ Top ]



Class Methods


constructor __construct [line 37]

CartQuantityField __construct( String $name, [String $title = null], [String $value = ""], [Int $maxLength = null], [Form $form = null], [Item $item = null])

Construct the field and set the current Item that this field represents.



Parameters:

String   $name  
String   $title  
String   $value  
Int   $maxLength  
Form   $form  
Item   $item  

[ Top ]

method FieldHolder [line 48]

void FieldHolder( )

Render the field with the appropriate template.



[ Top ]

method Item [line 57]

Item Item( )

Retrieve the current Item this field represents. Used in the template.



[ Top ]

method RemoveItemAction [line 176]

RemoveItemAction RemoveItemAction( )

Get a form action to remove an order item.



Tags:

return:  Type of FormAction


[ Top ]

method setItem [line 66]

void setItem( Item $item)

Set the current Item this field represents



Parameters:

Item   $item  

[ Top ]

method validate [line 77]

Boolean validate( $validator)

Validate this field, check that the current Item is in the current {@Link Order} and is valid for adding to the cart.



Parameters:

   $validator  

[ Top ]


Documentation generated on Thu, 08 Mar 2012 16:47:25 +1300 by phpDocumentor 1.4.4