then you might use the compare between the findparty and yours to see
what might be different.
I am willing, on the mailing list to
1) investigate what is in the svn.
2) give pointers to someone doing custom code.
what I am not willing to do
is trouble shoot someones code, unless I am hired.
So I have been doing #2.

you don't have a grasp yet. believe I know how frustrating that is.
here are the three rules I learn by
1) read everything till I understand ever word. this says you have 50%
of a discipline down.
2) when you think you know enought change something and predict the outcome.
3) if the outcome is not what you predicted go to #1, you missed something.

maybe someone else is willing to support you custom code.
I feel I have given you a way to accomplish trouble shooting this and
other problems you may have.

it is better to teach someone how to fish that to supply the fish for them.




Milind W sent the following on 8/17/2008 7:15 PM:
> Can't copy all the code in my app due to all the dependencies.
> But I think I have pretty much all the fields
>                 <set field="headerItem" value="Main"/>
>                               <set field="roleTypeId" value="CONTACT"/>
>                 <set field="partyTypeId" value="PERSON"/>
>                 <set field="headerItem" value="Contacts"/>
>                               <set field="partyId" 
> value="${userLogin.partyId}"/>
>                               <set field="lookupFlag" value="Y"/>
>                               <set field="extInfo" value="N"/>
>                               <set field="roleTypeId" value="ANY"/>
>                               <set field="noConditionFind" value="Y"/>
>                               <set field="titleProperty" 
> value="PageTitleFindParty" />
>                               <set field="headerItem" value="find" />
>                               <set field="tabButtonItem" value="findparty" />
> BJ you and Jacques seem to answer most questions :)
> Would be nice to add to the list and not subtract :)
> 
>> one last note:
>> findparty works so you have what it takes.
>> so you copy it over and add you code, step by step
>> when it stops working you know where to look in your code.
>>
>> Milind W sent the following on 8/17/2008 4:16 PM:
>>> Exactly what I am doing (using the debugger).
>>> But it would be nice if the "real findParty author could please stand
>>> up"
>>> :)
>>>
>>>> might want to go over the partyscreens.xml#findparty
>>>>
>>>>
>>>> Milind W sent the following on 8/17/2008 2:32 PM:
>>>>> hi,
>>>>> I think someone who understands the findParty method is probably the
>>>>> best
>>>>> person to answer this.
>>>>> I have a screen and form as detailed below.
>>>>> I am trying to get the data from the person entity for the logged in
>>>>> user
>>>>> and display it in a form.
>>>>> Am I missing some parameters? or something else?
>>>>> I am trying to debug this looking at the existing screens and forms
>>>>> but
>>>>> if
>>>>> someone who understands this method can help, I would appreciate it.
>>>>> Thanks
>>>>> -Milind
>>>>>
>>>>>
>>>>> The error:
>>>>>
>>>>> org.ofbiz.base.util.GeneralException: Error rendering screen
>>>>> [component://ebp/widget/EBPScreens.xml#main]:
>>>>> org.ofbiz.base.util.GeneralException: Error rendering screen
>>>>> [component://ebp/widget/EBPScreens.xml#main-decorator]:
>>>>> java.lang.IllegalArgumentException: Error getting value from the
>>>>> database
>>>>> for display of field [firstName] on form [profile]:
>>>>> org.ofbiz.entity.GenericModelException:
>>>>> [GenericDelegator.findByPrimaryKey] Passed primary key is not a valid
>>>>> primary key: [GenericEntity:Person][firstName,THE(java.lang.String)]
>>>>> (Error getting value from the database for display of field
>>>>> [firstName]
>>>>> on
>>>>> form [profile]: org.ofbiz.entity.GenericModelException:
>>>>> [GenericDelegator.findByPrimaryKey] Passed primary key is not a valid
>>>>> primary key: [GenericEntity:Person][firstName,THE(java.lang.String)])
>>>>> (Error rendering screen
>>>>> [component://ebp/widget/EBPScreens.xml#main-decorator]:
>>>>> java.lang.IllegalArgumentException: Error getting value from the
>>>>> database
>>>>> for display of field [firstName] on form [profile]:
>>>>> org.ofbiz.entity.GenericModelException:
>>>>> [GenericDelegator.findByPrimaryKey] Passed primary key is not a valid
>>>>> primary key: [GenericEntity:Person][firstName,THE(java.lang.String)]
>>>>> (Error getting value from the database for display of field
>>>>> [firstName]
>>>>> on
>>>>> form [profile]: org.ofbiz.entity.GenericModelException:
>>>>> [GenericDelegator.findByPrimaryKey] Passed primary key is not a valid
>>>>> primary key: [GenericEntity:Person][firstName,THE(java.lang.String)]))
>>>>>
>>>>>
>>>>> The Screen:
>>>>>     <screen name="main">
>>>>>         <section>
>>>>>             <actions>
>>>>>                 <set field="headerItem" value="Main"/>
>>>>>                           <set field="roleTypeId" value="CONTACT"/>
>>>>>                 <set field="partyTypeId" value="PERSON"/>
>>>>>                 <set field="headerItem" value="Contacts"/>
>>>>>                           <set field="partyId" 
>>>>> value="${userLogin.partyId}"/>
>>>>>                           <set field="lookupFlag" value="Y"/>
>>>>>                           <set field="extInfo" value="N"/>
>>>>>                           <set field="roleTypeId" value="ANY"/>
>>>>>                           <entity-one entity-name="Person" 
>>>>> value-name="Person" />
>>>>>             </actions>
>>>>>             <widgets>
>>>>>                 <decorator-screen name="main-decorator"
>>>>> location="component://ebp/widget/EBPScreens.xml">
>>>>>                                      <decorator-section name="body">
>>>>>                         <section>
>>>>>
>>>>>                             <actions>
>>>>>                                 <service service-name="findParty"
>>>>> auto-field-map="true"/>
>>>>>                             </actions>
>>>>>                             <widgets>
>>>>>                                 <container style="screenlet">
>>>>>                                     <container style="screenlet-body">
>>>>>                                         <section>
>>>>>                                             <condition>
>>>>>                                                 <not><if-empty
>>>>> field-name="partyList"/></not>
>>>>>                                             </condition>
>>>>>                                             <widgets>
>>>>>                                                 <include-form
>>>>> name="profile"
>>>>> location="component://ebp/widget/EBPForms.xml"/>
>>>>>                                             </widgets>
>>>>>                                             <fail-widgets>
>>>>>                                                 <container style="h3">
>>>>>                                                     <label
>>>>> text="PARTY_NOT_FOUND"/>
>>>>>                                                 </container>
>>>>>                                             </fail-widgets>
>>>>>                                         </section>
>>>>>                                     </container>
>>>>>                                 </container>
>>>>>                             </widgets>
>>>>>                         </section>
>>>>>                     </decorator-section>
>>>>>                 </decorator-screen>
>>>>>             </widgets>
>>>>>         </section>
>>>>>     </screen>
>>>>>
>>>>> The FORM:
>>>>>     <form name="profile" type="list" target="Person"
>>>>> default-entity-name="Person"   >
>>>>>           <actions>
>>>>>             <entity-condition entity-name="Person">
>>>>>                 <condition-expr field-name="partyId"
>>>>> value="${userLogin.partyId}"/>
>>>>>                 <order-by field-name="partyId"/>
>>>>>             </entity-condition>
>>>>>                   <entity-one entity-name="PartyType" 
>>>>> value-name="partyType">
>>>>>                 <field-map field-name="partyTypeId"
>>>>> env-name="partyRow.partyTypeId"/>
>>>>>             </entity-one>
>>>>>         </actions>
>>>>>           <field name="partyId" title="PartyId" ><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="firstName"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="middleName"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="lastName"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="personalTitle"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="gender"><display-entity 
>>>>> entity-name="Person"/></field>
>>>>>           <field name="birthDate"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="occupation"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="lastModifiedDate"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>           <field name="lastModifiedByUserLogin"><display-entity
>>>>> entity-name="Person"/></field>
>>>>>   </form>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>
>>>
>>>
>>>
>>
> 
> 
> 
> 
> 

Reply via email to