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

Class: CheckoutForm

Source Location: /code/form/CheckoutForm.php

Class Overview

Form
   |
   --CheckoutForm

Form for displaying on the CheckoutPage with all the necessary details for a visitor to complete their order and pass off to the Payment gateway class.


Author(s):

Version:

  • 1.0

Copyright:

  • Copyright (c) 2011, Frank Mullenger

Variables

Methods



Class Details

[line 12]
Form for displaying on the CheckoutPage with all the necessary details for a visitor to complete their order and pass off to the Payment gateway class.



Tags:

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


[ Top ]


Class Variables

$currentOrder =

[line 19]

The current Order



Tags:

access:  public

Type:   Order


[ Top ]

$groupedFields = array()

[line 27]

Fields for this form are grouped in sets, they are stored in an array so that the template can pull out a set of fields for a different part of the form.



Tags:

access:  protected

Type:   Array


[ Top ]



Class Methods


constructor __construct [line 48]

CheckoutForm __construct( Controller $controller, String $name, Array $groupedFields, FieldSet $actions, [Validator $validator = null], [Order $currentOrder = null])

Construct the form, get the grouped fields and set the fields for this form appropriately, the fields are passed in an associative array so that the fields can be grouped into sets making it easier for the template to grab certain fields for different parts of the form.



Parameters:

Controller   $controller  
String   $name  
Array   $groupedFields   Associative array of fields grouped into sets
FieldSet   $actions  
Validator   $validator  
Order   $currentOrder  

[ Top ]

method Cart [line 72]

Order Cart( )

Helper function to return the current Order, used in the template for this form



[ Top ]

method Fields [line 82]

FieldSet Fields( [ $set = null])

Return the forms fields for the template, but filter the fields for a particular 'set' of fields.



Tags:

return:  The form fields


Parameters:

   $set  

[ Top ]

method validate [line 113]

void validate( )

Overloaded so that form error messages are displayed.



[ Top ]


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