Author: hansbak
Date: Wed Dec 1 03:37:46 2010
New Revision: 1040867
URL:
http://svn.apache.org/viewvc?rev=1040867&view=revLog:
add an default purpose parameter to the getPartyEmail service to allow the selection of a specific purpose email
Modified:
ofbiz/trunk/applications/party/script/org/ofbiz/party/party/PartyServices.xml
ofbiz/trunk/applications/party/servicedef/services.xml
Modified: ofbiz/trunk/applications/party/script/org/ofbiz/party/party/PartyServices.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/script/org/ofbiz/party/party/PartyServices.xml?rev=1040867&r1=1040866&r2=1040867&view=diff==============================================================================
--- ofbiz/trunk/applications/party/script/org/ofbiz/party/party/PartyServices.xml (original)
+++ ofbiz/trunk/applications/party/script/org/ofbiz/party/party/PartyServices.xml Wed Dec 1 03:37:46 2010
@@ -680,7 +680,7 @@ under the License.
<!-- first try to find primary email Address when not found get other email -->
<entity-and entity-name="PartyContactWithPurpose" list="emailAddressesPurposes">
<field-map field-name="partyId" from-field="parameters.partyId"/>
- <field-map field-name="contactMechPurposeTypeId" value="PRIMARY_EMAIL"/>
+ <field-map field-name="contactMechPurposeTypeId" from-field="parameters.contactMechPurposeTypeId"/>
</entity-and>
<filter-list-by-date list="emailAddressesPurposes" to-list="emailAddressesPurposes1" from-field-name="purposeFromDate" thru-field-name="purposeThruDate"/>
<filter-list-by-date list="emailAddressesPurposes1" to-list="emailAddresses" from-field-name="contactFromDate" thru-field-name="contactThruDate"/>
Modified: ofbiz/trunk/applications/party/servicedef/services.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/servicedef/services.xml?rev=1040867&r1=1040866&r2=1040867&view=diff==============================================================================
--- ofbiz/trunk/applications/party/servicedef/services.xml (original)
+++ ofbiz/trunk/applications/party/servicedef/services.xml Wed Dec 1 03:37:46 2010
@@ -1003,6 +1003,7 @@ under the License.
location="component://party/script/org/ofbiz/party/party/PartyServices.xml" invoke="getPartyEmail" auth="false">
<description>Get the main party Email address</description>
<attribute name="partyId" type="String" mode="IN" optional="false"/>
+ <attribute name="contactMechPurposeTypeId" type="String" mode="IN" optional="false" default-value="PRIMARY_EMAIL"/>
<attribute name="emailAddress" type="String" mode="OUT" optional="true"/>
<attribute name="contactMechId" type="String" mode="OUT" optional="true"/>
</service>