JavaScript/jQuery TreeList - editing
The widget allows a user to edit data in several modes, which are detailed in the mode option. To define what editing operations a user can perform, specify the allowAdding, allowUpdating and allowDeleting options. Before enabling an operation, make sure that your data source supports it.
See Also
form
Configures the form. Used only if editing.mode is "form" or "popup".
Default form editors depend on the columns' configuration. If the generated form does not meet your requirements, and you need to reorganize form items or set other form options, specify it in the form object. To link a form item with a grid column, assign identical values to the form.items.dataField and columns.dataField options.
You cannot specify the following options in the form object:
- template
- readOnly
- editorType
- any event handler (options whose name starts with "on..."); instead, handle the editorPreparing or editorPrepared event to customize the form editors.
Also, the colCount option defaults to 2, but it can be redefined.
See Also
mode
The following list points out the differences in editing modes.
- Row
A user edits one row at a time. The widget saves changes when the row leaves the editing state. See demo. - Batch
A user edits data cell by cell. The widget does not save changes until a user clicks the global "Save" button. See demo. - Cell
Differs from the batch mode in that the widget saves changes when the cell leaves the editing state. See demo. - Form
On entering the editing state, a row becomes a form with editable fields. The widget saves changes after a user clicks the "Save" button. See demo. - Popup
Differs from the form mode in that the form with editable fields is placed in a popup window. See demo.
Use the GridEditMode
enum to specify this option when the widget is used as an ASP.NET MVC Control. This enum accepts the following values: Row
, Batch
, Cell
, Form
, and Popup
.
popup
Configures the popup. Used only if editing.mode is "popup".
You can specify most of the Popup options in this object except those listed below. The TreeList overriddes these options.
The popup always contains a form whose items are used for editing. Use the form option to customize the form items.
useIcons
Specifies whether the editing column uses icons instead of links.
If you have technical questions, please create a support ticket in the DevExpress Support Center.