\Kendo\UI\GridEditable
A PHP class representing the editable setting of Grid.
Methods
cancelDelete
If confirmation is enabled the grid will display a confirmation dialog when the user clicks the "destroy" command button. If the grid is in mobile mode this text will be used for the cancel button.
Returns
\Kendo\UI\GridEditable
Parameters
$value string
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->cancelDelete('value');
?>
confirmDelete
If confirmation is enabled the grid will display a confirmation dialog when the user clicks the "destroy" command button. If the grid is in mobile mode this text will be used for the confirm button.
Returns
\Kendo\UI\GridEditable
Parameters
$value string
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->confirmDelete('value');
?>
confirmation
If set to true the grid will display a confirmation dialog when the user clicks the "destroy" command button.Can be set to a string which will be used as the confirmation text.Can be set to a function which will be called, passing the model instance, to return the confirmation text.This and all Grid configuration properties can be set (enabled/disabled) after the grid has been initialized with the setOptions method.
Returns
\Kendo\UI\GridEditable
Parameters
$value boolean|string|\Kendo\JavaScriptFunction
Example - using boolean
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->confirmation(true);
?>
Example - using string
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->confirmation('value');
?>
Example - using \Kendo\JavaScriptFunction
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->confirmation(new \Kendo\JavaScriptFunction('function() { }'));
?>
createAt
The position at which new data items are inserted in the grid. Must be set to either "top" or "bottom". By default new data items are inserted at the top.
Returns
\Kendo\UI\GridEditable
Parameters
$value string
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->createAt('value');
?>
destroy
If set to true the user can delete data items from the grid by clicking the "destroy" command button. Deleting is enabled by default.
Returns
\Kendo\UI\GridEditable
Parameters
$value boolean
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->destroy(true);
?>
mode
The editing mode to use. The supported editing modes are "incell", "inline" and "popup".
Returns
\Kendo\UI\GridEditable
Parameters
$value string
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->mode('value');
?>
readonly
If set to true the Grid will be initialized in read only mode. Users won't be able to add, remove or update records. Clicking on the edit, delete or add buttons will have no effect. In incell mode, clicking on the cell will not open it for editing.API methods are not affected by this configuration. Calling editRow and editCell will still put the cell/row in edit mode. Calling addRow and removeRow will add/remove the row.This property is useful in combination with the enableEditing and disableEditing methods. You can initialize the Grid as read only and enable editing later on.
Returns
\Kendo\UI\GridEditable
Parameters
$value boolean
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->readonly(true);
?>
template
The template which renders popup editor.The template should contain elements whose name HTML attributes are set as the editable fields. This is how the grid will know which field to update. The other option is to use MVVM bindings in order to bind HTML elements to data item fields.To change the size of the popup editor you can follow the approach outlined in this article.
Returns
\Kendo\UI\GridEditable
Parameters
$value string|\Kendo\JavaScriptFunction
Example - using string
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->template('value');
?>
Example - using \Kendo\JavaScriptFunction
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->template(new \Kendo\JavaScriptFunction('function() { }'));
?>
update
If set to true the user can edit data items when editing is enabled.
Returns
\Kendo\UI\GridEditable
Parameters
$value boolean
Example
<?php
$editable = new \Kendo\UI\GridEditable();
$editable->update(true);
?>
window
Configures the Kendo UI Window instance, which is used when the Grid edit mode is "popup". The configuration is optional.For more information, please refer to the Window configuration API.
Returns
\Kendo\UI\GridEditable