Forum


16:05

16/01/2012

Hi all !
After hours of searching an answer, here i am.
I'm on jqGrid 4.3.1.
I implemented the del function on the navgrid and I got an issue when pushing the corresponding button when no row is selected. I'm well getting the alert modal with "Warning, no data selected", but :
- On Firefox : if I'm at the end of my page (I have 100 records on a page) the scroll bar doesn't go at the top of the screen. Doing so, the user can miss the popup. Actually, the focus of the page is move just under the alert modal.
- On Internet Explorer 8 : it's worth. The screen move like on Firefox but the overlay is displayed like if it's on "display: block". So the overlay is on the top of the page and the content is under the page.
Here are some screens of those bugs :
Bug in Firefox after clicking on "delete" (I changed the icon). The alert modal is in red :
[Image Can Not Be Found]
Bug in Internet Explorer :
Do you have any idea that explain why I got those bugs ?
As I didn't find any solution, I wanted to not to display this popup. But I didn't find a way to do that…
Any help would be appreciated.
12:31

16/01/2012

Hi there,
As nobody was able to help me, I chose to hide the butons when nothing is selected. Doing so, user is not able to show the alertmod. Here is how to hide the butons when nothing is selected (this is an option of the jqGrid() function):
onSelectRow: function (rowid) {
thisId = $.jgrid.jqID(this.id);
if (jQuery("#mygrid").jqGrid('getGridParam','selarrrow') != "") {
$("#del_" + thisId).removeClass('ui-state-disabled');
$("#del_" + thisId + "_top").removeClass('ui-state-disabled');
} else {
$("#del_" + thisId).addClass('ui-state-disabled');
$("#del_" + thisId + "_top").addClass('ui-state-disabled');
}
return true;
}
Most Users Ever Online: 715
Currently Online:
52 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66