Reputation: 698
How do I show row numbers in JqGrid ? My 'grid.js' is:
grid : { 'url':'cs?action=getGridContent&gridType=1001', 'col_names':['№','Qeydiyyat nömrəsi','Qeydiyyat tarixi','İmzalayan şəxs' , 'İcraçı şöbə','','',''], 'col_model': [ {name: 'r', index: 'r', sorttype: 'int', width:'10'}, {name: 'col2', index: 'col2', sorttype: 'text', width:'40' }, {name: 'col3', index: 'col3', sorttype: 'date', width:'30' }, {name: 'col4', index: 'col4', sorttype: 'text', width:'35' }, {name: 'col5', index: 'col5', sorttype: 'text', width:'30' }, {name: 'docid', index: 'docid', sorttype: 'date', width:'10',hidden:true }, {name: 'doctypeid', index: 'doctypeid', sorttype: 'date', width:'10',hidden:true } , {name: 'docclass', index: 'docclass', sorttype: 'date', width:'10',hidden:true } ], sortname: 'col3', sortorder: "desc" }
I can't add automatic number per row.
Upvotes: 2
Views: 11983
Reputation: 222017
You should first read the official documentation with the list of supported options. The option which shows row numbers is
rownumbers: true
Upvotes: 10