/// <summary> /// Defines a edit button. /// </summary> /// <returns></returns> public ImageButtonBuilder Edit() { var button = ImageButtonBuilder.GridEdit(); Column.ButtonSet.Add(button); return(button); }
public GridCrudCommandsColumnBuilder <T> All() { templateColumnBuilder.HeaderTemplate(ImageButtonBuilder.GridAdd().ToHtmlString()); templateColumnBuilder.ClientTemplate(ImageButtonSetBuilder.NewSet() .Add(ImageButtonBuilder.GridEdit()) .Add(ImageButtonBuilder.GridDelete()) .ToHtmlString()); rowCommandType = RowCommandType.All; return(this); }
public GridCrudCommandsColumnBuilder <T> Delete() { if (rowCommandType == null) { templateColumnBuilder.ClientTemplate(ImageButtonBuilder.GridDelete().ToHtmlString()); rowCommandType = RowCommandType.Delete; return(this); } if (rowCommandType == RowCommandType.Edit) { templateColumnBuilder.ClientTemplate(ImageButtonSetBuilder.NewSet() .Add(ImageButtonBuilder.GridEdit()) .Add(ImageButtonBuilder.GridDelete()) .ToHtmlString()); rowCommandType = RowCommandType.All; } return(this); }