menu

Adianti Solutions

API

Adianti, Framework, PHP, MVC, Active record, Front controller, IDE, RAD, Web, multiplataforma, geração de código, desenvolvimento rápido, relatórios, formulários, listagens, datagrids, gráficos, banco de dados, padrões de projeto, design patterns API do Adianti Framework.
API Docs
code
Selecione a classe

Class TForm

Description

Implements interfaces:

Wrapper class to deal with forms

Located in /widget/form/TForm.php (line 23)


	
			
Direct descendents
Class Description
TQuickForm Create quick forms for input data with a standard container for elements
Variable Summary
mixed $children
mixed $element
mixed $fields
mixed $js_function
mixed $name
Method Summary
static getFormByName ($name)
static sendData ($form_name, $object, [$aggregate = FALSE], [$fireEvents = TRUE])
__construct ([$name = 'my_form'])
add ($object)
addField ($field)
clear ([$keepDefaults = FALSE])
delField ($field)
getData ([$class = 'StdClass'])
getField ($name)
getName ()
getValues ([$class = 'StdClass'], [$withOptions = false])
pack ($object,)
setData ($object)
setEditable ($bool)
setFields ($fields)
setName ($name)
setProperty ($name, $value, [$replace = TRUE])
show ()
__set ($name, $value)
Variables
mixed $children (line 27)
  • access: protected
mixed $element (line 29)
  • access: protected
mixed $fields (line 25)
  • access: protected

Redefined in descendants as:
mixed $js_function (line 28)
  • access: protected
mixed $name (line 26)
  • access: protected

Redefined in descendants as:
Methods
static getFormByName (line 102)

Returns the form object by its name

  • access: public
static getFormByName ($name)
  • $name
static sendData (line 134)

Send data for a form located in the parent window

  • access: public
static sendData ($form_name, $object, [$aggregate = FALSE], [$fireEvents = TRUE])
  • $form_name: Form Name
  • $object: An Object containing the form data
  • $aggregate
  • $fireEvents
Constructor __construct (line 36)

Class Constructor

  • access: public
__construct ([$name = 'my_form'])
  • $name: Form Name

Redefined in descendants as:
add (line 464)

Add a container to the form (usually a table or panel)

  • access: public
add ($object)
  • $object: Any Object that implements the show() method
addField (line 213)

Add a Form Field

  • access: public
addField ($field)
  • $field: Object

Implementation of:
AdiantiFormInterface::addField()
clear (line 326)

clear the form Data

  • access: public
clear ([$keepDefaults = FALSE])
  • $keepDefaults

Implementation of:
AdiantiFormInterface::clear()
delField (line 257)

Remove a form field

  • access: public
delField ($field)
  • $field: Object

Implementation of:
AdiantiFormInterface::delField()
delFields (line 274)

Remove all form fields

  • access: public
delFields ()
getChild (line 484)

Returns the child object

  • access: public
getChild ()
getData (line 362)

Returns the form POST data as an object

  • access: public
getData ([$class = 'StdClass'])
  • $class: A string containing the class for the returning object

Implementation of:
AdiantiFormInterface::getData()
getField (line 306)

Returns a form field by its name

  • return: Field object
  • access: public
getField ($name)
  • $name: A string containing the field's name

Implementation of:
AdiantiFormInterface::getField()
getFields (line 318)

Returns an array with the form fields

  • return: of form fields
  • access: public
getFields ()

Implementation of:
AdiantiFormInterface::getFields()
getName (line 124)

Returns the form name

  • access: public
getName ()

Implementation of:
AdiantiFormInterface::getName()
getValues (line 387)

Returns the form start values as an object

  • access: public
getValues ([$class = 'StdClass'], [$withOptions = false])
  • $class: A string containing the class for the returning object
  • $withOptions
pack (line 476)

Pack a container to the form (usually a table or panel)

  • access: public
pack ($object,)
  • $object,: ...Any Object that implements the show() method
setData (line 343)

Define the data of the form

  • access: public
setData ($object)
  • $object: An Active Record object

Implementation of:
AdiantiFormInterface::setData()
setEditable (line 198)

Define if the form will be editable

  • access: public
setEditable ($bool)
  • $bool: A Boolean
setFields (line 283)

Define wich are the form fields

  • access: public
setFields ($fields)
  • $fields: An array containing a collection of TField objects

Implementation of:
AdiantiFormInterface::setFields()
setName (line 114)

Define the form name

  • access: public
setName ($name)
  • $name: A string containing the form name

Implementation of:
AdiantiFormInterface::setName()
setProperty (line 76)

Define a form property

  • access: public
setProperty ($name, $value, [$replace = TRUE])
  • $name: Property Name
  • $value: Property Value
  • $replace
show (line 492)

Shows the form at the screen

  • access: public
show ()

Implementation of:
AdiantiFormInterface::show()

Redefined in descendants as:
validate (line 434)

Validate form

  • access: public
validate ()

Implementation of:
AdiantiFormInterface::validate()
__set (line 51)

Intercepts whenever someones assign a new property's value

  • access: public
__set ($name, $value)
  • $name: Property Name
  • $value: Property Value

Redefined in descendants as: