From 70cc71aebfcf17e4dc1dd353580984e5d954dcc3 Mon Sep 17 00:00:00 2001 From: Ashish Vijaywargiya Date: Mon, 25 Apr 2011 09:29:04 +0000 Subject: [PATCH] Applied patch from jira issue OFBIZ-4263. When we link party from https://localhost:8443/partymgr/control/linkparty?partyId=10000 screen. It is showing error on console. For console error please refer jira issue. Thanks Amit for the contribution. git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1096441 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/ofbiz/party/party/PartyServices.java | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/applications/party/src/org/ofbiz/party/party/PartyServices.java b/applications/party/src/org/ofbiz/party/party/PartyServices.java index acde9f9cfd..4fd8c50e5a 100644 --- a/applications/party/src/org/ofbiz/party/party/PartyServices.java +++ b/applications/party/src/org/ofbiz/party/party/PartyServices.java @@ -1652,7 +1652,23 @@ public class PartyServices { return ServiceUtil.returnError(e.getMessage()); } - // TODO: there are a number of other places which may need to be updated + // update the Product Store Role records + try { + delegator.storeByCondition("ProductStoreRole", UtilMisc.toMap("partyId", partyIdTo, "thruDate", now), + EntityCondition.makeCondition("partyId", EntityOperator.EQUALS, partyId)); + } catch (GenericEntityException e) { + Debug.logError(e, module); + return ServiceUtil.returnError(e.getMessage()); + } + + // update the Communication Event Role records + try { + delegator.storeByCondition("CommunicationEventRole", UtilMisc.toMap("partyId", partyIdTo), + EntityCondition.makeCondition("partyId", EntityOperator.EQUALS, partyId)); + } catch (GenericEntityException e) { + Debug.logError(e, module); + return ServiceUtil.returnError(e.getMessage()); + } // remove all previous party roles try {