Thanks Kevin for answering,
I am not that familiar with handling the jQuery-objects.
I created the datagrid completely by javascript. For that I have created the pagination like that
var TrailPager = $('#edgTrail').edatagrid('getPager');
TrailPager.pagination({
showPageList: false,
showRefresh : false,
displayMsg : '{from} bis {to} von {total} Tabellen'
,buttons :[
{iconCls:'icon-add' ,handler:function(){addTrail();}}
,{iconCls:'icon-edit' ,handler:function(){editTrail();}}
,{iconCls:'icon-remove',handler:function(){removeTrail();}}
,{iconCls:'icon-save' ,handler:function(){saveTrail();}}
,{iconCls:'icon-undo' ,handler:function(){undoTrail();}}
]
});//TrailPager
Now I would like to control the visibility of the buttons regarding on the privilege-value which in some way must sent by the server. When the datagrid code sends the data request via url to the server it gets the result-set via json back. For my model-structure it seems to me the best to use the additional json-object "privilege". But how?
here is the modified json-file:
TrailList => {"privilege":"1","total":"17","rows":[{"OLT50A001T_KEY":"10000002","TRY_YEAR":"1989","TRY_ROUTE":"Rheurdt (DE) - Grote Brogel (BE)"}]}