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
Footer summary JSON format
14/09/2009
15:40
Avatar
Vinoth
Guest
Guests

Hello,

I am trying to show columnm summary on the footer. I have enabled footerrow : true, userDataOnFooter : true at the grid configuration. I have the summary information from the code base and wondering if anyone can help me on how to pass the summary information to the client as JSON object.

Here is the json format, I use to display the data.

{totalpages: '2', currentpage: '1', pagerecords: '14',itemrows: [
{Id:'941', CheckAmt:'10.00' },
{Id:'951', CheckAmt:'5.00' },
{Id:'952', CheckAmt:'2.60' },
{Id:'957', CheckAmt:'5.00' } ]}

How can I pass the total amount to the client with the json strng. CheckTotalAmt: '22.60'

- thanks

Vinoth

14/09/2009
23:14
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

You should provide the additional information in user data array where the summs are here or use the getCol method to summ the needed row and put the info with footerData method.

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.

21/09/2009
13:55
Avatar
Vinoth
Guest
Guests

Tony,

thanks for your reply. I am using the below script at the grid configuration level and the data from server.

jsonReader:{
root: 'itemrows',
page: 'currentpage',
total: 'totalpages',
records: 'pagerecords',
userdata: 'SummaryData'
},

-------------

{totalpages: '2',
currentpage: '1',
pagerecords: '14',
SummaryData: {CheckAmt: '22.60'}
itemrows: [{Id:'941', CheckAmt:'10.00' },{Id:'951', CheckAmt:'5.00' },{Id:'952', CheckAmt:'2.60' },{Id:'957', CheckAmt:'5.00' } ]}

Please advise.

thanks,

Vinoth

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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