Hey Murali,

If gender is defined in HelloPersonHobby then as stated in my first response, there is no need for <display-entity> so <display> should replace it. Also, the name of the field should be changed to gender instead of guestId.

On 01/25/2014 11:54 AM, Murali Shankar Gopalakrishnan wrote:
Here goes the Form Widget Christian. Have made the couple of elements in
question in Bold.

     <form name="EditPersonHobby" type="single" target="updatePersonhobby"
title="Edit Person Hobby" default-map-name="helloPersonHobby"
default-entity-name="HelloPersonHobby">
           <alt-target use-when="helloPersonHobby==null"
target="createPersonhobby?gender=${gender}"/>
         <!--  <auto-fields-service service-name="updatePersonHobby"/>  -->

         <field use-when="helloPersonHobby!=null" name="guestHobbyId"
title="${uiLabelMap.PersonHobbyId}"
tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field>
         <field use-when="helloPersonHobby==null @and guestHobbyId==null"
name="guestHobbyId" title="${uiLabelMap.PersonId}"><ignored/></field>
         <field use-when="helloPersonHobby==null @and guestHobbyId!=null"
name="guestHobbyId" title="${uiLabelMap.PersonHobbyId}"><display
description="${uiLabelMap.CommonCannotBeFound}: [${guestHobbyId}]"
also-hidden="false"/></field>
         <field use-when="helloPersonHobby==null @and guestId==null"
name="guestId" title="${uiLabelMap.PersonName}">
         <drop-down>
<entity-options entity-name="HelloPerson" description="${firstName}" />
</drop-down>
</field>
* <field use-when="helloPersonHobby!=null @and guestId!=null"
name="guestId" entry-name="gender"><display-entity
entity-name="HelloPerson" description="${gender}"></display-entity></field>*
* <field use-when="helloPersonHobby!=null @and guestId!=null"
name="guestId" entry-name="guestId"><display-entity
entity-name="HelloPerson"
description="${firstName}"></display-entity></field>*

         <field name="hobbyId">
<drop-down>
<entity-options entity-name="HelloHobby" description="${description}" />
</drop-down>
</field>
         <field name="submitButton" use-when="helloPersonHobby==null"
title="${uiLabelMap.CommonCreate}"><submit button-type="button"/></field>
         <field name="submitButton" use-when="helloPersonHobby!=null"
title="${uiLabelMap.CommonUpdate}"><submit button-type="button"/></field>
     </form>


On Sat, Jan 25, 2014 at 10:33 PM, Christian Carlow <
[email protected]> wrote:

Sorry Murali,

I think I'm mistaken.  Please post the entire form widget code.


On 01/25/2014 10:30 AM, Christian Carlow wrote:

Hey Murali,

Seems like this is the problem:

<field  name="guestId"  name="gender"
entry-name="guestId"><display-entity

I think the form widget <display-entity> element is only supposed to be
used for fields that are PKs.  Since gender is not a PK field, an entity
cannot be found.  If gender is defined in the entity that is being used by
the form, then replacing <display-entity> with <display> seems like it
would resolve the problem by correctly displaying the gender of the person.

On 01/25/2014 10:14 AM, Murali Shankar Gopalakrishnan wrote:

<field  name="guestId"  name="gender"
entry-name="guestId"><display-entity



Reply via email to