tags:

views:

132

answers:

1

i want to add one more tool bar with different buttons in the bottom of the header. is there any possibilities?

used

 toolbar: [true,"top"] or toolbar: [true,"bottom"] 

its showing same toolbars... in the bottom toolbar contains Add, edit, delete buttons.. i want to make change in top toolbar contains ADD button only.. & bottom toolbar contains Edit, Delete, refresh, etc.,

Thank you,

+1  A: 

Probably you misunderstood toolbar parameter of the jqGrid. Perhaps you want use Navigator having cloneToTop: true which works if you define additionally toppager: true jqGrid option. This option clone the pager div on the top of the jqGrid. After this one can easy remove some elements from the top or bottom "toolbar":

jQuery("#list").jqGrid({
    // some parameters
    toppager: true,
    // some other paremeters
}).jqGrid('navGrid','#pager',{cloneToTop:true});

var topPagerDiv = $("#list_toppager")[0];
$("#edit_list_top", topPagerDiv).remove();
$("#del_list_top", topPagerDiv).remove();
$("#search_list_top", topPagerDiv).remove();
$("#refresh_list_top", topPagerDiv).remove();
$("#list_toppager_center", topPagerDiv).remove();
$(".ui-paging-info", topPagerDiv).remove();

var bottomPagerDiv = $("div#pager")[0];
$("#add_list", bottomPagerDiv).remove();

The part "list" of different id names from the code above will be used because we use <table> element with id="list".

Oleg
thank you so much Oleg. this is exactly want i needed. many thanks to u. u saved my time..
jerry