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
This topic is locked No permission to create posts
sp_Feed Topic RSS sp_TopicIcon
jqGrid 3.6 beta
02/11/2009
10:28
Avatar
Mark C
Guest
Guests

MarkW,

I thought jqgrid handled that from reading the docs:

Note the id attribute in the <row> tags. While this attribute can be omitted, it is a good practice to have a unique id for every row. If this attribute is omitted, jqGrid has two ways of dealing with need for unique ids: if the property key in the colModel is set to true for a particular column, then jqGrid will assign the value of this column to be the id of the row; otherwise, jqGrid sets the row id based on the order of the row.

I didn't think my table structure of 4 key fields making up the primary key (ITEM/PO/LINE/CAST) fiited the row-id attribute model, so i just presumed it got handled.

And all i use for this project is getRowData(id) on a users double click, not sure if that comes into teh category of serious work as i only use the grid.base.js no editing/formatting required.

Do you suggest some how introducing a Autoincrement field to represent teh row-id attribute and restructuring my table to allow this.

Or shall i leave it if you are going to handle this with a fix.

Thanks for your time, much appreciated.

Regards

Mark C

02/11/2009
10:39
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Mark,

If you are sure that this will break the code we can get back not using call

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.

02/11/2009
11:14
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Mark C,

Yes, the grid should support it. It does so by assigning the row number (within the page) as the id. That works for paged grids, but not for scrolling grids. I will fix that.

So the "serious work" comment 🙂

The issue is that if your data on the server is changing, then you really need your own ids. If the data is static, you're ok with generated ids (or you will be, once I fix the id issue).

Mark

02/11/2009
11:25
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Tony,

I pushed a fix for the loadComplete issue, and the simplest possible fix for the shared grid/p issue.

On the callback issue - it /shouldnt/ break code that only uses the documented features. And it will make it much easier to write generic callbacks (ie ones that dont have to know which grid they belong to).

But there are a handfull of callbacks where "this" used to be the parameter object, and now its not - obviously it /could/ break code. I think it will be rare (and should only affect people like me who've looked inside the grid code).

So, I hope we can keep it - but its your call... (I should have kept quiet - and probably would have done if Id thought about it a bit longer!)

Mark

02/11/2009
11:40
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Mark,

Thanks. I will test it. Looking brief into the code it seems that there will be not so much problems. Let see..

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.

02/11/2009
12:12
Avatar
MarkC
Member
Members
Forum Posts: 14
Member Since:
02/11/2009
sp_UserOfflineSmall Offline

MarkW,

My data is fixed, its a table of existing doucments for a finished contract, it will never be added to/edited just searched, hence why I did not include an auotinc field to index the grid.

look forward to the fix.

Kind Regards

MarkC

02/11/2009
13:35
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Tony: I've pushed the row id fix to my fork of the grid.

MarkC: if you have git installed, you can get the updated .js direct from markw65/jqGrid (or look at the changes, and copy them - its only a few lines).

Mark

03/11/2009
08:48
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Mark,

I have merged the changes, but today I again have no luck with GitHub, so You can't see them.

My first test are OK with these changes.

I will hold down 3.6 release for some other days, untill I'm sure that all work OK.

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.

03/11/2009
13:48
Avatar
Liam
Guest
Guests

Hey guys, I was wondering if I will be able to use the column reorder functionality to return the new position of a column, or some other way to access the order of all of the columns.  Thanks.. everything else looks fantastic.  

Liam

03/11/2009
15:29
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

tony said:

I have merged the changes, but today I again have no luck with GitHub, so You can't see them.


Might be worth posting about this on the github support site... I was having similar problems (push would fail intermittently, and clone failed 100%) a couple of weeks ago, and they found some inconsistencies in the database, which they were able to fix by running git gc at their end. My problems went away...

Mark

03/11/2009
15:38
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Liam said:

Hey guys, I was wondering if I will be able to use the column reorder functionality to return the new position of a column, or some other way to access the order of all of the columns.


After column reordering, colModel is updated with the new order.

You can use $("mygrid").jqGrid("getGridParam", "colModel") to get the array. Also, by default, the current permutation is recorded in the "remapColumns" array.

var rc = $("mygrid").jqGrid("getGridParam", "remapColumns")

if (rc && rc.length) {

   // rc[i] is the original position of the current i'th column

} else {

   // columns havent been reordered yet

}

Mark

}

03/11/2009
23:42
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Tony,

One more small bugfix. remapColumns didnt update the footer when updateCells was false. This is wrong, because even if you rewrite the footer, it doesnt regenerate the td's, it just sets their contents.

Mark

04/11/2009
03:55
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Mark,

Yes. The footer shold have the consistency of the header.

Fixed.

Also I wait for the support response from GitHub

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.

05/11/2009
03:24
Avatar
aurelien.pernoud
Member
Members
Forum Posts: 5
Member Since:
28/07/2009
sp_UserOfflineSmall Offline

markw65 said:

The bgiframe trouble can easily be solved: turn on bgiframe! (include bgiframe in your header, and then set $.ui.dialog.defaults.bgiframe = true)

I'll try to take a look at the loading while scrolling problem tonight…

Mark


Hi Mark,

I agree this will probably solve the issue, but have a look at all others dialogs of jqgrid (in the demo), they don't need it.

