Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Bug?...Grids with the same gridId - onCompleteTopics only gets called once...
15/03/2010
18:00
Avatar
mikesmith
Member
Members
Forum Posts: 47
Member Since:
26/01/2010
sp_UserOfflineSmall Offline

Hi fellow jqgrid users....

In my application I have many jsps each holding a grid. These grids are in the different jsp pages & all have the same gridId but have different columns and store different data.

I give the grids the same id because I am using a generic javascript function which all these pages access and call to update the grid. (add an image to a specific column depending on data returned from the server).  The same gridId implies less work for me.

All my grids subscribe to the onCompleteTopics which will invoke a javascript function passing in the columnId to be updated after the grid is complete.

The problem I have noticed is that onCompleteTopics only gets called once! Even if I access a brand new jsp page, holding a brand new grid but if it has the same gridId(as a previous grid even on another jsp), onCompleteTopics does not get called again. This problem causes my grid not update properly. Infact the wrong column gets updated!

Is This a Bug in jqgrid or a bug in my strut2 plugin or should I be doing something different? How can I ensure that whenever I go to a new jsp, when loading the grid, that onCompleteTopics will be called regardless?

I am sure if I rename all the gridIds in my entire application to unquie names, then this will work. But this will hinder me greatly & cause me a lot of trouble!

Help is greatly appreicated..

15/03/2010
19:58
Avatar
mikesmith
Member
Members
Forum Posts: 47
Member Since:
26/01/2010
sp_UserOfflineSmall Offline

Just an update… I have figured out why my grids are not calling their respective onCompleteTopics.

Its because all my grids are subscribed to the same topic. This means the first grid works fine but when subsequent grids which call the same topic are executed, they are infact using the save values as the first topic. I dont quite understand the whole topic thing but if I change the grid to subscribe to another topic, it works fine!

if this is the case is this my only solution(i.e: to ensure that all grids call a unquie topic?)

what happens if I subscribe to lots of topics...do i have topics floating around in the client? is there a performance hit?

thanks again

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
48 Guest(s)

Currently Browsing this Page:
1 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.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information