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
Multi-level grouping summary mis-calculations or misplacement
13/07/2014
08:41
Avatar
ricardo
Member
Members
Forum Posts: 3
Member Since:
13/07/2014
sp_UserOfflineSmall Offline

I have a jqgrid configuration with three-level grouping and summary totals for revenue column. 

It does well in terms of the desired grouping.

However, when it comes to summaries, only the two outermost level groupings are showing the correct sum total. The innermost group-levels are showing exactly the same summary value as the parent group-level when it shouldn't. 

For example,

Group A has a revenue total of $8,000,000;

Group A1 has $4,500,000;

Both Group A1.i and Group A1.ii both shows $4,500,000 (same as the parent level group) , when it should be $1,500,000 and $3,000,000 respectively adding up to the parents total.      

-Same pattern for all third-level groupings.-

 

I will appreciate all the help on this.

 Here is the code:

jQuery("#48remote4").jqGrid(
{
data: result.ReportLines,
datatype: "local",
colNames:['LoB ', 'type' , 'Account Number', 'Service Code','Total'],
colModel:[
{
name:'LoB',index:'LoB', editable:true, align:"center",sorttype:'text', hidden:false
},
{
name:'Type',index:'Type', editable:true, align:"center",sorttype:'text', hidden:false, width:30
},
{
name:'AccountNumber',index:'AccountNumber', editable:true, align:"center",sorttype:'text'
},
{
name:'ServiceCode',index:'ServiceCode', align:"center", sortable:true, width:90
},
{
name:'NetRevenue01',index:'NetRevenue01',align:"right",summaryType:'sum', summaryTpl : '<b>{0}</b>',formatter:'currency', width:70
}
],
rowNum:1000,
rowList:[100, 200, 500, 1000],
height: 'auto',
width: 'auto',
pager: '#p48remote4',
sortname: 'AccountNumber',
viewrecords: false,
sortorder: "asc",
caption:"Annual Revenue Report",
grouping: true,
groupingView:
{
groupField : ['LoB', 'Type', 'AccountNumber'],
groupColumnShow : [true, false, true],
hideFirstGroupCol:true,
groupText : ['<b>{0}</b>'],
groupCollapse : true,
groupOrder: ['asc','asc','asc'],
groupDataSorted : true,
groupSummaryPos: ['header', 'header', 'header'],
showSummaryOnHide: [true, true, true]
},
footerrow: true,
userDataOnFooter: true 

}

14/07/2014
17:57
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,
In order to do the full description can you please post the data which causes the problem?
Thank you

Regards

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.

14/07/2014
19:11
Avatar
ricardo
Member
Members
Forum Posts: 3
Member Since:
13/07/2014
sp_UserOfflineSmall Offline

Tony-

 

Here is the requestedData:

var ReportLines = [
 {Lob:"VOIP REVENUE",Type:"COMMERCIAL INCOME",AccountNumber:"97000-691-90-2",ServiceCode:"3300::H9",NetRevenue01:"1500000.00"},
 {Lob:"VOIP REVENUE",Type:"COMMERCIAL INCOME",AccountNumber:"97000-691-90-3",ServiceCode:"3300::K9",NetRevenue01:"3000000.00"},
 {Lob:"VOIP REVENUE",Type:"TELEPHONY INCOME",AccountNumber:"97000-691-90-4",ServiceCode:"3300::09",NetRevenue01:"1600000.00"},
 {Lob:"VOIP REVENUE",Type:"TELEPHONY INCOME",AccountNumber:"97000-691-90-5",ServiceCode:"3300::J9",NetRevenue01:"2900000.00"},
 {Lob:"DRONE REVENUE",Type:"TICKLE INCOME",AccountNumber:"97000-691-90-6",ServiceCode:"3300::P9",NetRevenue01:"1600000.00"},
 {Lob:"DRONE REVENUE",Type:"TICKLE INCOME",AccountNumber:"97000-691-90-7",ServiceCode:"3300::C9",NetRevenue01:"2900000.00"},
 ];

 

Please replace result.Reportlines with ReportLines in the data portion of the jqgrid.

16/07/2014
13:58
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Thank you for the test case.
I reproduce the problem. Will try to fix ASAP.

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

24/07/2014
12:54
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

 

I have fixed the problem in GitHub here.

Please let me know if you have difficulties to run and test the fix

 

Kind Regards

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.

31/08/2014
02:30
Avatar
ricardo
Member
Members
Forum Posts: 3
Member Since:
13/07/2014
sp_UserOfflineSmall Offline

tony said
Hello,

 

I have fixed the problem in GitHub here.

Please let me know if you have difficulties to run and test the fix

 

Kind Regards

Tony-

 

       Thanks For the Help. 

 

       I applied the suggested solution but It has NOT solved the problem. ¿Could you please check again?

13/09/2014
12:58
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

 

There was more fixes on this. Please, if possible download all the code and use grid base, common and grouping modules (other modules can be requiered maybe)

If it is difficult for you I will send you the fixed version

 

Thanks

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.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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