Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0031088Openbravo ERP04. Warehouse managementpublic2015-09-14 12:562015-10-07 16:50
VictorVillar 
vmromanos 
urgentmajoralways
closedfixed 
5
pi 
3.0PR15Q4 
dmiguelez
OBPS
Core
38230
No
0031088: It should not be possible to define the Costing background process for Organizations not Legal
It should not be possible to define the Costing background process for Organizations not Legal
As Admin role,
  Go to Process Request window:
     create a new register for España Región Norte.

This is wrong behavior which could cause inconsistent cost values. It should be possible only for Legals or any ancestor (not children organizations)
Define an EntityEventObserver to avoid saving (insert and update) the record when the process is the Costing background and the organization has an ancestor which is a legal entity

Add a similar validation in the costing background process itself for the context organization
No tags attached.
blocks defect 00308153.0PR16Q1 closed vmromanos It should not be possible to define the Costing background process for Organizations not Legal 
Issue History
2015-10-07 16:49dmiguelezTypedefect => backport
2015-10-07 16:49dmiguelezTarget Version3.0PR16Q1 => 3.0PR15Q4
2015-10-07 16:50hgbotCheckin
2015-10-07 16:50hgbotNote Added: 0080866
2015-10-07 16:50hgbotStatusscheduled => resolved
2015-10-07 16:50hgbotResolutionopen => fixed
2015-10-07 16:50hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/9bcc5cdaf9996b5bb29aee3422f66f79c589f039 [^] => http://code.openbravo.com/erp/backports/3.0PR15Q4/rev/007045d0abe6e9f25ce9ef002d26939a3bcda97e [^]
2015-10-07 16:50dmiguelezReview Assigned To => dmiguelez
2015-10-07 16:50dmiguelezNote Added: 0080867
2015-10-07 16:50dmiguelezStatusresolved => closed

Notes
(0080866)
hgbot   
2015-10-07 16:50   
Repository: erp/backports/3.0PR15Q4
Changeset: 007045d0abe6e9f25ce9ef002d26939a3bcda97e
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Wed Sep 30 16:13:10 2015 +0200
URL: http://code.openbravo.com/erp/backports/3.0PR15Q4/rev/007045d0abe6e9f25ce9ef002d26939a3bcda97e [^]

Fixed bug 31088: Scheduled Organization for Costing background process

The Costing Background Process should only be scheduled for a legal entity or any of its ancestor.

The fix adds a validation in both the ProcessRequestEventHandler, so each time a record is saved/updated the validation is run, and in the CostingBackground class itself to control wrong process request scheduled before this validation.

---
M src-db/database/sourcedata/AD_MESSAGE.xml
M src/org/openbravo/costing/CostingBackground.java
M src/org/openbravo/costing/CostingUtils.java
M src/org/openbravo/event/ProcessRequestEventHandler.java
---
(0080867)
dmiguelez   
2015-10-07 16:50   
Code Review + Testing Ok