Project Wonder 5.0.0.8787

er.extensions.components.javascript
Class ERXJSSubmitFunction

java.lang.Object
  extended by com.webobjects.appserver.WOElement
      extended by com.webobjects.appserver.WODynamicElement
          extended by er.extensions.components.javascript.ERXJSSubmitFunction

public class ERXJSSubmitFunction
extends WODynamicElement

ERXJSSubmitFunction generates a javascript method that can submit a particular form and trigger the call of a component action. This allows more flexibility for submitting forms. For instance, if you set the functionName to "submitForm" and action set to processAction, you could have a WOPopupButton with the following binding: onChange = "submitForm();"; Which will cause the form to submit when the popup button changes and call the action specified in the ERXJSSubmitFunction (in this example, processAction).

Author:
mschrag
Bindings
action the action to call when the javascript function is called and the form is submitted
           
formName the name of the form to submit (right now you must set the name properly on the desired form)
           
functionName the name of the javascript function that executes the submit
           
name the name of the hidden field that identifies which action is to be executed
           

Field Summary
protected  WOAssociation _action
           
protected  WOAssociation _disabled
           
protected  WOAssociation _formName
           
protected  WOAssociation _functionName
           
protected  WOAssociation _name
           
 
Fields inherited from class com.webobjects.appserver.WODynamicElement
_ConstructorParameters
 
Constructor Summary
ERXJSSubmitFunction(String elementName, NSDictionary associations, WOElement woelement)
           
 
Method Summary
 void appendToResponse(WOResponse response, WOContext context)
           
 boolean disabledInComponent(WOComponent component)
           
 WOActionResults invokeAction(WORequest request, WOContext context)
           
protected  String nameInContext(WOContext context, WOComponent component)
           
 void takeValuesFromRequest(WORequest worequest, WOContext wocontext)
           
 
Methods inherited from class com.webobjects.appserver.WODynamicElement
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_action

protected WOAssociation _action

_name

protected WOAssociation _name

_functionName

protected WOAssociation _functionName

_disabled

protected WOAssociation _disabled

_formName

protected WOAssociation _formName
Constructor Detail

ERXJSSubmitFunction

public ERXJSSubmitFunction(String elementName,
                           NSDictionary associations,
                           WOElement woelement)
Method Detail

takeValuesFromRequest

public void takeValuesFromRequest(WORequest worequest,
                                  WOContext wocontext)
Overrides:
takeValuesFromRequest in class WOElement

nameInContext

protected String nameInContext(WOContext context,
                               WOComponent component)

disabledInComponent

public boolean disabledInComponent(WOComponent component)

invokeAction

public WOActionResults invokeAction(WORequest request,
                                    WOContext context)
Overrides:
invokeAction in class WOElement

appendToResponse

public void appendToResponse(WOResponse response,
                             WOContext context)
Overrides:
appendToResponse in class WOElement

Last updated: Wed, Jan 7, 2009 • 04:35 AM EST

Copyright © 2002 – 2007 Project Wonder.