leora
leora

Reputation: 196539

can you replicate all buttons on the top in jqgrid

i see in jqgrid you can move the pager up to the top of the grid and the default buttons but i wanted to see if you can move the entire row (including buttons default and custom along with the pager) to the top above the grid ?

if i use clonetoTop it only moves the regular buttons but not ones that i add dynamically

Update:


As you can see below, i added my own personal RefreshGrid button using this code and its not showing up at top:

 .navButtonAdd('#pager', {
            caption: "",
            title: "Reload Grid",
            buttonicon: "ui-icon-refresh",
            onClickButton: function () {
                $(gridSelector).trigger("reloadGrid");
            },
            position: "last"
        });

enter image description here

Upvotes: 3

Views: 4797

Answers (1)

Oleg
Oleg

Reputation: 221997

The parameter cloneToTop:true of the navGrid do what you need:

$("#list").jqGrid('navGrid', '#pager', {cloneToTop: true});

See here and here for additional information.

Upvotes: 4

Related Questions