Forum


10:18

11/10/2008

I have to be doing something stupid. No one else seems to have this problem. jQuery 1.2.6 and jgGrid 3.3
see example: http://qindy.com/map/popup-lis.....e=rtb_list
Clicking the row doesn't check/uncheck the checkbox. I determined that the checkbox id's are all 'jgq_' (no id appended to them).
From the code it appears this id is created from the <tr> id, which I see set to the appropriate values for each row (using Firebug in Firefox to examine this). They are the 'id' values I extract from my database and which are in the 'id' element of my JSON 'rows' element.
I've stepped through the grid.base.js and the id simply seems to be undefined when the checkbox id is created. If I edit the id into them with Firebug, the checkbox works correctly.
And, here's one grid-row of data from my JSON response:
"page": "1",
"total": 1,
"records": "322",
"rows": [
{
"id": "376",
"cell": [
"2414-16 N Kitley Av<\\/span>",
"VIEW<\\/a>",
"2 Unit",
"2br 1ba",
"No",
"$2,500.00",
"$749.00",
"$74,934.00",
"Map<\\/a>"
]
},
Been looking at this for hours and just don't see why this happens.
Don
11:01

Moderators
30/10/2007

Hello,
It is definitley a bug. It will be corrected.
Thank you
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:37

Moderators
30/10/2007

Hello,
In the example is set in the options multikey: false and this work -
i.e - in the code there should be some additional checking for this options
Thank you
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:40

Moderators
30/10/2007

Hello,
sorry multikey is true and not false
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:51

Moderators
30/10/2007

But at all this is not the problem 🙂
The problem is that there is no id for the checkbox. I will look why?
P.S. This help me to find any other issue with this (My first post)
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:57

Moderators
30/10/2007

Here is it
The problem is - there is no id for the checkbox.
This happen only when using json data - i.e. the id is obtained after constructing the check box - must be before - It is fixed.
Alse the second bug , which actuall was first for me is fixed too.
Thank you
Reagrds
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
16:35

11/10/2008

To all, until Tony makes another release, I offer the following workaround/fix:
in grid.base.js at line 740 (release version 3.3)
add: row.id = cur[idn];
See below for the relevant section of code I modified:
if (drows) {
for (var i=0;i<drows.length;i++) {
cur = drows[i];
row = document.createElement("tr");row.id = cur[idn];
if(ts.p.multiselect){
addMulti(t,row);
gi = 1;
}
if (ts.p.subGrid) {
try { $(ts).addSubGrid(t,row,gi);} catch (e){}
si= 1;
}
My change is in BOLD
Most Users Ever Online: 715
Currently Online:
72 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