Forum

July 10th, 2011
You must be logged in to post Login Register

Search Forums:


 






UserPost

14:31
21/09/2010


admin

Admin

posts 56

Today we released 3.8 version of jqGrid. Again with a lot of bugfixes the version add a grouping.

Many thanks to all for the invaluable comments, recommendation and bug fixes.

Many Thanks to Oleg, which do the lot of things and give the community perfect solutions.
Thank you Oleg.

The version can be downloaded form the Download section.
All the changes can be found in 3.8 changes and fixes

The documentation can be found here

In the Download section we have updated the demo files too.

Enjoy.
jqGrid Team.


Read original blog post

20:33
21/09/2010


melissaC

New Member

posts 1

Thanks for all the new updates in 3.8 version.  Keep up the good work.


I have been using the 3.8 beta for 'local' data grid,  I think there is a date formatting bug when I tried to use it in addRowData and setRowData.

In grid.base.js,  for addRowData and setRowdata,

once the date formatter did all the formatting, and reassigned to  lcdata[nm],   lcdata[nm] is never used.

So, I guess  lcdata[nm]  should be  just data[nm]  to override the existing data or v needs to use the lcdata[dm] instead of data[dm].

addRowData function:

for(i = gi+si+ni; i < t.p.colModel.length;i++){
   cm = t.p.colModel[i];
   nm = cm.name;
   lcdata[nm] = cm.formatter && typeof(cm.formatter) === 'string'
      && cm.formatter == 'date' ? $.unformat.date(data[nm],cm) : data[nm];
   v = t.formatter( rowid, $.jgrid.getAccessor(data,nm), i, data, 'edit');
   prp = t.formatCol(i,1,v);
   row += "<td role="gridcell" aria-describedby=""+t.p.id+"_"+nm+"" "+prp+">"+v+"</td>";
}

setRowData function:

if( data[nm] !== undefined) {
   lcdata[nm] = this.formatter && typeof(this.formatter) === 'string'
      && this.formatter == 'date' ? $.unformat.date(data[nm],this) : data[nm];
   vl = t.formatter( rowid, data[nm], i, data, 'edit');
   title = this.title ? {"title":$.jgrid.stripHtml(vl)} : {};
   if(t.p.treeGrid===true && nm == t.p.ExpandColumn) {
      $("td:eq("+i+") > span:first",ind).html(vl).attr(title);
   } else {
      $("td:eq("+i+")",ind).html(vl).attr(title);
   }
}

Thanks,

Melissa.

11:44
22/09/2010


znarfdwarf

Member

posts 3

I also stumpled over the formatting error Melissa mentions. jqGrid seems to ignore the formatter options when adding a date row with addRowData.  When I first sort the grid, the formatting is applied.


Another addRowData-related bug: I use the id option of addRowData to assign a non-sequential id to each table row, e.g.

$gridNode.addRowData('9827', {col1: 'value1', col2: 'value2'});

$gridNode.addRowData('31', {col1: 'value12', col2: 'value22'});


When I re-sort the rendered grid,

 $gridNode.getGridParam('selrow');

suddenly returns the table row index (1 or 2) instead of the assigned ids ('9827' or '31'). When I don't re-sort the grid, the correct ids are reported.

 

Do you plan to fix this bugs soon? I'm not so fond of monkey-patching jqGrid's source files.

 

Thanks for jqGrid!

 

Franz

16:29
22/09/2010


tony

Sofia, Bulgaria

Moderator

posts 7010

@Melissa,

Thank you very much for the investigations.

1. Im'm not sure that the lcdata is not used anymore as you write. Ths lcdata is used to be inserted into the local data array.

As of this code

 if(t.p.datatype == 'local') {
       t.p._index[rowid] = t.p.data.length;
       t.p.data.push(lcdata);
       lcdata = {};
}

The reason that we first unformat the date and put the unformated value in the grid is:

the v value is inserted direct into the grid, but the lcdata contain the reverse date format since we have srcformat and newformat for the date.

You understand what I mean. I think this is not a bug.


@Franz,

For me is very important to know how do you do this:

When I re-sort the rendered grid,

In order to investigate the problem I need a link to the problem or code example.

Thank you

Kind Regards

Tony

11:44
23/09/2010


flack

Member

posts 5

Congratulations on the new release, grouping is a feature I have been waiting for a long time!


There is one request that I have, though: Would it be possible to add an option for sorting to also rearrange groups?


For example, on your demo page if I go to "Simple grouping with array data" and sort by Tax, the group "test" always stays on top, for me, it would be more helpful if it moves to the bottom when I sort with descending order (in group test3 the Tax column always has the value 30, so it should be on top when sort descending is selected)

Keep up the good work!


23:00
24/09/2010


kk

Member

posts 3

Hi,


First of all, thanks for such a wonderful plugin. We have been using it for a while. Grouping is an extremely welcome feature and we have upgraded our version to 3.8 now. Though it works fine on FF, we haven't been able to make it work at all on Chrome browser. 


The Grid gets stuck at 'Loading…' with the following error in the console -

 

jquery.jqGrid.min.js:28Uncaught jqGrid – No such method: groupingCalculations.undefined

 

Since the same code works fine on FF, this might point to a bug in 3.8.

 

