You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Ernest Hocking <er...@computer.org> on 2023/10/13 07:34:33 UTC

Form reuse

Good afternoon everyone,

I tried to use the include form directive in a plugin screen ( calling the
BOM form from the manufacturing application ). However ofbiz complains
about missing decorators.  Is there something else I need to specify in for
example the controller.xml to enable the full context needed to run the
form?.  The sim is to avoid the user having to switch applications (from
the plugin) to access the functionality

If anyone can point me ti an example in the code base that would be a great
help

Thanks and kind regards

Ernest

Re: Form reuse

Posted by Deepak Dixit <de...@apache.org>.
Hello Ernest,

Form does not need the decorators, decorators required by screens.
Please check the web.xml files to define the decorator location.
e.g mainDecoratorLocation

Thanks & Regards
--
Deepak Dixit
ofbiz.apache.org


On Fri, Oct 13, 2023 at 1:04 PM Ernest Hocking <er...@computer.org>
wrote:

> Good afternoon everyone,
>
> I tried to use the include form directive in a plugin screen ( calling the
> BOM form from the manufacturing application ). However ofbiz complains
> about missing decorators.  Is there something else I need to specify in for
> example the controller.xml to enable the full context needed to run the
> form?.  The sim is to avoid the user having to switch applications (from
> the plugin) to access the functionality
>
> If anyone can point me ti an example in the code base that would be a great
> help
>
> Thanks and kind regards
>
> Ernest
>

Re: Form reuse

Posted by Ernest Hocking <er...@computer.org>.
Good evening Nicolas

The intention was to  include the form in a plugin screen:

     <screen>
...
                <widgets>
                    <include-form name="RunBomSimulation"
location="component://manufacturing/widget/manufacturing/BomForms.xml"/>
                </widgets>
      ....
     </screen>

I believe that I might be able to solve this issue:through the use of the
following line to the plugin webapp/..WEB_INF/controller.xml file

    <include
location="component://manufacturing/webapp/manufacturing/WEB-INF/controller.xml"/>

along with the view maps (I have not tested to see if they are a necessary
inclusion)

    <view-map name="BillOfMaterials" type="screen"
page="component://manufacturing/widget/manufacturing/BomScreens.xml#BomSimulation"/>
    <view-map name="FindBom" type="screen"
page="component://manufacturing/widget/manufacturing/BomScreens.xml#FindBom"/>
    <view-map name="BomSimulation" type="screen"
page="component://manufacturing/widget/manufacturing/BomScreens.xml#BomSimulation"/>
   etc


I've not yet fully tested this due to other priorities


kind regards

Ernest




On Tue, Nov 7, 2023 at 4:36 PM Nicolas Malin <ni...@nereide.fr>
wrote:

> Hello Ernest,
>
> Can you share me your code,
>
> This would be help to spot the good solution :)
>
> Nicolas
>
> Le 13/10/2023 à 09:34, Ernest Hocking a écrit :
> > Good afternoon everyone,
> >
> > I tried to use the include form directive in a plugin screen ( calling
> the
> > BOM form from the manufacturing application ). However ofbiz complains
> > about missing decorators.  Is there something else I need to specify in
> for
> > example the controller.xml to enable the full context needed to run the
> > form?.  The sim is to avoid the user having to switch applications (from
> > the plugin) to access the functionality
> >
> > If anyone can point me ti an example in the code base that would be a
> great
> > help
> >
> > Thanks and kind regards
> >
> > Ernest
> >
>

Re: Form reuse

Posted by Nicolas Malin <ni...@nereide.fr>.
Hello Ernest,

Can you share me your code,

This would be help to spot the good solution :)

Nicolas

Le 13/10/2023 à 09:34, Ernest Hocking a écrit :
> Good afternoon everyone,
>
> I tried to use the include form directive in a plugin screen ( calling the
> BOM form from the manufacturing application ). However ofbiz complains
> about missing decorators.  Is there something else I need to specify in for
> example the controller.xml to enable the full context needed to run the
> form?.  The sim is to avoid the user having to switch applications (from
> the plugin) to access the functionality
>
> If anyone can point me ti an example in the code base that would be a great
> help
>
> Thanks and kind regards
>
> Ernest
>