GanttContextMenuBuilder.Items(Action<CollectionFactory<GanttContextMenuItemBuilder>>) Method
Configures context menu item settings. Mirrors the client-side items option.
Namespace: DevExtreme.AspNet.Mvc.Builders
Assembly: DevExtreme.AspNet.Core.dll
Declaration
public GanttContextMenuBuilder Items(
Action<CollectionFactory<GanttContextMenuItemBuilder>> configurator
)
Parameters
Name | Type | Description |
---|---|---|
configurator | Action<CollectionFactory<GanttContextMenuItemBuilder>> | A function that configures toolbar options. |
Returns
Type | Description |
---|---|
GanttContextMenuBuilder | A reference to this instance after the method is called. |
Remarks
@(Html.DevExtreme().Gantt()
.ContextMenu(cm => {
cm.Items(i => {
i.Add().Name(GanttContextMenuItem.AddTask);
i.Add().Name(GanttContextMenuItem.TaskDetails);
i.Add().Name(GanttContextMenuItem.DeleteTask);
i.Add().Name("ToggleDisplayOfResources").Text("Toggle Display of Resources");
});
})
//...
)
See Also