com.softslate.commerce.customer.order
Class OrderForm

java.lang.Object
  extended by org.apache.struts.action.ActionForm
      extended by com.softslate.commerce.customer.core.BaseForm
          extended by com.softslate.commerce.customer.order.BillingAddressForm
              extended by com.softslate.commerce.customer.order.AddressesForm
                  extended by com.softslate.commerce.customer.order.CheckoutAddressesForm
                      extended by com.softslate.commerce.customer.order.CheckoutComboShippingForm
                          extended by com.softslate.commerce.customer.order.OrderForm
All Implemented Interfaces:
java.io.Serializable

public class OrderForm
extends CheckoutComboShippingForm

Struts form class for submissions to the store's order form. Used for requests to "/OrderProcess.do".

OrderForm is a subclass of CheckoutComboShippingForm, and it inherits its address properties and shipping option property.

The validate method of this class runs the validate method of CheckoutComboShippingForm to make sure all the required address fields are present and a shipping option was selected. It then checks to make sure at least one product with a positive quantity was submitted.

Author:
David Tobey
See Also:
Serialized Form

Field Summary
(package private) static org.apache.commons.logging.Log log
           
private  java.lang.String[] orderProductCodes
           
private  java.lang.String[] orderProductQuantities
           
private static long serialVersionUID
           
 
Fields inherited from class org.apache.struts.action.ActionForm
multipartRequestHandler, servlet
 
Constructor Summary
OrderForm()
           
 
Method Summary
 java.lang.String[] getOrderProductCodes()
           
 java.lang.String[] getOrderProductQuantities()
           
 void setOrderProductCodes(java.lang.String[] string)
           
 void setOrderProductQuantities(java.lang.String[] string)
           
 org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)
           
 void validateProducts()
          Ensure that at least one product was submitted with a positive quantity.
 
Methods inherited from class com.softslate.commerce.customer.order.CheckoutComboShippingForm
getShippingOption, getUpdateCustomer, isSubmitted, setIsSubmitted, setShippingOption, setUpdateCustomer, validateShippingOption
 
Methods inherited from class com.softslate.commerce.customer.order.AddressesForm
copyBillingToDelivery, getDeliveryAddress1, getDeliveryAddress2, getDeliveryCity, getDeliveryCountry, getDeliveryEmail1, getDeliveryEmail2, getDeliveryExtra1, getDeliveryExtra2, getDeliveryExtra3, getDeliveryExtra4, getDeliveryExtra5, getDeliveryFirstName, getDeliveryLastName, getDeliveryNotes, getDeliveryOrganization, getDeliveryOther, getDeliveryPhone1, getDeliveryPhone2, getDeliveryPostalCode, getDeliveryState, getDeliveryUseBilling, isDeliveryFieldValid, prepareStateAndOtherFields, prepareStateAndOtherFields, setDeliveryAddress1, setDeliveryAddress2, setDeliveryCity, setDeliveryCountry, setDeliveryEmail1, setDeliveryEmail2, setDeliveryExtra1, setDeliveryExtra2, setDeliveryExtra3, setDeliveryExtra4, setDeliveryExtra5, setDeliveryFirstName, setDeliveryLastName, setDeliveryNotes, setDeliveryOrganization, setDeliveryOther, setDeliveryPhone1, setDeliveryPhone2, setDeliveryPostalCode, setDeliveryState, setDeliveryUseBilling, validateDeliveryFields, validateDeliveryStateField
 
Methods inherited from class com.softslate.commerce.customer.order.BillingAddressForm
doesCountryAllowOtherStates, getBillingAddress1, getBillingAddress2, getBillingCity, getBillingCountry, getBillingEmail1, getBillingEmail2, getBillingExtra1, getBillingExtra2, getBillingExtra3, getBillingExtra4, getBillingExtra5, getBillingFirstName, getBillingLastName, getBillingNotes, getBillingOrganization, getBillingOther, getBillingPhone1, getBillingPhone2, getBillingPostalCode, getBillingState, isBillingFieldValid, isOtherState, setBillingAddress1, setBillingAddress2, setBillingCity, setBillingCountry, setBillingEmail1, setBillingEmail2, setBillingExtra1, setBillingExtra2, setBillingExtra3, setBillingExtra4, setBillingExtra5, setBillingFirstName, setBillingLastName, setBillingNotes, setBillingOrganization, setBillingOther, setBillingPhone1, setBillingPhone2, setBillingPostalCode, setBillingState, stateAndCountryMatch, validateBillingFields, validateBillingStateField
 
Methods inherited from class com.softslate.commerce.customer.core.BaseForm
formUtils, getBusinessObjectFactory, getErrors, getMapping, getMessage, getMessages, getRequest, getSettings, getUser, initializeProperties, setBusinessObjectFactory, setErrors, setMapping, setMessages, setRequest, setSettings, setUser
 
Methods inherited from class org.apache.struts.action.ActionForm
getMultipartRequestHandler, getServlet, getServletWrapper, reset, reset, setMultipartRequestHandler, setServlet, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

log

static org.apache.commons.logging.Log log

orderProductCodes

private java.lang.String[] orderProductCodes

orderProductQuantities

private java.lang.String[] orderProductQuantities
Constructor Detail

OrderForm

public OrderForm()
Method Detail

getOrderProductCodes

public java.lang.String[] getOrderProductCodes()

getOrderProductQuantities

public java.lang.String[] getOrderProductQuantities()

setOrderProductCodes

public void setOrderProductCodes(java.lang.String[] string)

setOrderProductQuantities

public void setOrderProductQuantities(java.lang.String[] string)

validate

public org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping,
                                                      javax.servlet.http.HttpServletRequest request)
Overrides:
validate in class CheckoutComboShippingForm

validateProducts

public void validateProducts()
Ensure that at least one product was submitted with a positive quantity.



Copyright ? SoftSlate, LLC 2003?2005