Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0038685Openbravo ERP04. Warehouse managementpublic2018-06-01 13:422018-06-28 08:21
maite 
collazoandy4 
urgentmajoralways
closedfixed 
5
 
3.0PR18Q3 
Sandrahuguet
Core
No
0038685: It is not possible to process a Physical Inventory for a product with attributes that has negative stock without attributes
When there is no stock for a product defined with attributes but is sold via POS, a goods shipment document will be created for this product without attributes. Then the user needs to regularize this stock but is not able to process a Physical Inventory document.
0. Access POS Terminal (https://livebuilds.openbravo.com/retail_mp_3.0RR18Q2/web/org.openbravo.retail.posterminal/?terminal=VBS-1#retail.pointofsale [^]) and create ticket using "Hiking Boots" product. Pay ticket
1. Access to backoffice. Create new Physical Inventory for "Vall Blanca Store" organization. Add line and open product selector to set "Hiking Boots" products with qty=-1. Run "Process Inventory Count" and error "In line 10 the product has no attribute set" will be received
No tags attached.
related to defect 0038687 closed rqueralta Retail Modules Autobom not working wth products that have attributes and if there is not stock. 
Issue History
2018-06-01 13:42maiteNew Issue
2018-06-01 13:42maiteAssigned To => Triage Finance
2018-06-01 13:42maiteModules => Core
2018-06-01 13:42maiteResolution time => 1529618400
2018-06-01 13:42maiteTriggers an Emergency Pack => No
2018-06-01 13:43maiteIssue Monitored: networkb
2018-06-01 14:16VictorVillarRelationship addedrelated to 0038687
2018-06-13 11:48dmiguelezAssigned ToTriage Finance => AtulOpenbravo
2018-06-19 12:42dmiguelezAssigned ToAtulOpenbravo => collazoandy4
2018-06-21 00:15collazoandy4Statusnew => scheduled
2018-06-21 00:15collazoandy4Note Added: 0105288
2018-06-27 08:57hgbotCheckin
2018-06-27 08:57hgbotNote Added: 0105461
2018-06-27 08:57hgbotStatusscheduled => resolved
2018-06-27 08:57hgbotResolutionopen => fixed
2018-06-27 08:57hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/20cd44382a6502e47c1aee6a5e6d9eabd996d6fa [^]
2018-06-27 08:57hgbotCheckin
2018-06-27 08:57hgbotNote Added: 0105462
2018-06-27 08:57hgbotCheckin
2018-06-27 08:57hgbotNote Added: 0105463
2018-06-27 08:57hgbotCheckin
2018-06-27 08:57hgbotNote Added: 0105464
2018-06-27 08:57hgbotCheckin
2018-06-27 08:57hgbotNote Added: 0105465
2018-06-27 09:40SandrahuguetReview Assigned To => Sandrahuguet
2018-06-27 09:40SandrahuguetNote Added: 0105466
2018-06-27 09:40SandrahuguetStatusresolved => closed
2018-06-27 09:40SandrahuguetFixed in Version => 3.0PR18Q3
2018-06-27 13:04hudsonbotCheckin
2018-06-27 13:04hudsonbotNote Added: 0105470
2018-06-27 13:04hudsonbotCheckin
2018-06-27 13:04hudsonbotNote Added: 0105471
2018-06-27 13:04hudsonbotCheckin
2018-06-27 13:04hudsonbotNote Added: 0105472
2018-06-27 13:04hudsonbotCheckin
2018-06-27 13:04hudsonbotNote Added: 0105473
2018-06-27 13:04hudsonbotCheckin
2018-06-27 13:04hudsonbotNote Added: 0105474
2018-06-28 08:21hgbotCheckin
2018-06-28 08:21hgbotNote Added: 0105479

Notes
(0105288)
collazoandy4   
2018-06-21 00:15   
Test Plan I
  Access POS Terminal and create ticket using "Hiking Boots" product. Pay ticket
  Access to backoffice. Create new Physical Inventory for Vall Blanca Store organization.
  Add line and open product selector to set Hiking Boots products with qty=0.
  Run Process Inventory Count and check the process ends without errors
  Check the product stock was updated

Test Plan II
  Create another Physical Inventory for Vall Blanca Store organization
  Add line and open product selector to set Hiking Boots products with qty=5.
  Run Process Inventory Count and check the error message 'In line 10 the product has no attribute set' is shown
(0105461)
hgbot   
2018-06-27 08:57   
Repository: erp/devel/pi
Changeset: 20cd44382a6502e47c1aee6a5e6d9eabd996d6fa
Author: Armaignac <collazoandy4 <at> gmail.com>
Date: Wed Jun 20 18:17:10 2018 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/20cd44382a6502e47c1aee6a5e6d9eabd996d6fa [^]

Fixes issue 38685:It is not possible to process a Physical Inventory for a
product with attributes that has negative stock without attributes

When a new physical inventory was process with a product without an attribute set
defined an exception was throw aborting the process.

Now a physical inventory can be process if the product have not attribute set defined
and no available stock in the bin.

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
M src/org/openbravo/materialmgmt/InventoryCountProcess.java
---
(0105462)
hgbot   
2018-06-27 08:57   
Repository: erp/devel/pi
Changeset: 8da978492eeb1bb897ba220dfee905030d17cd12
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Mon Jun 25 16:11:54 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/8da978492eeb1bb897ba220dfee905030d17cd12 [^]

Related to Issue 38685. Code Review changes

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
M src/org/openbravo/materialmgmt/InventoryCountProcess.java
---
(0105463)
hgbot   
2018-06-27 08:57   
Repository: erp/devel/pi
Changeset: fcd2b0c4708176dd341897f220e4d96a06bc01b0
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Mon Jun 25 17:15:16 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/fcd2b0c4708176dd341897f220e4d96a06bc01b0 [^]

Related to Issue 38685. Code Review changes:

* When querying for exising stock, take into account that the uom
  is the same one as the uom of the inventory line
* When querying for existing stock, check that there is no stock
  assign to draft transactions
* When checking for existing stock, do it only when the quantitycount
  is 0
* Changed the query to be more readable
* Added explanatory commentary

---
M src/org/openbravo/materialmgmt/InventoryCountProcess.java
---
(0105464)
hgbot   
2018-06-27 08:57   
Repository: erp/devel/pi
Changeset: 91b8d9df5a3bbe33e18b2669db5320452d4bcb19
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Mon Jun 25 17:57:48 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/91b8d9df5a3bbe33e18b2669db5320452d4bcb19 [^]

Related to Issue 38685. Refactor of runChecks method

* Split method into smaller ones
* Renamed variables with obtuse names
* Delete unnecessary exceptions thrown
* Changed queries to make them more readable

---
M src/org/openbravo/materialmgmt/InventoryCountProcess.java
---
(0105465)
hgbot   
2018-06-27 08:57   
Repository: erp/devel/pi
Changeset: 79f006ced359347f2a6cbf384ff95586eb243b9f
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Tue Jun 26 11:42:34 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/79f006ced359347f2a6cbf384ff95586eb243b9f [^]

Related to Issue 38685. Code Review changes:

* Formatted code to make it more readable
* Added check of quantity in draft transactions to query that retrieves stock
* Changed logic to check if the attribute can be null
  * I the QuantityCount of the line is <> 0, attribute is mandatory
  * If there is no stock with emtpy attribute, attribute is mandatory
  * If there is previous stock with empty attribute and the quantity count
    is 0 then the attribute can be null

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
---
(0105466)
Sandrahuguet   
2018-06-27 09:40   
Code review + testing OK
(0105470)
hudsonbot   
2018-06-27 13:04   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7721d0db9ee1 [^]
Maturity status: Test
(0105471)
hudsonbot   
2018-06-27 13:04   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7721d0db9ee1 [^]
Maturity status: Test
(0105472)
hudsonbot   
2018-06-27 13:04   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7721d0db9ee1 [^]
Maturity status: Test
(0105473)
hudsonbot   
2018-06-27 13:04   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7721d0db9ee1 [^]
Maturity status: Test
(0105474)
hudsonbot   
2018-06-27 13:04   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7721d0db9ee1 [^]
Maturity status: Test
(0105479)
hgbot   
2018-06-28 08:21   
Repository: erp/devel/pi
Changeset: 58eb040e2d99f678863d84205db30f1337a9245d
Author: Sandra Huguet <sandra.huguet <at> openbravo.com>
Date: Thu Jun 28 08:21:40 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/58eb040e2d99f678863d84205db30f1337a9245d [^]

related to issue 38685 delete unused variable

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
---