On 21-Feb-09, at 10:32 AM, Henrique Gomes wrote:


On Feb 20, 2009, at 11:13 AM, David LeBer wrote:

I wrote a blog post with an intro to working with multiple ECs: < http://davidleber.net/?p=322 >

Two basic rules:
        1. You cannot relate EOs in different ECs
        2. You cannot move uncommitted EOs between ECs


Thank you for such a clear text.

I'm in the process to change my code to avoid the default EC.
(In my defense the previous projects were mostly read only, very few writes) Any way, I now face this question: Let's say I have EO's that, for example, relate to a country EO. In my app I had the country list preloaded on the session and used it as a WOPopUp list binding with the select key bound to my EO.country. So to use a peer EC on the edit page, do I have to re-fetch the country list on the new EC? Is there a better way?

1 Cat. 1 Million ways to skin it. (No cats where harmed during the creation of the analogy).

Can I leave the "selected" key bound to a var and localInstace() on the setter?

You could do it that way.

You could write cover methods in your EO - localCountry/ setLocalCountry that do the localInstance thing that you could bind directly to.

You could copy all of the countries into the local EC on the edit page using EOUtilities localInstancesOfObjects or similar.

;david

--
David LeBer
Codeferous Software
'co-def-er-ous' adj. Literally 'code-bearing'
site:   http://codeferous.com
blog:   http://davidleber.net
profile:        http://www.linkedin.com/in/davidleber
twitter:        http://twitter.com/rebeld
--
Toronto Area Cocoa / WebObjects developers group:
http://tacow.org




_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to