svn commit: r562645 - /ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r562645 - /ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java

jonesde
Author: jonesde
Date: Fri Aug  3 20:00:03 2007
New Revision: 562645

URL: http://svn.apache.org/viewvc?view=rev&rev=562645
Log:
Fairly small change so that shipmentId is saved with the OagisMessageInfo, so we know which we're dealing with!

Modified:
    ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java

Modified: ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java?view=diff&rev=562645&r1=562644&r2=562645
==============================================================================
--- ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java (original)
+++ ofbiz/trunk/specialpurpose/oagis/src/org/ofbiz/oagis/OagisShipmentServices.java Fri Aug  3 20:00:03 2007
@@ -86,9 +86,7 @@
         Document doc = (Document) context.get("document");
         LocalDispatcher dispatcher = ctx.getDispatcher();
         GenericDelegator delegator = ctx.getDelegator();
-        
         Timestamp nowTimestamp = UtilDateTime.nowTimestamp();
-        
         List errorMapList = FastList.newInstance();
             
         GenericValue userLogin =null;
@@ -117,6 +115,11 @@
         String confirmation = UtilXml.childElementValue(senderElement, "of:CONFIRMATION"); // of
         String authId = UtilXml.childElementValue(senderElement, "of:AUTHID"); // of
 
+        Element dataAreaElement = UtilXml.firstChildElement(showShipmentElement, "ns:DATAAREA"); // n
+        Element daShowShipmentElement = UtilXml.firstChildElement(dataAreaElement, "ns:SHOW_SHIPMENT"); // n
+        Element shipmentElement = UtilXml.firstChildElement(daShowShipmentElement, "ns:SHIPMENT"); // n                              
+        String shipmentId = UtilXml.childElementValue(shipmentElement, "of:DOCUMENTID"); // of          
+
         Map result = FastMap.newInstance();
         result.put("logicalId", logicalId);
         result.put("component", component);
@@ -132,6 +135,7 @@
         oagisMsgInfoCtx.put("authId", authId);
         oagisMsgInfoCtx.put("outgoingMessage", "N");
         oagisMsgInfoCtx.put("receivedDate", nowTimestamp);
+        oagisMsgInfoCtx.put("shipmentId", shipmentId);
         oagisMsgInfoCtx.put("userLogin", userLogin);
         oagisMsgInfoCtx.put("processingStatusId", "OAGMP_RECEIVED");
         if (OagisServices.debugSaveXmlIn) {
@@ -159,10 +163,6 @@
             Debug.logError(e, errMsg, module);
         }
           
-        Element dataAreaElement = UtilXml.firstChildElement(showShipmentElement, "ns:DATAAREA"); // n
-        Element daShowShipmentElement = UtilXml.firstChildElement(dataAreaElement, "ns:SHOW_SHIPMENT"); // n
-        Element shipmentElement = UtilXml.firstChildElement(daShowShipmentElement, "ns:SHIPMENT"); // n                              
-        String shipmentId = UtilXml.childElementValue(shipmentElement, "of:DOCUMENTID"); // of          
         GenericValue shipment = null;
         try {
             shipment = delegator.findByPrimaryKey("Shipment", UtilMisc.toMap("shipmentId", shipmentId));