Any help/work around/pointers would be greatly appreciated.

 

Thanks again.

 

_K

00:06
25/09/2010


kk

Member

posts 3

Ok. After looking at it a bit more, it seems to be related to Grouping Summary. If I set it to false, the grid displays fine on Chrome 6.


_K

00:59
26/09/2010


angelo.pellegrinon

Member

posts 5

Very thanks for the updates of 3.8 version.

I'm using the new grouping functionality and is wonderfoul.

Question: is there a way to use addRowData and see the new row directly insered into the right group? Or if there is not a group, group it?

At this time when I use addRowData, it inserts the new row like it always do.


Thanks

Angelo

13:22
27/09/2010


mk

New Member

posts 2

Thanks for all the new updates in 3.8 version.  Keep up the excellent work.

The demo download has 2 bugs:

1. the file "js/jquery.min.js" has to be renamed to "js/jquery.js"

2. since 3.6 the "Find records" function is not working. The search modal window is displayed in the table grid and you can not enter any data. See the following hardcopy. I would really appreciate a fix for that.

Thanks

Manfred

find-bug


17:30
28/09/2010


varta

Member

posts 10

I had the same problem. You have to Update the ui.jqgrid.css file.


Martín V.

18:50
28/09/2010


mk

New Member

posts 2

Thank you martin.

For me it does not solve the problem. I had to change ui.jqgrid.css AND jquery-ui-1.8.2.custom.min.js with the one used in the online demo (which is jquery-ui-1.8.1.custom.min).

14:30
08/10/2010


znarfdwarf

Member

posts 3


@Franz,

For me is very important to know how do you do this:

When I re-sort the rendered grid,

In order to investigate the problem I need a link to the problem or code example.


Hi Tony,


sorry for my late reply, I've been busy with other things recently. You can reproduce my bug in four steps:

  • Open Firebug and execute the following statement 

jQuery("#list4").jqGrid('addRowData',83923,{id:"113",invdate:"2010-09-01",name:"outtest3",note:"mynote3",amount:"400.00",tax:"30.00",total:"430.00"} );
  • Re-sort the table by clicking on the Date or Client header
  • Select the newly added row and query its id in firebug with

jQuery("#list4").jqGrid('getGridParam','selarrrow');

This will yield '113' instead of '83923', although '83923' was the explicitely assigned id with the addRow-Statement


regards,


Franz


10:34
11/10/2010


znarfdwarf

Member

posts 3

Another addRowData-Bug i stumpled upon: after i added 37 records with this method, the grid navigator tells me "page 1 of 0″. When I resort the grid by clicking on one of the column headers, the navigator display is correct ("page 1 of 2″)

13:41
20/10/2010


angelo.pellegrinon

Member

posts 5

Hello!

The plugin is great!

It'll be fantastic to have scrolling enabled with the grouping function!

20:13
20/10/2010


MattyCiii

Member

posts 4

Hello,

It appears Multiple Search no longer works on locally loaded data.  Both IE8 and FireFox 3.6.8, the search icon will not display.  I'm pretty sure I have everything loaded and configured correctly, I updated a page that worked fine under jqGrid 3.7


Any thoughts?

14:55
12/02/2013


akanaujia

New Member

posts 2

hi

I used jqgrid 3.8 Beta. I am getting an error on getRowData method i.e. t.p.colModel[i].name null  as per the given content. Please suggest the solution. Thansk in advance.


getRowData : function( rowid ) {
		var res = {}, resall, getall=false, len, j=0;
		this.each(function(){
			var $t = this,nm,ind;
			if(typeof(rowid) == 'undefined') {
				getall = true;
				resall = [];
				len = $t.rows.length;
			} else {
				ind = $t.rows.namedItem(rowid);
				if(!ind) { return res; }
				len = 2;
			}
			while(j<len){
				if(getall) { ind = $t.rows[j]; }
				if( $(ind).hasClass('jqgrow') ) {
					$('td',ind).each( function(i) {
						nm = $t.p.colModel[i].name; 
						if ( nm !== 'cb' && nm !== 'subgrid' && nm !== 'rn') {
							if($t.p.treeGrid===true && nm == $t.p.ExpandColumn) {
								res[nm] = $.jgrid.htmlDecode($("span:first",this).html());
							} else {
								try {
									res[nm] = $.unformat(this,{rowId:ind.id, colModel:$t.p.colModel[i]},i);
								} catch (e){
									res[nm] = $.jgrid.htmlDecode($(this).html());
								}
							}
						}
					});
					if(getall) { resall.push(res); res={}; }
				}
				j++;
			}
		});
		return resall ? resall: res;
	},

-AK

About the jQuery Grid Plugin – jqGrid forum

Most Users Ever Online:

157


Currently Online:

27 Guests

Forum Stats:

Groups: 1

Forums: 7

Topics: 9596

Posts: 28792

Membership:

There are 10195 Members

There have been 448 Guests

There is 1 Admin

There are 2 Moderators

Top Posters:

OlegK – 1157

markw65 – 179

kobruleht – 144

phicarre – 126

YamilBracho – 124

Renso – 118

Administrators: admin (56 Posts)

Moderators: tony (7010 Posts), Rumen[Trirand] (81 Posts)




Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information