How do I set the display text on a link column in jqGrid. I want the text in every column to just say "View" with the link containing the specific Id. Here is what I currently have, but the Id get displayed in the column instead of the text "View". I was hoping to do it without passing the link html in the json returned data.
{ name: 'myId', index: 'View', edittype: 'select', formatter: 'showlink', formatoptions: { baseLinkUrl: 'Consumer/Details', idName: 'myId'} }
My json object getting return looks like this:
select new
{
myId = obj.myId.ToString(),
Date = String.Format("{0:d}", obj.Date),
Description = obj.Description,
View = "View"
}
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…