PDA

View Full Version : GRID.js refresh not a function



jdunneirl
24 Feb 2009, 3:58 AM
Hi guys, I am using ext grid.js that ships with coldfusion 8, but i get an error this.refresh is not a function (http://localhost:8301/CFIDE/scripts/ajax/ext/package/grid/grid.js, line 11

any ideas

thanks

John

24 Feb 2009, 4:18 AM
http://extjs.com/learn/Ext_Forum_Help

jdunneirl
24 Feb 2009, 4:24 AM
huh whats that mean?

Animal
24 Feb 2009, 4:25 AM
A little more than your post.

Do we all have crystal balls?

jdunneirl
24 Feb 2009, 4:32 AM
Ok, heres what I got so far,

I have a page with a cfgrid on it, a coldfusion grid, coldfusion calls the ext js grid.js and renders it to the screen, sometimes I get grid.refresh is not a function when the page orginally loads,

My sort is also not working, I am guessing this is related, when I click on the header of the tab to sort it, the arrow changes direction and nothing else, ie desc or asc,.


<cfform width="100%">
<cfgrid name="dgClaimsStatus" format="html" width="100%" stripeRows="true" selectmode="browse" selectonload="false" pageSize="10" bindonload="yes" sort="yes"
bind="cfc:#request.siteContext.dsn#.app_templates.coreobjects.claims.claims.returnall({cfgridpage},{cfgridpagesize},{cfgridsortcolumn},{cfgridsortdirection})">
<cfgridcolumn name="dateReceived" header="Date Received">
<cfgridcolumn href=""name="nameofClaimant" header="Name of Claimant" width="110">
<cfgridcolumn name="type" header="Type" width="88">
<cfgridcolumn href="" name="status" header="Status">
<cfgridcolumn name="grossBenefits" header="Gross Benefits<br>Paid Year to Date" width="125">
<cfgridcolumn name="netBenefits" header="Net Benefits Paid<br>Year to Date" width="125">
<cfgridcolumn name="benefitsApproved" header="Benefits Approved<br>to Date" width="125">
</cfgrid>
</cfform>


This is binded to

<cffunction name="returnall" output="no" access="remote">
<cfargument name="page" required="true">
<cfargument name="pageSize" required="true">
<cfargument name="gridsortcolumn" required="true">
<cfargument name="gridsortdirection" required="true">
<cfset var ps = pageSize>
<cfif q.RecordCount LT ps>
<cfset ps = q.RecordCount>
</cfif>


<cfdump var="#queryconvertforgrid(paymentDetails,page,pgSize)#">

<cfreturn queryconvertforgrid(q,page,ps)/>
</cffunction>



where q is a hard coded query


variables.q = queryNew('dateReceived,nameofClaimant,type,status,grossBenefits,netBenefits,benefitsApproved');
queryAddRow(q,1);
querySetCell(q, 'dateReceived', '01/09/2009');
querySetCell(q, 'nameofClaimant', 2);
querySetCell(q, 'type', 'STD');
querySetCell(q, 'status', 'Approved');
querySetCell(q, 'grossBenefits', '$10,000.00');
querySetCell(q, 'netBenefits', '$10,000.00');
querySetCell(q, 'benefitsApproved', '02/25/2009');
queryAddRow(q,1);
querySetCell(q, 'dateReceived', '12/31/2009');
querySetCell(q, 'nameofClaimant', 1);
querySetCell(q, 'type', 'LTD');
querySetCell(q, 'status', 'Pending');
querySetCell(q, 'grossBenefits', '$5,000.00');
querySetCell(q, 'netBenefits', '$4,500.00');
querySetCell(q, 'benefitsApproved', '01/29/2009');
queryAddRow(q,1);
querySetCell(q, 'dateReceived', '11/25/2009');
querySetCell(q, 'nameofClaimant', 'Bunny,Bugs');
querySetCell(q, 'type', 'LTD');
querySetCell(q, 'status', 'Approved');
querySetCell(q, 'grossBenefits', '$2,000.00');
querySetCell(q, 'netBenefits', '$1,500.00');
querySetCell(q, 'benefitsApproved', '06/13/2009');










thanks John