Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0031848Openbravo ERP02. Master data managementpublic2016-01-08 08:552016-01-13 16:31
VictorVillar 
aferraz 
immediatemajoralways
closedfixed 
5
pi 
3.0PR16Q1 
vmromanos
Core
No
0031848: Not possible to change the product definition to Stocked under some circumstancies
Not possible to change the product definition to Stocked under some circumstancies
As group admin role,
 Go to Product window:
   Create a new one. Item and stocked = Y
   Org: *
  Price list: Bebidas alegres

Go to physical inventory:
 add 1 unit of this product
Process it.

Go to Goods Shipment window and add 1 unit of this product.
Process it.

Change the definition of the product as Service.

Try to change the definition to Item and Stocked again. You can not do that.

Error: You cannot change the product to stocked because it has completed documents which would generate inventory transactions
If there is a warehouse/sales order document related with a product it should not be possible to change the stocked flag.
No tags attached.
blocks defect 00318353.0PR16Q2 closed aferraz Not possible to change the product definition to Stocked under some circumstancies 
Issue History
2016-01-08 15:03aferrazTypedefect => backport
2016-01-08 15:03aferrazTarget Version3.0PR15Q4.2 => 3.0PR16Q1
2016-01-13 16:31hgbotCheckin
2016-01-13 16:31hgbotNote Added: 0083251
2016-01-13 16:31hgbotStatusscheduled => resolved
2016-01-13 16:31hgbotResolutionopen => fixed
2016-01-13 16:31hgbotFixed in SCM revision => http://code.openbravo.com/erp/backports/3.0PR16Q1/rev/0a9e8acc986c7686d8123310a9d65fbbee5b5be3 [^]
2016-01-13 16:31hgbotCheckin
2016-01-13 16:31hgbotNote Added: 0083252
2016-01-13 16:31vmromanosReview Assigned To => vmromanos
2016-01-13 16:31vmromanosNote Added: 0083253
2016-01-13 16:31vmromanosStatusresolved => closed

Notes
(0083251)
hgbot   
2016-01-13 16:31   
Repository: erp/backports/3.0PR16Q1
Changeset: 0a9e8acc986c7686d8123310a9d65fbbee5b5be3
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Jan 11 17:23:56 2016 +0100
URL: http://code.openbravo.com/erp/backports/3.0PR16Q1/rev/0a9e8acc986c7686d8123310a9d65fbbee5b5be3 [^]

Fixes issue 31848: Not possible to change product to stocked

Stocked flag in Product window will not be updatable in case product is present in any order, invoice or warehouse document.

---
M src-db/database/model/triggers/M_PRODUCT_TRG.xml
M src-db/database/sourcedata/AD_MESSAGE.xml
---
(0083252)
hgbot   
2016-01-13 16:31   
Repository: erp/backports/3.0PR16Q1
Changeset: dd627520447d3c303a87b75b3ead7a933ede3b42
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Wed Jan 13 15:31:26 2016 +0100
URL: http://code.openbravo.com/erp/backports/3.0PR16Q1/rev/dd627520447d3c303a87b75b3ead7a933ede3b42 [^]

Related to issue 31848: code review improvements

The old messages have been reverted because it could be used by external modules, so it could be considered as a functional API Change.
Create a new message instead and improve it to be more descriptive.

Modified pl/sql comment to reflect the new behavior and to avoid confusions in the future

---
M src-db/database/model/triggers/M_PRODUCT_TRG.xml
M src-db/database/sourcedata/AD_MESSAGE.xml
---
(0083253)
vmromanos   
2016-01-13 16:31   
Code review + testing OK