Textarea contains lot or lines. In jqgrid grid only first line should displayed.
In jqgrid view window more lines and possible scrollbar also should be displayed.
Oleg answer from How to restrict maximum height of row in jqgrid
restricts textarea height in view window also to single line.
How to show first line in grid only but show more lines in jqgrid view form ?
colmodel is:
{"name":"Description",
"edittype":"textarea",
"wrap":"on",
"formatter":function(v){ return '<div style="max-height:20px">'+$.jgrid.htmlEncode(v)+'</div>';
}
,"editoptions":{"class":"","rows":18,"wrap":"off","style":"width:800px",
"readonly":"readonly"
},
"editrules":{"edithidden":true},"editable":true,"width":539,
"classes":"jqgrid-readonlycolumn"}
jqgrid view window shows multiple lines. This should remain the same:
grid shows also multiple lines. This is wrong.:
How to force grid to show only first line in each textarea
Or is is possible to show more lines in bottom of screen: if some row becomes active, first 10 lines from textarea column should appear in bottom. This is like in windows log viewer: moving into event row shows event long data in separate window
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…