details: https://code.openbravo.com/erp/devel/pi/rev/b0701ee55593
changeset: 17583:b0701ee55593
user: Javier Etxarri <javier.echarri <at> openbravo.com>
date: Wed Aug 01 10:54:53 2012 +0200
summary: Fixes issue 21264: Module script DeleteInventoryLines is incomplete
and the processes related
diffstat:
src-db/database/model/functions/M_INVENTORY_LISTCREATE.xml
| 9 +++++++++
src-db/database/model/functions/M_UPDATE_INVENTORY.xml
| 3 ++-
src-db/database/model/functions/M_UPDATE_STOCKAUX.xml
| 3 ++-
src-util/modulescript/build/classes/org/openbravo/modulescript/DeleteInventoryLinesData.class
| 0
src-util/modulescript/src/org/openbravo/modulescript/DeleteInventoryLines_data.xsql
| 3 ++-
5 files changed, 15 insertions(+), 3 deletions(-)
diffs (60 lines):
diff -r e9c55a0f8bad -r b0701ee55593
src-db/database/model/functions/M_INVENTORY_LISTCREATE.xml
--- a/src-db/database/model/functions/M_INVENTORY_LISTCREATE.xml Tue Jul
31 13:32:18 2012 +0200
+++ b/src-db/database/model/functions/M_INVENTORY_LISTCREATE.xml Wed Aug
01 10:54:53 2012 +0200
@@ -233,6 +233,15 @@
AND l.M_Product_ID=s.M_Product_ID
AND l.M_Locator_ID=s.M_Locator_ID
)
+ AND NOT EXISTS (SELECT 1
+ FROM M_STORAGE_DETAIL MS
+ WHERE m_product_id IN (SELECT po.m_product_id
+ FROM m_product po JOIN m_attributeset
aset ON po.m_attributeset_id = aset.m_attributeset_id
+ WHERE coalesce(po.attrsetvaluetype, '-')
<> 'F'
+ AND aset.isoneattrsetvalrequired = 'Y'
+ AND po.M_PRODUCT_ID = p.m_product_id)
+ AND COALESCE(m_attributesetinstance_id, '0') = '0'
+ )
ORDER BY s.M_Locator_ID,
p.Value,
s.Created
diff -r e9c55a0f8bad -r b0701ee55593
src-db/database/model/functions/M_UPDATE_INVENTORY.xml
--- a/src-db/database/model/functions/M_UPDATE_INVENTORY.xml Tue Jul 31
13:32:18 2012 +0200
+++ b/src-db/database/model/functions/M_UPDATE_INVENTORY.xml Wed Aug 01
10:54:53 2012 +0200
@@ -134,7 +134,8 @@
AND PREQTYONHAND=0
AND (PREQTYORDERONHAND=0 OR PREQTYORDERONHAND IS NULL)
AND P.M_PRODUCT_ID=p_product
- AND NOT EXISTS (SELECT 1 FROM m_stock_aux WHERE M_STORAGE_DETAIL_ID =
SD.M_STORAGE_DETAIL_ID);
+ AND NOT EXISTS (SELECT 1 FROM m_stock_aux WHERE M_STORAGE_DETAIL_ID =
SD.M_STORAGE_DETAIL_ID)
+ AND NOT EXISTS (SELECT 1 FROM m_stock_proposed WHERE M_STORAGE_DETAIL_ID =
SD.M_STORAGE_DETAIL_ID);
IF (v_Storage_ID IS NOT NULL) THEN
DELETE FROM M_STORAGE_DETAIL WHERE M_STORAGE_DETAIL_ID =v_Storage_ID;
diff -r e9c55a0f8bad -r b0701ee55593
src-db/database/model/functions/M_UPDATE_STOCKAUX.xml
--- a/src-db/database/model/functions/M_UPDATE_STOCKAUX.xml Tue Jul 31
13:32:18 2012 +0200
+++ b/src-db/database/model/functions/M_UPDATE_STOCKAUX.xml Wed Aug 01
10:54:53 2012 +0200
@@ -126,7 +126,8 @@
AND COALESCE(QTYORDERONHAND, 0) = 0
AND PREQTYONHAND=0
AND COALESCE(PREQTYORDERONHAND, 0) = 0
- AND SD.M_STORAGE_DETAIL_ID = v_StorageDetail_ID;
+ AND SD.M_STORAGE_DETAIL_ID = v_StorageDetail_ID
+ AND NOT EXISTS (SELECT 1 FROM m_stock_proposed WHERE
M_STORAGE_DETAIL_ID = SD.M_STORAGE_DETAIL_ID);
IF (v_count > 0) THEN
DELETE FROM M_STORAGE_DETAIL WHERE M_STORAGE_DETAIL_ID =
v_StorageDetail_ID;
diff -r e9c55a0f8bad -r b0701ee55593
src-util/modulescript/build/classes/org/openbravo/modulescript/DeleteInventoryLinesData.class
Binary file
src-util/modulescript/build/classes/org/openbravo/modulescript/DeleteInventoryLinesData.class
has changed
diff -r e9c55a0f8bad -r b0701ee55593
src-util/modulescript/src/org/openbravo/modulescript/DeleteInventoryLines_data.xsql
---
a/src-util/modulescript/src/org/openbravo/modulescript/DeleteInventoryLines_data.xsql
Tue Jul 31 13:32:18 2012 +0200
+++
b/src-util/modulescript/src/org/openbravo/modulescript/DeleteInventoryLines_data.xsql
Wed Aug 01 10:54:53 2012 +0200
@@ -42,7 +42,8 @@
AND PREQTYONHAND = 0
AND (QTYORDERONHAND=0 OR QTYORDERONHAND IS NULL)
AND (PREQTYORDERONHAND=0 OR PREQTYORDERONHAND IS NULL)
- AND NOT EXISTS (SELECT 1 FROM m_stock_aux SA WHERE
SA.M_STORAGE_DETAIL_ID = MS.M_STORAGE_DETAIL_ID))
+ AND NOT EXISTS (SELECT 1 FROM m_stock_aux SA WHERE
SA.M_STORAGE_DETAIL_ID = MS.M_STORAGE_DETAIL_ID)
+ AND NOT EXISTS (SELECT 1 FROM m_stock_proposed SA WHERE
SA.M_STORAGE_DETAIL_ID = MS.M_STORAGE_DETAIL_ID))
]]>
</Sql>
</SqlMethod>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits