PHP Class Form_Field_ValueList, atk4

Inheritance: extends Form_Field
ファイルを表示 Open project: atk4/atk4 Class Usage Examples

Public Properties

Property Type Description
$default_empty_text default empty text message
$empty_text current empty text message and ID
$value_list array of available values

Protected Properties

Property Type Description
$empty_value
$separator value separator, for internal use

Public Methods

Method Description
getValueList ( ) : array Return value list.
normalize ( ) Normalize POSTed data.
setEmptyText ( string $text = null ) Sets default text which is displayed on a null-value option.
setForm ( $form )
setModel ( Model $m ) : Model Sets model of form field.
setValueList ( array $list ) Set value list of form field.
validateValidItem ( ) : boolean Validate POSTed field value.

Method Details

getValueList() public method

Return value list.
public getValueList ( ) : array
return array

normalize() public method

Normalize POSTed data.
public normalize ( )

setEmptyText() public method

Set to "Select.." or "Pick one.."
public setEmptyText ( string $text = null )
$text string Pass null to use default text, empty string - disable

setForm() public method

public setForm ( $form )

setModel() public method

Sets model of form field.
public setModel ( Model $m ) : Model
$m Model
return Model

setValueList() public method

Set value list of form field.
public setValueList ( array $list )
$list array

validateValidItem() public method

Validate POSTed field value.
public validateValidItem ( ) : boolean
return boolean

Property Details

$default_empty_text public_oe property

default empty text message
public $default_empty_text

$empty_text public_oe property

current empty text message and ID
public $empty_text

$empty_value protected_oe property

protected $empty_value

$separator protected_oe property

value separator, for internal use
protected $separator

$value_list public_oe property

array of available values
public $value_list