Adding actions instead of replacing them in extended forms

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Adding actions instead of replacing them in extended forms

Bruno Busco
Hi,
when extending a form is there a way to ADD actions to the ones defined in
the original form?
What I see now is that actions defined in the original form are completely
replaced by the actions defined in the extended form.

Thank you,
-Bruno
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Bruno Busco
In other words,
how can I call actions of the parent form a child one?

Thank you,
Bruno

2008/8/31 Bruno Busco <[hidden email]>

> Hi,
> when extending a form is there a way to ADD actions to the ones defined in
> the original form?
> What I see now is that actions defined in the original form are completely
> replaced by the actions defined in the extended form.
>
> Thank you,
> -Bruno
>
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

BJ Freeman
before the answer need some clarification:
by extended form are you talking about widgets or ftl.
or are you talking about some new functions you are considering.

Bruno Busco sent the following on 8/31/2008 2:15 AM:

> In other words,
> how can I call actions of the parent form a child one?
>
> Thank you,
> Bruno
>
> 2008/8/31 Bruno Busco <[hidden email]>
>
>> Hi,
>> when extending a form is there a way to ADD actions to the ones defined in
>> the original form?
>> What I see now is that actions defined in the original form are completely
>> replaced by the actions defined in the extended form.
>>
>> Thank you,
>> -Bruno
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Jacques Le Roux
Administrator
I think it's about widget, there is no notion of action in FTL. And I have no answers to propose.

Jacques

From: "BJ Freeman" <[hidden email]>

> before the answer need some clarification:
> by extended form are you talking about widgets or ftl.
> or are you talking about some new functions you are considering.
>
> Bruno Busco sent the following on 8/31/2008 2:15 AM:
>> In other words,
>> how can I call actions of the parent form a child one?
>>
>> Thank you,
>> Bruno
>>
>> 2008/8/31 Bruno Busco <[hidden email]>
>>
>>> Hi,
>>> when extending a form is there a way to ADD actions to the ones defined in
>>> the original form?
>>> What I see now is that actions defined in the original form are completely
>>> replaced by the actions defined in the extended form.
>>>
>>> Thank you,
>>> -Bruno
>>>
>>
>
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Bruno Busco
BJ, Jacques,
yes, I was interested to the form widget.
I have a form widget with many actions and then I created a new frame
extending the first. This simply adds one field a drop-down that need an
additional action to be populated.
Could be interesting to call all parent form actions and then perform the
additional one.
-Bruno

2008/8/31 Jacques Le Roux <[hidden email]>

> I think it's about widget, there is no notion of action in FTL. And I have
> no answers to propose.
>
> Jacques
>
> From: "BJ Freeman" <[hidden email]>
>
>  before the answer need some clarification:
>> by extended form are you talking about widgets or ftl.
>> or are you talking about some new functions you are considering.
>>
>> Bruno Busco sent the following on 8/31/2008 2:15 AM:
>>
>>> In other words,
>>> how can I call actions of the parent form a child one?
>>>
>>> Thank you,
>>> Bruno
>>>
>>> 2008/8/31 Bruno Busco <[hidden email]>
>>>
>>>  Hi,
>>>> when extending a form is there a way to ADD actions to the ones defined
>>>> in
>>>> the original form?
>>>> What I see now is that actions defined in the original form are
>>>> completely
>>>> replaced by the actions defined in the extended form.
>>>>
>>>> Thank you,
>>>> -Bruno
>>>>
>>>>
>>>
>>
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

BJ Freeman
I believe this was discussed before, but I can't find the email.

the simplest way I can think of, but have not tested
is you have the drop down but it is conditionally displayed on the data
being there.
the data becomes available after the first step is taken.
The code (groovy) would then have  a if statement the checks for the
first data before retrieving the second.
this would probably need a Java Script that acted on the first being
filled to post to the form again.
I believe there would be multiple request responses to direct to the
next form.

that is the way I would try to accomplish it.
that would be an interesting example.





Bruno Busco sent the following on 8/31/2008 5:21 AM:

