Question about event chaining

0 views
Skip to first unread message

Jordan Gouger

unread,
Nov 18, 2009, 2:12:42 PM11/18/09
to mach-ii-for...@googlegroups.com

What would be the best way to go about creating a “processing” page with Mach II (besides going with jQuery)?

 

I have a couple of long running stored procedures and want to display a “processing” page to the user while the procedures are running in the background.

 

Basically, I’m firing a method in a listener that calls two procedures:

 

<cfscript>

                Arguments.event.setArg(‘processingMsg’, ‘Some text here’);

 

                announceEvent(‘billing.processAssmt’, arguments.event.getArgs());

 

                billObj.proc1(Some Args);

 

                billObj.proc2(Some more Args);

 

                redirectEvent(‘billing.budgetSummary’);

 

</cfscript>

 

Billing.processAssmt is a private event that calls the processing page and the layout sub-routine. When I change billing.processAssmt to public and load it directly it displays correctly, but when it is run through the listener it doesn’t display at all. However the procedure calls do run but the redirectEvent doesn’t seem to fire and I end up with a blank page.

 

Thanks,

 

Jordan

 

Bjarte Bore

unread,
Nov 18, 2009, 2:28:06 PM11/18/09
to mach-ii-for...@googlegroups.com
You could use the threading utilities in mach II, add an identfier to
the session scope ( that you will remove when the procedure finish)
and redirect to a loading page. Then let the loading page redirect
with javascript (window.location) to a result page that has a while
loop running until the idenitifier is removed.

It would be cleaner to do this check with an ajax request, but since
you said no jquery I guess that means no ajax at all.

-Bjarte



2009/11/18 Jordan Gouger <jgo...@yahoo.com>:
> --
> You received this message because you are subscribed to Mach-II for CFML
> list.
> To post to this group, send email to mach-ii-for...@googlegroups.com
> To unsubscribe from this group, send email to
> mach-ii-for-coldf...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/mach-ii-for-coldfusion?hl=en
> SVN: http://greatbiztoolsllc.svn.cvsdude.com/mach-ii/
> Wiki / Documentation / Tickets:
> http://greatbiztoolsllc.trac.cvsdude.com/mach-ii/
Reply all
Reply to author
Forward
0 new messages