datagrid=$('#datagrid').datagrid({ pagePosition:'bottom', height:fixHeight(1,30), ...
// 将百分比高度转为固定宽度 如:0.1 -> px function fixHeight(percent,offset)
{ return (document.body.clientHeight-(offset==undefined?0:offset)) * percent ; }
datagrid=$('#datagrid').datagrid({ pagePosition:'bottom', height:fixHeight(1,30), ...
// 将百分比高度转为固定宽度 如:0.1 -> px function fixHeight(percent,offset)
{ return (document.body.clientHeight-(offset==undefined?0:offset)) * percent ; }
转载于:https://my.oschina.net/maoguangdong/blog/788558