> BJ, Jacques,
> yes, I was interested to the form widget.
> I have a form widget with many actions and then I created a new frame
> extending the first. This simply adds one field a drop-down that need an
> additional action to be populated.
> Could be interesting to call all parent form actions and then perform the
> additional one.
> -Bruno
>
> 2008/8/31 Jacques Le Roux <[hidden email]>
>
>> I think it's about widget, there is no notion of action in FTL. And I have
>> no answers to propose.
>>
>> Jacques
>>
>> From: "BJ Freeman" <[hidden email]>
>>
>>  before the answer need some clarification:
>>> by extended form are you talking about widgets or ftl.
>>> or are you talking about some new functions you are considering.
>>>
>>> Bruno Busco sent the following on 8/31/2008 2:15 AM:
>>>
>>>> In other words,
>>>> how can I call actions of the parent form a child one?
>>>>
>>>> Thank you,
>>>> Bruno
>>>>
>>>> 2008/8/31 Bruno Busco <[hidden email]>
>>>>
>>>>  Hi,
>>>>> when extending a form is there a way to ADD actions to the ones defined
>>>>> in
>>>>> the original form?
>>>>> What I see now is that actions defined in the original form are
>>>>> completely
>>>>> replaced by the actions defined in the extended form.
>>>>>
>>>>> Thank you,
>>>>> -Bruno
>>>>>
>>>>>
>

Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

BJ Freeman
In reply to this post by Jacques Le Roux
I was asking on the vague chance that he was referring to the action
folder (groovy).


Jacques Le Roux sent the following on 8/31/2008 4:48 AM:

> I think it's about widget, there is no notion of action in FTL. And I
> have no answers to propose.
>
> Jacques
>
> From: "BJ Freeman" <[hidden email]>
>> before the answer need some clarification:
>> by extended form are you talking about widgets or ftl.
>> or are you talking about some new functions you are considering.
>>
>> Bruno Busco sent the following on 8/31/2008 2:15 AM:
>>> In other words,
>>> how can I call actions of the parent form a child one?
>>>
>>> Thank you,
>>> Bruno
>>>
>>> 2008/8/31 Bruno Busco <[hidden email]>
>>>
>>>> Hi,
>>>> when extending a form is there a way to ADD actions to the ones
>>>> defined in
>>>> the original form?
>>>> What I see now is that actions defined in the original form are
>>>> completely
>>>> replaced by the actions defined in the extended form.
>>>>
>>>> Thank you,
>>>> -Bruno
>>>>
>>>
>>
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Adrian Crum-2
In reply to this post by Bruno Busco
That's interesting - the menu widget extends actions, but the form widget replaces them.

Having the form widget extend actions would be a simple change to make.

Any objections?

-Adrian


--- On Sun, 8/31/08, Bruno Busco <[hidden email]> wrote:

> From: Bruno Busco <[hidden email]>
> Subject: Adding actions instead of replacing them in extended forms
> To: [hidden email]
> Date: Sunday, August 31, 2008, 2:08 AM
> Hi,
> when extending a form is there a way to ADD actions to the
> ones defined in
> the original form?
> What I see now is that actions defined in the original form
> are completely
> replaced by the actions defined in the extended form.
>
> Thank you,
> -Bruno


     
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Bruno Busco
I would suggest to implement something like a tag (i.e.
<call-parent-actions>) that will let to call the parent actions like this:
<form name"formP">
  <actions>
     <action1>
     <action2>
  </actions>
</form>

<form name"formC" extends="formP">
  <actions>
     <actionA>
     <call-parent-actions>
     <actionB>
  </actions>
</form>

In this way the user can have parent form actions executed before or after
the child actions. It will be also possible to have them NOT executed if the
<call-parent-actions> tag is not included.
-Bruno

2008/8/31 Adrian Crum <[hidden email]>

> That's interesting - the menu widget extends actions, but the form widget
> replaces them.
>
> Having the form widget extend actions would be a simple change to make.
>
> Any objections?
>
> -Adrian
>
>
> --- On Sun, 8/31/08, Bruno Busco <[hidden email]> wrote:
>
> > From: Bruno Busco <[hidden email]>
> > Subject: Adding actions instead of replacing them in extended forms
> > To: [hidden email]
> > Date: Sunday, August 31, 2008, 2:08 AM
> > Hi,
> > when extending a form is there a way to ADD actions to the
> > ones defined in
> > the original form?
> > What I see now is that actions defined in the original form
> > are completely
> > replaced by the actions defined in the extended form.
> >
> > Thank you,
> > -Bruno
>
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Adrian Crum-2
In reply to this post by Bruno Busco
I can make the change now to have the form widget simply extend the parent form's actions. (It seems to me this is what was intended, but somehow it got overlooked in the java code.)

If you would like to see additional abilities added to the form widget, then we will have to wait for others to offer their comments.

-Adrian


--- On Sun, 8/31/08, Bruno Busco <[hidden email]> wrote:

