details:   https://code.openbravo.com/erp/devel/pi/rev/9e0a8ef21cfb
changeset: 30407:9e0a8ef21cfb
user:      Asier Martirena <asier.martirena <at> openbravo.com>
date:      Fri Oct 14 08:38:42 2016 +0200
summary:   Fixed issue 34166: Order lines with netting shipment lines shouldn't 
be returned

diffstat:

 src-db/database/model/tables/M_INOUT.xml                               |   5 +
 src-db/database/sourcedata/AD_COLUMN.xml                               |  41 
+++++++++-
 src-db/database/sourcedata/AD_ELEMENT.xml                              |  14 
+++
 src-db/database/sourcedata/AD_FIELD.xml                                |  29 
+++++++
 src-db/database/sourcedata/AD_TABLE.xml                                |   1 +
 src/org/openbravo/erpCommon/businessUtility/CancelAndReplaceUtils.java |   1 +
 6 files changed, 90 insertions(+), 1 deletions(-)

diffs (165 lines):

diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb src-db/database/model/tables/M_INOUT.xml
--- a/src-db/database/model/tables/M_INOUT.xml  Mon Oct 10 11:45:08 2016 +0200
+++ b/src-db/database/model/tables/M_INOUT.xml  Fri Oct 14 08:38:42 2016 +0200
@@ -257,6 +257,10 @@
         <default/>
         <onCreateDefault/>
       </column>
+      <column name="ISNETTINGSHIPMENT" primaryKey="false" required="false" 
type="CHAR" size="1" autoIncrement="false">
+        <default><![CDATA[N]]></default>
+        <onCreateDefault><![CDATA['N']]></onCreateDefault>
+      </column>
       <foreign-key foreignTable="M_FREIGHTCATEGORY" 
name="M_FREIGHTCATEGORY_M_INOUT">
         <reference local="M_FREIGHTCATEGORY_ID" 
foreign="M_FREIGHTCATEGORY_ID"/>
       </foreign-key>
@@ -355,6 +359,7 @@
       <check name="M_INOUT_GENERATETO_CHECK"><![CDATA[GENERATETO IN ('Y', 
'N')]]></check>
       <check name="M_INOUT_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 
'N')]]></check>
       <check name="M_INOUT_ISLOGISTIC_CHK"><![CDATA[ISLOGISTIC IN ('N', 
'Y')]]></check>
+      <check name="M_INOUT_ISNETTINGSHIPMENT_CHK"><![CDATA[ISNETTINGSHIPMENT 
IN ('Y', 'N')]]></check>
       <check name="M_INOUT_ISPRINTED_CHECK"><![CDATA[ISPRINTED IN ('Y', 
'N')]]></check>
       <check name="M_INOUT_ISSOTRX_CHECK"><![CDATA[ISSOTRX IN ('Y', 
'N')]]></check>
       <check name="M_INOUT_PROCESSED_CHECK"><![CDATA[PROCESSED IN ('Y', 
'N')]]></check>
diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb src-db/database/sourcedata/AD_COLUMN.xml
--- a/src-db/database/sourcedata/AD_COLUMN.xml  Mon Oct 10 11:45:08 2016 +0200
+++ b/src-db/database/sourcedata/AD_COLUMN.xml  Fri Oct 14 08:38:42 2016 +0200
@@ -250050,7 +250050,7 @@
 <!--191328025FA64A5E81837A1501678ADF-->  
<ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--191328025FA64A5E81837A1501678ADF-->  
<DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--191328025FA64A5E81837A1501678ADF-->  
<AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--191328025FA64A5E81837A1501678ADF-->  <POSITION><![CDATA[68]]></POSITION>
+<!--191328025FA64A5E81837A1501678ADF-->  <POSITION><![CDATA[64]]></POSITION>
 <!--191328025FA64A5E81837A1501678ADF-->  
<ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--191328025FA64A5E81837A1501678ADF-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--191328025FA64A5E81837A1501678ADF-->  
<VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -324254,6 +324254,45 @@
 <!--8D6169322485477F8D53E2E246723D3A-->  
<ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
 <!--8D6169322485477F8D53E2E246723D3A--></AD_COLUMN>
 
