Hi Jason,
Spot on with the scenario.
In my case I'm dealing with a Finance object that can have a m2o
relationship with an instalment. The idea is that the Finance passes to the
instalment its Total and any Cleared Payment. The instalment can then work
out any percentage breakdown.
Everything works fine when they're logged in and go through Finance. My
Finance Decorator is setup to overwrite the default setInstalment when it's
setting is told to pass on its details.
The problem I'm hitting is if the user's objects are saved, they log out and
then back in again. Transfer is told to get the records back and populate
their session. It's doing that but not running the setInstalment for me so
the passing of details doesn't happen.
So I'm currently having to code in that trigger at any point the objects are
retrieved from the DB. Ideally I want this in one place, the Decorator, and
have the Finance self-manage itself.
---
Had a look at Brian's Injector and noticed this in the documentation...
" Your ColdSpring configuration must be set to inject the Transfer object
into the Observer as a constructor argument.
It must also be set to inject the BeanInjector as a property. The
Observer will register itself with Transfer using the
transfer.addAfterNewObserver() method. To ensure that this happens at
application startup, you have two options:"
So it looks like the injection only happens on the creation of new objects.
Like I say that's great in the Finance section but when logging back in I'm
dealing with persisted objects so they don't seem to fall under the category
of "new" in Transfer's eyes.
--
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer
Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8
You received this message because you are subscribed to the Google Groups
"transfer-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/transfer-dev?hl=en