ParamQuery grid support forum
General Category => ParamQuery Pro Evaluation Support => Topic started by: Ajay on July 02, 2015, 02:55:40 pm
-
Hi ,
I have purchased the licensed version of pQ grid.
Before I am using PQ grid 1.1.3,the time it took to load the grid is far better than PQ3.0.0 version.
Here is my Code:
searchUsrGrid.pqGrid({
width: NMCApp.getSearchGridWidth(),
height: NMCApp.getSearchGridHeight(),
editable: false,
numberCell: false,
roundCorners: false,
wrap: false,
colModel: columnModel,
dataModel: { data: [] },
showTop: false,
showBottom: false,
scrollModel: { pace: 'consistent' },
hoverMode: 'row',
selectionModel: { type: 'row', mode: 'single' },
rowSelect: function (event, ui) {
try {
selectedUser = ui.rowData;
}
catch (error) {
NMCApp.showNMCExceptionWindow('Jquery Error:' + error);
}
},
});
function searchUsers() {
$.ajax({
type: 'GET',
url: searchUrl + '&skip=' + startIndex,
contentType: 'application/json; charset=utf-8',
dataType: 'json',
processdata: false,
cache: false,
success: function (data, textStatus, request) {
try{
for (var i = 0; i < data.length; i++) {
users.push(data);
}
if (data.length == NMCApp.getMaxSearchNumber() && NMCApp.isSearchCancelled() == false) {
searchUsrGrid.pqGrid("option", "dataModel.data", users);
model.numberOfUsers(users.length);
startIndex = startIndex + NMCApp.getMaxSearchNumber();
searchUsers();
}
else {
searchUsrGrid.pqGrid("option", "dataModel.data", users);
if (users.length > 0)
searchUsrGrid.pqGrid("setSelection", { rowIndx: 0 });
model.numberOfUsers(users.length);
if (NMCApp.isSearchCancelled() == false) {
NMCApp.hideLoadingWindow();
model.numberOfUsers(users.length);
}
else
model.numberOfUsers(users.length + ' (cancelled)');
}
searchUsrGrid.pqGrid("refreshDataAndView");
}
catch (error) {
NMCApp.showNMCExceptionWindow('Jquery Error:' + error);
}
},
error: function (request, status, error) {
NMCApp.hideLoadingWindow();
}
});
}
1)Can you please let me know why the latest version is taking more time to load data on to the grid.
For example: I am having 45,000 records to display on Grid.
with PQ 1.1.3, it is taking less time than 1:20
Where as with PQ 3.0.0, it is taking more than 4 min.
2)One more query,I am showing one loading windows when the data is getting loaded in to the gird.
In pQ 1.1.3,it is allowing user to can cancel the loading window.
In PQ 3.0.0,it is not allowing user to Cancel the loading window and the browser get hangs.
Could you please let me know how to resolve the aboe issues.
-
1. It has been replied here:
http://paramquery.com/forum/index.php?topic=1215.0
2. Your 2nd issue also seems related to 1st one.
Also if you have lot of grids you can enable virtual mode for all of them at once by adding 2 lines before initialization of the grids:
$.paramquery.pqGrid.prototype.options.virtualX = true;
$.paramquery.pqGrid.prototype.options.virtualY = true;
Please let me know whether it resolves your issues.
-
Hi
Thanks it worked.
For point 2.
I have removed z-index:0 property from pQ-Grid-min.css and it worked.