¡@

Home 

2014/10/16 ¤W¤È 12:04:58

jquery Programming Glossary: maingridprefix

JQuery Grid-SubGrid for Parent-Child relation

http://stackoverflow.com/questions/14194754/jquery-grid-subgrid-for-parent-child-relation

can follow the answer or another one . The demo demonstrate the implementation approach It uses the following code var mainGridPrefix s_ #grid .jqGrid url Adofo.json datatype json colNames First Name Last Name colModel name givenName name familyName cmTemplate.. 20 rowList 20 40 60 pager #pager gridview true caption Contacts rownumbers true autoencode true height 100 idPrefix mainGridPrefix subGrid true jsonReader repeatitems false beforeProcessing function data var rows data.rows l rows.length i item subgrids.. function subgridDivId rowId var subgrid table id ' subgridDivId _t' table pureRowId .jgrid.stripPref mainGridPrefix rowId subgrids this .jqGrid getGridParam userData subgrid.appendTo # .jgrid.jqID subgridDivId subgrid.jqGrid datatype local..

Resize SubGrid Columns on resizing main grid

http://stackoverflow.com/questions/14216113/resize-subgrid-columns-on-resizing-main-grid

Value 3.4 subgridData id 10 c1 ga c2 gb c3 gc c4 gd id 20 c1 ha c2 hb c3 hc c4 hd id 30 c1 ia c2 ib c3 ic c4 id mainGridPrefix s_ #list .jqGrid datatype local data myData colNames Column 1 Column 2 Column 3 Column 4 colModel name c1 width 100 name.. #pager gridview true ignoreCase true rownumbers true sortname c1 viewrecords true autoencode true height 100 idPrefix mainGridPrefix subGrid true subGridRowExpanded function subgridDivId rowId var subgrid table id ' subgridDivId _t' table pureRowId .jgrid.stripPref.. function subgridDivId rowId var subgrid table id ' subgridDivId _t' table pureRowId .jgrid.stripPref mainGridPrefix rowId colModel this .jqGrid getGridParam colModel subgrid.appendTo # .jgrid.jqID subgridDivId subgrid.jqGrid datatype local..