PHP 클래스 TbTags

저자: Antonio Ramirez ([email protected])
상속: extends CInputWidget
파일 보기 프로젝트 열기: yinhe/yincart

공개 프로퍼티들

프로퍼티 타입 설명
$displayPopovers boolean whether to display popovers with information or not
$events the JavaScript event handlers. The events are on the format:
...
   'whenAddingTag' => 'js:function(tag){ console.log(tag);}',
...
$exclude array
$form when created via TbActiveForm This attribute is set to the form that renders the widget
$popoverData list of popover messages that should be displayed with the tags initially displayed. Note: Is important that the list matches the index list of those tags in $tagData.
$promptText string placeholder string when the re are no tags and nothing typed in
$restrictTo array
$suggestions array Suggestions for generating the list options: array('A','B','C')
$tagClass string what class the tag div will have for styling. Defaults to btn-success
$tagData list of tags to display initially display

보호된 프로퍼티들

프로퍼티 타입 설명
$options array the array to configure the js component.

공개 메소드들

메소드 설명
init ( ) ### .init()
registerClientScript ( string $id ) ### .registerClientScript()
renderContent ( integer $id, string $name ) : string ### .renderContent()
run ( ) ### .run()

메소드 상세

init() 공개 메소드

Initializes the widget.
public init ( )

registerClientScript() 공개 메소드

Registers required client script for bootstrap select2. It is not used through bootstrap->registerPlugin in order to attach events if any
public registerClientScript ( string $id )
$id string

renderContent() 공개 메소드

Renders required HTML tags
public renderContent ( integer $id, string $name ) : string
$id integer
$name string
리턴 string with HTML tags

run() 공개 메소드

Runs the widget.
public run ( )

프로퍼티 상세

$displayPopovers 공개적으로 프로퍼티

whether to display popovers with information or not
public bool $displayPopovers
리턴 boolean

$events 공개적으로 프로퍼티

the JavaScript event handlers. The events are on the format:
...
   'whenAddingTag' => 'js:function(tag){ console.log(tag);}',
...
또한 보기:
public $events

$exclude 공개적으로 프로퍼티

public array $exclude
리턴 array

$form 공개적으로 프로퍼티

when created via TbActiveForm This attribute is set to the form that renders the widget
public $form

$options 보호되어 있는 프로퍼티

the array to configure the js component.
protected array $options
리턴 array

$popoverData 공개적으로 프로퍼티

list of popover messages that should be displayed with the tags initially displayed. Note: Is important that the list matches the index list of those tags in $tagData.
public $popoverData

$promptText 공개적으로 프로퍼티

placeholder string when the re are no tags and nothing typed in
public string $promptText
리턴 string

$restrictTo 공개적으로 프로퍼티

public array $restrictTo
리턴 array

$suggestions 공개적으로 프로퍼티

Suggestions for generating the list options: array('A','B','C')
public array $suggestions
리턴 array

$tagClass 공개적으로 프로퍼티

what class the tag div will have for styling. Defaults to btn-success
public string $tagClass
리턴 string

$tagData 공개적으로 프로퍼티

list of tags to display initially display
public $tagData