This question is locked. New answers and comments are not allowed.
I have the following for my script, the problem is that the "Select, "Add New", "Edit" all show the same route for the url. And Delete doesn't show one.
Select: http://localhost:4381/aaaaaa/Index/1?Search=test&showInActive=False&mode=select
Add: http://localhost:4381/aaaaaa?Search=test&showInActive=False&mode=insert
Edit: http://localhost:4381/aaaaaa/Index/1?Search=test&showInActive=False&mode=edit
And why does "Add" not show the Index?
Now the ActionLink approach works find but the buttons don't. Any reason why this is the case? Also what is there a "mode" parameter as this is redundant when using proper routing.
Select: http://localhost:4381/aaaaaa/Index/1?Search=test&showInActive=False&mode=select
Add: http://localhost:4381/aaaaaa?Search=test&showInActive=False&mode=insert
Edit: http://localhost:4381/aaaaaa/Index/1?Search=test&showInActive=False&mode=edit
And why does "Add" not show the Index?
Now the ActionLink approach works find but the buttons don't. Any reason why this is the case? Also what is there a "mode" parameter as this is redundant when using proper routing.
Html.Telerik().Grid(Model)
.Name("Project")
.PrefixUrlParameters(false)
.ToolBar(commands => commands.Insert())
.DataKeys(dataKeys => dataKeys.Add(c => c.ProjectId))
.DataBinding(dataBinding =>
{
dataBinding.Server()
.Select("Index", "aaaaaa",
new
{
Search = (string) ViewData["Search"],
showInActive = (Boolean) ViewData["showInActive"]
});
dataBinding.Server().Update("Edit", "PPPP", new {});
dataBinding.Server().Insert("Add", "EEEE", new {});
dataBinding.Server().Delete("Delete", "FFFFF");
})
//Template column which shows an action link
.Columns(columns =>
{
columns.Command(commands => commands.Select()).Title("Select");
columns.Template(o =>
{
columns.Command(commands =>
{
commands.Edit();
commands.Delete();
}).Width(180).Title("Commands");