Ex in "NEW API" from 3.6 demo, open the "search" modal dialog, you'll see the paging combo will disappear, without us having to include anything ? Why applying a fix only for the new column chooser (BTW really nice job on it).

I also saw your scrolling problem reply, and hope you'll find a way to fix it, IE 6 is a real mess to deal with 🙁

Aurelien

05/11/2009
09:05
Avatar
markw65
Member
Members
Forum Posts: 179
Member Since:
30/07/2009
sp_UserOfflineSmall Offline

Aureliaen,

The ie6 scrolling problem and various other scroll issues are fixed in the latest github. I think my latest fix (for MarkC) isnt there yet because tony is having problems with github 🙁

The bgiframe issue: all the other dialogs use jqModal, and I think it has a bgiframe equivalent built in. The column chooser is actually very customizable - you can use essentially any "unobtrusive" mutiselect plugin, and any "dialog" - its just setup by default to use ui.dialog and ui.multiselect.

The reason is that I initially implemented it outside of jqgrid for my own project (which already uses multiselect and dialog) - and then realized it would make a nice general purpose addition to jqGrid. If I get time, I'll figure out how to set it up to use jqModal instead of ui.dialog, and post an example.

Mark

05/11/2009
09:07
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello All,

The today release for the 3.6 version of jqGrid is changed for November 8, 2009.

The reasons are mostley connected with some problems in GitHub. I hope that they will be corrected to this date.

I have published a 3.6 RC which can be downloaded from the same place of the original blog post for 3.6 beta again with the demo files. Also the zip contain Changes.txt file with all fixes, news and changes.

The documentation in the wiki is updated to this release.

I think that this is very impresive – the docs are redy before the release Wink

Best 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.

05/11/2009
09:35
Avatar
jhsu
Member
Members
Forum Posts: 23
Member Since:
05/11/2009
sp_UserOfflineSmall Offline

Hi Tony and Mark,

First of all, I'd like to say jqGrid is a fantastic plugin. The best I've seen so far for web apps with the feature set and performance offered. Thank you so much!

Now with the issues I've experienced with the latest v3.6 version (as of Nov 3) I played with:

1. CSS display issues with the paging bar at the bottom of the grid: On IE6 and IE7, the total pages indicator seems to be wrapped and pushed off to the next line when the number has more than 3 digits. On firefox, safari and chrome, the row number select list is cropped slightly to the right. see [Image Can Not Be Found] (jqGrid page bar browser comparisonImage Enlarger)

2. Paging with scrolling feature: sometimes, the content of the grid does not display after scrolling, even though the data comes through from the server. Also, the scrolling feature tends to retrieve the data several times while the user's mouse is still in scrolling. I think it'd be better if it could be made to retrieve data once after the mouse button is released from the scroll bar.

Thank you again with your amazing work on jqGrid.

Jack

05/11/2009
10:24
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello Jack,

Thanks.

About the first issue - just now I have do the fix. It will be available in the final 3.6 Release.

About the second I have only once such situation, but currently I can not reproduce it again. Will continue to investigate the problem

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.

05/11/2009
10:51
Avatar
jhsu
Member
Members
Forum Posts: 23
Member Since:
05/11/2009
sp_UserOfflineSmall Offline

Thanks a lot Tony!

For the second issue with page scrolling, the display problem seems to occur in IE6 and IE7 only, especially when the grid gets reloaded by the following code:

        var params = getSearchParams();
        $("#searchGrid").jqGrid('setGridParam', { postData: params, page: 1 }).trigger('reloadGrid');

However, i find that the page scrolling features from the v3.6 demo works great on IE6 and IE7.

As for the retrieving data part, the behaviour of hitting the server several times before the mouse is released from the scroll bar seems to be consistent across all the browsers I tested, IE6, IE7, firefox, Safari and Chrome.

Thanks again for being so quick with your reply.

Jack

05/11/2009
15:31
Avatar
Roman
Guest
Guests

Great job on the new version of jqGrid and thank you for expanding Ajax options with the new “ajaxGridOptions” parameter. This makes it a lot easier to make jqGrid pull data from ASP.NET WebServices / WCF (since they prefer to respond to HTTP Posts rather than Gets).   I have two suggestions to improve this new feature though. 

  1. Some of the newer browsers now have a native JSON object which allows for improved performance in JSON parsing over using “eval” (see: http://encosia.com/2009/07/07/.....security/).
  2. Because of a workaround for an XSS vulnerability, ASP.NET 3.5 started wrapping return values of WebServices into a “d” object ( see: http://encosia.com/2009/06/29/.....s-d-again/ ).

In grid.base.js, replacing the following line ( should be around line 56 in the file ) in the "parse" method

msg = eval('(' + js + ')');

with

var msg;

if(typeof (JSON) === 'object' && typeof (JSON.parse) === 'function') {
    // Native JSON parsing is available.
    msg = JSON.parse(js);
} else {
    // This boils the response string down into a proper JavaScript Object().
    msg = eval('(' + js + ')');
}

// If the response has a “.d” top-level property, return what's below that instead.
if(msg.hasOwnProperty('d')) {
    return msg.d;
} else {
    return msg;
}

would address both native JSON parsing and the new “d” wrapper object in ASP.NET 3.5.

This topic is locked No permission to create posts
Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
50 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