+<!--8D6DB098961B42BDAC5AD83AFFDD797C--><AD_COLUMN>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_COLUMN_ID><![CDATA[8D6DB098961B42BDAC5AD83AFFDD797C]]></AD_COLUMN_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<NAME><![CDATA[Isnettingshipment]]></NAME>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <DESCRIPTION><![CDATA[Field that says 
if the shipment is a netting shipment]]></DESCRIPTION>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <HELP><![CDATA[Field that says if the 
shipment is a netting shipment]]></HELP>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<COLUMNNAME><![CDATA[Isnettingshipment]]></COLUMNNAME>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_TABLE_ID><![CDATA[319]]></AD_TABLE_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_REFERENCE_ID><![CDATA[20]]></AD_REFERENCE_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<FIELDLENGTH><![CDATA[1]]></FIELDLENGTH>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<DEFAULTVALUE><![CDATA[N]]></DEFAULTVALUE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <ISKEY><![CDATA[N]]></ISKEY>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <ISPARENT><![CDATA[N]]></ISPARENT>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISMANDATORY><![CDATA[N]]></ISMANDATORY>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <SEQNO><![CDATA[480]]></SEQNO>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISSELECTIONCOLUMN><![CDATA[N]]></ISSELECTIONCOLUMN>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_ELEMENT_ID><![CDATA[3809065C3B754137BA7DE6709ECE8A74]]></AD_ELEMENT_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <POSITION><![CDATA[65]]></POSITION>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<IMAGESIZEVALUESACTION><![CDATA[N]]></IMAGESIZEVALUESACTION>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ALLOWSORTING><![CDATA[Y]]></ALLOWSORTING>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ALLOWFILTERING><![CDATA[Y]]></ALLOWFILTERING>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C-->  
<ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
+<!--8D6DB098961B42BDAC5AD83AFFDD797C--></AD_COLUMN>
+
 <!--8D87BBF4A1EBD0C9E040007F01011665--><AD_COLUMN>
 <!--8D87BBF4A1EBD0C9E040007F01011665-->  
<AD_COLUMN_ID><![CDATA[8D87BBF4A1EBD0C9E040007F01011665]]></AD_COLUMN_ID>
 <!--8D87BBF4A1EBD0C9E040007F01011665-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb src-db/database/sourcedata/AD_ELEMENT.xml
--- a/src-db/database/sourcedata/AD_ELEMENT.xml Mon Oct 10 11:45:08 2016 +0200
+++ b/src-db/database/sourcedata/AD_ELEMENT.xml Fri Oct 14 08:38:42 2016 +0200
@@ -22463,6 +22463,20 @@
 <!--361ED16139BD40CBA4DB049380EE1641-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--361ED16139BD40CBA4DB049380EE1641--></AD_ELEMENT>
 
+<!--3809065C3B754137BA7DE6709ECE8A74--><AD_ELEMENT>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  
<AD_ELEMENT_ID><![CDATA[3809065C3B754137BA7DE6709ECE8A74]]></AD_ELEMENT_ID>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  
<COLUMNNAME><![CDATA[Isnettingshipment]]></COLUMNNAME>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <NAME><![CDATA[Is netting 
shipment]]></NAME>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <PRINTNAME><![CDATA[Is netting 
shipment]]></PRINTNAME>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <DESCRIPTION><![CDATA[Field that says 
if the shipment is a netting shipment]]></DESCRIPTION>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <HELP><![CDATA[Field that says if the 
shipment is a netting shipment]]></HELP>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  
<AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--3809065C3B754137BA7DE6709ECE8A74-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--3809065C3B754137BA7DE6709ECE8A74--></AD_ELEMENT>
+
 <!--38148AAF2D384F08B493B5484EFFA6E3--><AD_ELEMENT>
 <!--38148AAF2D384F08B493B5484EFFA6E3-->  
<AD_ELEMENT_ID><![CDATA[38148AAF2D384F08B493B5484EFFA6E3]]></AD_ELEMENT_ID>
 <!--38148AAF2D384F08B493B5484EFFA6E3-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb src-db/database/sourcedata/AD_FIELD.xml