> From: Bruno Busco <[hidden email]>
> Subject: Re: Adding actions instead of replacing them in extended forms
> To: [hidden email]
> Date: Sunday, August 31, 2008, 9:43 AM
> Adrian,
> this pattern is not flexible enough why do not try to get
> it more powerfull?
> In the example application you can find:
>
>     <form name="EditExampleExt"
> extends="EditExample"
>
> extends-resource="component://example/widget/example/ExampleForms.xml">
>         <!-- NOTE: add new fields for the EditExample
> form here -->
>         <field
> name="exampleText"><display
> description="This example text
> means we are in the extended form."/></field>
>         <!-- In order for these to be at the bottom of
> the form, we need to
> hide the buttons from the
>             original form, and then create new ones. We
> could use the
> sort-order element, but that
>             doesn't work well when we want to allow
> changes in the original
> form. -->
>         <field name="submitButton"
> use-when="example!=null"><hidden/></field>
>         <field name="submitButton"
> use-when="example==null"><hidden/></field>
>         <field name="submitButtonOvrd"
> title="${uiLabelMap.CommonCreate}"
> use-when="example==null"
> widget-style="smallSubmit"><submit
> button-type="button"/></field>
>         <field name="submitButtonOvrd"
> title="${uiLabelMap.CommonUpdate}"
> use-when="example!=null"
> widget-style="smallSubmit"><submit
> button-type="button"/></field>
>     </form>
>
> From the comment I can see that the extending system need
> to be improved for
> the field adding also.
> -Bruno
>
> 2008/8/31 Adrian Crum <[hidden email]>
>
> > I don't like that idea. The pattern in other
> things like this is something
> > like "I want all of this widget's actions,
> plus I want to add these
> > actions."
> >
> > -Adrian
> >
> > --- On Sun, 8/31/08, Bruno Busco
> <[hidden email]> wrote:
> >
> > > From: Bruno Busco <[hidden email]>
> > > Subject: Re: Adding actions instead of replacing
> them in extended forms
> > > To: [hidden email], [hidden email]
> > > Date: Sunday, August 31, 2008, 9:23 AM
> > > I would suggest to implement something like a tag
> (i.e.
> > > <call-parent-actions>) that will let to
> call the
> > > parent actions like this:
> > > <form name"formP">
> > >   <actions>
> > >      <action1>
> > >      <action2>
> > >   </actions>
> > > </form>
> > >
> > > <form name"formC"
> > > extends="formP">
> > >   <actions>
> > >      <actionA>
> > >      <call-parent-actions>
> > >      <actionB>
> > >   </actions>
> > > </form>
> > >
> > > In this way the user can have parent form actions
> executed
> > > before or after
> > > the child actions. It will be also possible to
> have them
> > > NOT executed if the
> > > <call-parent-actions> tag is not included.
> > > -Bruno
> > >
> > > 2008/8/31 Adrian Crum
> <[hidden email]>
> > >
> > > > That's interesting - the menu widget
> extends
> > > actions, but the form widget
> > > > replaces them.
> > > >
> > > > Having the form widget extend actions would
> be a
> > > simple change to make.
> > > >
> > > > Any objections?
> > > >
> > > > -Adrian
> > > >
> > > >
> > > > --- On Sun, 8/31/08, Bruno Busco
> > > <[hidden email]> wrote:
> > > >
> > > > > From: Bruno Busco
> <[hidden email]>
> > > > > Subject: Adding actions instead of
> replacing them
> > > in extended forms
> > > > > To: [hidden email]
> > > > > Date: Sunday, August 31, 2008, 2:08 AM
> > > > > Hi,
> > > > > when extending a form is there a way to
> ADD
> > > actions to the
> > > > > ones defined in
> > > > > the original form?
> > > > > What I see now is that actions defined
> in the
> > > original form
> > > > > are completely
> > > > > replaced by the actions defined in the
> extended
> > > form.
> > > > >
> > > > > Thank you,
> > > > > -Bruno
> > > >
> > > >
> > > >
> > > >
> >
> >
> >
> >


     
Reply | Threaded
Open this post in threaded view
|

Re: Adding actions instead of replacing them in extended forms

Jacques Le Roux
Administrator
In reply to this post by Adrian Crum-2
From: "Adrian Crum" <[hidden email]>
> That's interesting - the menu widget extends actions, but the form widget replaces them.
>
> Having the form widget extend actions would be a simple change to make.

+1

Jacques
 

> Any objections?
>
> -Adrian
>
>
> --- On Sun, 8/31/08, Bruno Busco <[hidden email]> wrote:
>
>> From: Bruno Busco <[hidden email]>
>> Subject: Adding actions instead of replacing them in extended forms
>> To: [hidden email]
>> Date: Sunday, August 31, 2008, 2:08 AM
>> Hi,
>> when extending a form is there a way to ADD actions to the
>> ones defined in
>> the original form?
>> What I see now is that actions defined in the original form
>> are completely
>> replaced by the actions defined in the extended form.
>>
>> Thank you,
>> -Bruno
>
>
>      
>