How to keep a ActionLink to each row of the JQGrid

Posted by ramuvalmiki07-22001 under jQuery on 5/30/2013 | Points: 10 | Views : 1686 | Status : [Member] | Replies : 0
Hii to all,
I have done successfully,in getting the tables data from database & displayed in JQGrid.Now i want to add one more column to my JQGrid that should be an ActionLink say "EDIT",i.e i want to add a Link button to each row of my JQGrid,so that whenever user clicked on ActionLink it has to redirect to another View,and also it has to get the respective row data say some cell value(id)..This is my JQGrid

datatype: "local",
data: mdata,
colNames: ["EmployeeID", "EmpName", "Designation", "Salary", "MobileNo", "Email", "EDIT"],
colModel: [
{ name: "EmployeeID", index: "EmployeeID", sortable: false,
editable: true, edittype: 'checkbox', editoptions: { value: 'true:false' }
{ name: "EmpName", index: "EmpName" },
{ name: "Designation", index: "Designation" },
{ name: "Salary", index: "Salary", sorttype: "int" },
{ name: "MobileNo", index: "MobileNo", sorttype: "int" },
{ name: "Email", index: "Email" },
{ name: 'EditAction', formatter: 'showlink', formatoptions: { baseLinkUrl: '@Url.Action("Edit")'} },

shrinkToFit: true,
viewrecords: true,
sortorder: 'asc',
caption: "Employee List"

I have tried with the following but didn't get the Links column
name: 'EditAction', formatter: 'showlink', formatoptions: { baseLinkUrl: '@Url.Action("Edit")'} },

Please help me how can i show a links to each row..Thanks in advance



(No response found.)

Login to post response