You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: components/grid/editing/overview.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ The Grid offers several ways to add and edit rows with a different user experien
48
48
49
49
To allow users to add or edit values in the Grid:
50
50
51
-
1. Set the `EditMode` parameter to a [member of the `GridEditMode` enum](slug:telerik.blazor.grideditmode). The default `EditMode` parameter value is `None`. The built-in [`Add` and `Edit` commands](slug://components/grid/columns/command#built-in-commands) don't work in this case.
51
+
1. Set the `EditMode` parameter to a [member of the `GridEditMode` enum](slug:telerik.blazor.grideditmode). The default `EditMode` parameter value is `None` and the built-in [`Add` and `Edit` commands](slug://components/grid/columns/command#built-in-commands) don't work.
52
52
1. Define the required [command buttons](#commands) and [events](#events) for the selected edit mode and operations.
53
53
54
54
>caption Set up Grid popup edit mode
@@ -114,6 +114,8 @@ The following table describes the Grid events, which are related to adding, dele
114
114
|`OnModelInit`|[Depends on the Grid model type](slug:grid-events#onmodelinit)| Fires when the Grid requires a [new model instance](#item-instances), which is immediately before `OnAdd` or immediately after `OnEdit`. <br /> Use this event when the Grid model type is an [interface, abstract class, or has no parameterless constructor](slug:grid-events#onmodelinit). | No event arguments | Not cancellable |
115
115
|`OnUpdate`| To edit existing items. | Fires on `Save` command invocation for existing items. This event succeeds `OnEdit`. |[Cloned](#item-instances)| Grid remains in edit mode. |
116
116
117
+
The following considerations apply for the Grid CRUD events:
118
+
117
119
* Most events provide a [`GridCommandEventArgs` argument](#gridcommandeventargs) in the handler. `OnModelInit` has no event argument.
118
120
* All events, except `OnModelInit`, are cancellable and the user action can be prevented. Cancelling `OnDelete` does not automatically prevent item deletion from the Grid data source. This depends entirely on the executed application code.
119
121
* The `OnCreate`, `OnDelete`, and `OnUpdate` events are required when using add, delete, and edit operations, respectively. The app must use these events to modify the Grid data source. [The Grid does not modify its data directly](#item-instances).
Copy file name to clipboardExpand all lines: components/treelist/editing/overview.md
+9-7Lines changed: 9 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,8 +15,8 @@ The Telerik TreeList for Blazor supports create, update, and delete operations (
15
15
16
16
*[How the create, update, and delete operations work in the TreeList](#basics).
17
17
*[What are the available edit modes and how to enable them](#edit-modes).
18
-
*[The applicable TreeList commands](#commands)
19
-
*[The applicable TreeList events](#events)
18
+
*[The applicable TreeList commands](#commands).
19
+
*[The applicable TreeList events](#events).
20
20
*[How to change the built-in editors for certain data types](#column-editors).
21
21
*[How to refresh the TreeList data after add, edit, and delete operations](#rebinding-after-data-changes).
22
22
*[How the TreeList CRUD operations integrate with other component features](#integration-with-other-features).
@@ -48,7 +48,7 @@ The TreeList offers several ways to add and edit rows with a different user expe
48
48
49
49
To allow users to add or edit values in the TreeList:
50
50
51
-
1. Set the `EditMode` parameter to a [member of the `TreeListEditMode` enum](slug:telerik.blazor.treelisteditmode). The default `EditMode` parameter value is `None`. The built-in [`Add` and `Edit` commands](slug://treelist-columns-command#built-in-commands) don't work in this case.
51
+
1. Set the `EditMode` parameter to a [member of the `TreeListEditMode` enum](slug:telerik.blazor.treelisteditmode). The default `EditMode` parameter value is `None` and the built-in [`Add` and `Edit` commands](slug://treelist-columns-command#built-in-commands) don't work.
52
52
1. Define the required [command buttons](#commands) and [events](#events) for the selected edit mode and operations.
53
53
54
54
>caption Set up TreeList popup edit mode
@@ -64,21 +64,21 @@ To allow users to add or edit values in the TreeList:
64
64
</TelerikTreeList>
65
65
````
66
66
67
-
>tip See the TreeList add and edit operations in action in the complete examples for TreeList [inline](slug:treelist-editing-inline#example), [in-cell](slug:treelist-editing-incell#example) and [popup](slug:treelist-editing-popup#example) editing.
67
+
>tip See the TreeList add and edit operations in action in the complete examples for TreeList [inline](slug:treelist-editing-inline#example), [in-cell](slug:treelist-editing-incell#example), and [popup](slug:treelist-editing-popup#example) editing.
68
68
69
69
> Editing multiple rows at the same time is not supported. You can [render editors in all TreeList data cells through column `<Template>`s](slug:grid-kb-edit-all-rows-cells) as an alternative.
70
70
71
71
### Delete Operations
72
72
73
73
Delete operations provide the same user experience in all TreeList edit modes and require the same configuration:
74
74
75
-
*[**Delete** command button](#commands)
76
-
*[`OnDelete` event](#events)
75
+
*[**Delete** command button](#commands).
76
+
*[`OnDelete` event](#events).
77
77
* Optional `ConfirmDelete` TreeList parameter. It determines if the component will show a Dialog before firing `OnDelete`, so that users can abort the operation.
78
78
79
79
Delete operations can work even if the TreeList `EditMode` parameter value is `None`.
80
80
81
-
>tip See delete operations in action in the complete examples for TreeList [inline](slug:treelist-editing-inline#example), [in-cell](slug:treelist-editing-incell#example) and [popup](slug:treelist-editing-popup#example) editing. Also check how to [customize the Delete Confirmation Dialog](slug:grid-kb-customize-delete-confirmation-dialog).
81
+
>tip See the delete operations in action in the complete examples for TreeList [inline](slug:treelist-editing-inline#example), [in-cell](slug:treelist-editing-incell#example) and [popup](slug:treelist-editing-popup#example) editing. Also check how to [customize the Delete Confirmation Dialog](slug:grid-kb-customize-delete-confirmation-dialog).
82
82
83
83
## Commands
84
84
@@ -114,6 +114,8 @@ The following table describes the TreeList events, which are related to adding,
114
114
|`OnModelInit`|[Depends on the TreeList model type](slug:treelist-events#onmodelinit)| Fires when the TreeList requires a [new model instance](#item-instances), which is immediately before `OnAdd` or immediately after `OnEdit`. <br /> Use this event when the TreeList model type is an [interface, abstract class, or has no parameterless constructor](slug:treelist-events#onmodelinit). | No event arguments | Not cancellable |
115
115
|`OnUpdate`| To edit existing items. | Fires on `Save` command invocation for existing items. This event succeeds `OnEdit`. |[Cloned](#item-instances)| TreeList remains in edit mode. |
116
116
117
+
The following considerations apply for the TreeList CRUD events:
118
+
117
119
* Most events provide a [`TreeListCommandEventArgs` argument](#treelistcommandeventargs) in the handler. `OnModelInit` has no event argument.
118
120
* All events, except `OnModelInit`, are cancellable and the user action can be prevented. Cancelling `OnDelete` does not automatically prevent item deletion from the TreeList data source. This depends entirely on the executed application code.
119
121
* The `OnCreate`, `OnDelete`, and `OnUpdate` events are required when using add, delete, and edit operations, respectively. The app must use these events to modify the TreeList data source. [The TreeList does not modify its data directly](#item-instances).
0 commit comments