Re: Creating and Editing EO's
Re: Creating and Editing EO's
- Subject: Re: Creating and Editing EO's
- From: "Cuauhtemoc Hohman" <email@hidden>
- Date: Wed, 23 Apr 2008 12:05:36 -0500
Hi Guido,
Use the pageConfiguration:
pageConfiguration = "CreateMyObject" vs pageConfiguration = "EditMyObject"
I haven't used pageConfigurations before, but reading about it I see a problem with them for the issue I want them, because for it to work correctly I have to specify in the rules a few things.
"As a minimum, you need to provide rules for task and entity so the D2W Factory can determine what kind of page it is creating"
(pageConfiguration = 'CreateCustomer') => task = "edit"
(pageConfiguration = 'CreateCustomer') => entity = "Customer"
Does that mean that I would need to create a pair of configurations (EditXxx and CreateXxx) for each entity I have??
I suppose I would also need to change (in templates and pages code) all
D2W.factory().
editPageForNewObjectWithEntityNamed(entityName(), session());
with
D2W.factory().
pageForConfigurationNamed("Create"+entityName(), session());
I suppose it's possible, but it's a bit troublesome, or maybe I'm not getting the idea still.
Thanks for your support.
--
Cuauhtemoc Hohman
On Mon, Apr 21, 2008 at 6:27 PM, Guido Neitzer <
email@hidden> wrote:
On 21.04.2008, at 17:11, Cuauhtemoc Hohman wrote:
However, I don't really get how does this help my EditPage Template to distinguish between edit and create modes.
In my testing, both continue using task "edit", so how do I differentiate them in the Rule System?
Use the pageConfiguration:
pageConfiguration = "CreateMyObject" vs pageConfiguration = "EditMyObject"
_______________________________________________
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