Author: ashish
Date: Tue Jul 21 10:41:34 2009
New Revision: 796245
URL:
http://svn.apache.org/viewvc?rev=796245&view=revLog:
Applied patch from jira issue - OFBIZ-2743 (GenericEntityException in createItemIssuanceRole when receiving PO in multiple attempts)
Thanks Mridul for the contribution.
Modified:
ofbiz/trunk/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml
Modified: ofbiz/trunk/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml?rev=796245&r1=796244&r2=796245&view=diff==============================================================================
--- ofbiz/trunk/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml (original)
+++ ofbiz/trunk/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml Tue Jul 21 10:41:34 2009
@@ -362,10 +362,17 @@
</if-empty>
<!-- Add ItemIssuanceRole for party that issues this... -->
- <set from-field="itemIssuanceId" field="itemIssuanceRoleCreate.itemIssuanceId"/>
- <set from-field="userLogin.partyId" field="itemIssuanceRoleCreate.partyId"/>
- <set value="PACKER" field="itemIssuanceRoleCreate.roleTypeId"/>
- <call-service service-name="createItemIssuanceRole" in-map-name="itemIssuanceRoleCreate"/>
+ <entity-one value-field="itemIssuanceRole" entity-name="ItemIssuanceRole">
+ <field-map field-name="itemIssuanceId" from-field="itemIssuanceId"/>
+ <field-map field-name="partyId" from-field="userLogin.partyId"/>
+ <field-map field-name="roleTypeId" value="PACKER"/>
+ </entity-one>
+ <if-empty field="itemIssuanceRole">
+ <set from-field="itemIssuanceId" field="itemIssuanceRoleCreate.itemIssuanceId"/>
+ <set from-field="userLogin.partyId" field="itemIssuanceRoleCreate.partyId"/>
+ <set value="PACKER" field="itemIssuanceRoleCreate.roleTypeId"/>
+ <call-service service-name="createItemIssuanceRole" in-map-name="itemIssuanceRoleCreate"/>
+ </if-empty>
</simple-method>
<simple-method method-name="issueInventoryItemToFixedAssetMaint" short-description="Issue InventoryItem To FixedAssetMaint">