--- a/src-db/database/sourcedata/AD_FIELD.xml   Mon Oct 10 11:45:08 2016 +0200
+++ b/src-db/database/sourcedata/AD_FIELD.xml   Fri Oct 14 08:38:42 2016 +0200
@@ -188995,6 +188995,35 @@
 <!--1B5F586245684A51AA12C9A7A2A3BD9B-->  
<EM_OBUIAPP_SHOWSUMMARY><![CDATA[N]]></EM_OBUIAPP_SHOWSUMMARY>
 <!--1B5F586245684A51AA12C9A7A2A3BD9B--></AD_FIELD>
 
+<!--1B7051BA2DCD439D99C45352F8A0B5CB--><AD_FIELD>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<AD_FIELD_ID><![CDATA[1B7051BA2DCD439D99C45352F8A0B5CB]]></AD_FIELD_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <NAME><![CDATA[Is netting 
shipment]]></NAME>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <DESCRIPTION><![CDATA[Field that says 
if the shipment is a netting shipment]]></DESCRIPTION>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <HELP><![CDATA[Field that says if the 
shipment is a netting shipment]]></HELP>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <AD_TAB_ID><![CDATA[257]]></AD_TAB_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<AD_COLUMN_ID><![CDATA[8D6DB098961B42BDAC5AD83AFFDD797C]]></AD_COLUMN_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<AD_FIELDGROUP_ID><![CDATA[402880E72F1C15A5012F1C7AA98B00E8]]></AD_FIELDGROUP_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<DISPLAYLENGTH><![CDATA[1]]></DISPLAYLENGTH>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <SEQNO><![CDATA[2050]]></SEQNO>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<SHOWINRELATION><![CDATA[N]]></SHOWINRELATION>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISFIRSTFOCUSEDFIELD><![CDATA[N]]></ISFIRSTFOCUSEDFIELD>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<STARTINODDCOLUMN><![CDATA[N]]></STARTINODDCOLUMN>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<STARTNEWLINE><![CDATA[N]]></STARTNEWLINE>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<ISSHOWNINSTATUSBAR><![CDATA[N]]></ISSHOWNINSTATUSBAR>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB-->  
<EM_OBUIAPP_SHOWSUMMARY><![CDATA[N]]></EM_OBUIAPP_SHOWSUMMARY>
+<!--1B7051BA2DCD439D99C45352F8A0B5CB--></AD_FIELD>
+
 <!--1B722399437345D292340D9949886D7D--><AD_FIELD>
 <!--1B722399437345D292340D9949886D7D-->  
<AD_FIELD_ID><![CDATA[1B722399437345D292340D9949886D7D]]></AD_FIELD_ID>
 <!--1B722399437345D292340D9949886D7D-->  
<AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb src-db/database/sourcedata/AD_TABLE.xml
--- a/src-db/database/sourcedata/AD_TABLE.xml   Mon Oct 10 11:45:08 2016 +0200
+++ b/src-db/database/sourcedata/AD_TABLE.xml   Fri Oct 14 08:38:42 2016 +0200
@@ -12119,6 +12119,7 @@
 and dt.return = false
 and io.processed = true and io.documentStatus <> 'VO' 
 and io.salesTransaction = @isSalesTransaction@ 
+and io.isnettingshipment = false
 and (iol.movementQuantity+(@returnedOthersLeftClause@) <> 0) 
 and @insertion_point_0@
 and @additional_filters@]]></HQLQUERY>
diff -r 2d6dd13cc6dd -r 9e0a8ef21cfb 
src/org/openbravo/erpCommon/businessUtility/CancelAndReplaceUtils.java
--- a/src/org/openbravo/erpCommon/businessUtility/CancelAndReplaceUtils.java    
Mon Oct 10 11:45:08 2016 +0200
+++ b/src/org/openbravo/erpCommon/businessUtility/CancelAndReplaceUtils.java    
Fri Oct 14 08:38:42 2016 +0200
@@ -283,6 +283,7 @@
           // Create Netting goods shipment Header
           if (nettingGoodsShipment == null) {
             nettingGoodsShipment = createNettingGoodShipmentHeader(oldOrder);
+            nettingGoodsShipment.setNettingshipment(true);
             nettingGoodsShipmentId = nettingGoodsShipment.getId();
           }
 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Openbravo-commits mailing list
Openbravo-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to