PHP 클래스 Prado\Web\UI\WebControls\TEditCommandColumn

TEditCommandColumn contains the Edit command buttons for editing data items in each row. TEditCommandColumn will create an edit button if a cell is not in edit mode. Otherwise an update button and a cancel button will be created within the cell. The button captions are specified using {@link setEditText EditText}, {@link setUpdateText UpdateText}, and {@link setCancelText CancelText}. The buttons in the column can be set to display as hyperlinks, push or image buttons by setting the {@link setButtonType ButtonType} property. When an edit button is clicked, the datagrid will generate an {@link onEditCommand OnEditCommand} event. When an update/cancel button is clicked, the datagrid will generate an {@link onUpdateCommand OnUpdateCommand} or an {@link onCancelCommand OnCancelCommand} You can write these event handlers to change the state of specific datagrid item. The {@link setCausesValidation CausesValidation} and {@link setValidationGroup ValidationGroup} properties affect the corresponding properties of the edit and update buttons. The cancel button does not cause validation by default. The command buttons in the column can be accessed by one of the following methods: $datagridItem->ButtonColumnID->EditButton (or UpdateButton, CancelButton) $datagridItem->ButtonColumnID->Controls[0] The second method is possible because the button control created within the datagrid cell is the first child.
부터: 3.0
저자: Qiang Xue ([email protected])
상속: extends TDataGridColumn
파일 보기 프로젝트 열기: pradosoft/prado

공개 메소드들

메소드 설명
getButtonType ( ) : TButtonColumnType
getCancelImageUrl ( ) : string
getCancelText ( ) : string
getCausesValidation ( ) : boolean
getEditImageUrl ( ) : string
getEditText ( ) : string
getUpdateImageUrl ( ) : string
getUpdateText ( ) : string
getValidationGroup ( ) : string
initializeCell ( $cell, $columnIndex, $itemType ) Initializes the specified cell to its initial values.
setButtonType ( $value )
setCancelImageUrl ( $value )
setCancelText ( $value )
setCausesValidation ( $value )
setEditImageUrl ( $value )
setEditText ( $value )
setUpdateImageUrl ( $value )
setUpdateText ( $value )
setValidationGroup ( $value )

보호된 메소드들

메소드 설명
createButton ( $commandName, $text, $causesValidation, $validationGroup ) : mixed Creates a button and initializes its properties.

메소드 상세

createButton() 보호된 메소드

The button type is determined by {@link getButtonType ButtonType}.
protected createButton ( $commandName, $text, $causesValidation, $validationGroup ) : mixed
리턴 mixed the newly created button.

getButtonType() 공개 메소드

public getButtonType ( ) : TButtonColumnType
리턴 TButtonColumnType the type of command button. Defaults to TButtonColumnType::LinkButton.

getCancelImageUrl() 공개 메소드

public getCancelImageUrl ( ) : string
리턴 string the URL of the image file for cancel image buttons

getCancelText() 공개 메소드

public getCancelText ( ) : string
리턴 string the caption of the cancel button. Defaults to 'Cancel'.

getCausesValidation() 공개 메소드

public getCausesValidation ( ) : boolean
리턴 boolean whether postback event trigger by edit or update button will cause input validation, default is true

getEditImageUrl() 공개 메소드

public getEditImageUrl ( ) : string
리턴 string the URL of the image file for edit image buttons

getEditText() 공개 메소드

public getEditText ( ) : string
리턴 string the caption of the edit button. Defaults to 'Edit'.

getUpdateImageUrl() 공개 메소드

public getUpdateImageUrl ( ) : string
리턴 string the URL of the image file for update image buttons

getUpdateText() 공개 메소드

public getUpdateText ( ) : string
리턴 string the caption of the update button. Defaults to 'Update'.

getValidationGroup() 공개 메소드

public getValidationGroup ( ) : string
리턴 string the group of validators which the edit or update button causes validation upon postback

initializeCell() 공개 메소드

This method overrides the parent implementation. It creates an update and a cancel button for cell in edit mode. Otherwise it creates an edit button.
public initializeCell ( $cell, $columnIndex, $itemType )

setButtonType() 공개 메소드

public setButtonType ( $value )

setCancelImageUrl() 공개 메소드

public setCancelImageUrl ( $value )

setCancelText() 공개 메소드

public setCancelText ( $value )

setCausesValidation() 공개 메소드

public setCausesValidation ( $value )

setEditImageUrl() 공개 메소드

public setEditImageUrl ( $value )

setEditText() 공개 메소드

public setEditText ( $value )

setUpdateImageUrl() 공개 메소드

public setUpdateImageUrl ( $value )

setUpdateText() 공개 메소드

public setUpdateText ( $value )

setValidationGroup() 공개 메소드

public setValidationGroup ( $value )