Multiple Calls to Bound Action in Request-Response
Multiple Calls to Bound Action in Request-Response
- Subject: Multiple Calls to Bound Action in Request-Response
- From: Carter Wojcik <email@hidden>
- Date: Tue, 19 Dec 2006 08:43:32 -0800 (PST)
Hi All -
I have a page containing a custom component
(TabComponent). The TabComponent contains an
ObjectComponent. The ObjectComponent contains a
ButtonComponent. The TabComponent is wrapped in a
conditional.
When the user wants to add a record they push a
button, which flags the conditional as true and
displays the TabComponent. The user selects the
objects to add from a list and then presses an 'Add'
button which calls a method (addAction) located on the
page. Inside the addAction, the conditional is set to
false, to hide the TabComponent once objects are
added.
Initially I was having issues with synchronizing the
conditional on the page, but following advice from
Chuck's book and overriding appendToResponse with an
additional boolean has solved that problem.
Now the problem seems to be that my addAction is being
called multiple times in the Request-Response loop.
This causes the conditional to be set to false and the
TabComponent is hidden. I would only like the
TabComponent to be hidden under certain circumstances,
such as 'Cancel' button pressed or 'Add' button
pressed.
Is there an alternate way to limit when the addAction
is called? Or a different place to put my logic so
that the addAction is not always called?
Thanks for the help.
Carter
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden