Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0015640Openbravo ERP03. Procurement managementpublic2011-01-13 12:332011-02-25 12:30
xabiermerino 
adrianromero 
urgentmajoralways
closedsuspended 
5
2.50MP25 
2.50MP27 
Core
No
0015640: you are able to add a discount in an order completed
you are able to add a discount in an order completed, but are not able to delete it.
-As Openbravo Admin go to Procurement Management || Transactions || Purchase Order
-Create a new order and complete it
-go to Header >> Discounts
- Create a new record and save
- realize that it is possible to save it
- Try to delete it
- realize that it is not possible to delete it
No tags attached.
related to design defect 0016057 scheduled Triage Omni OMS Is it possible able to add a discount in an order completed 
blocks defect 0015931 closed jonalegriaesarte you are able to add a discount in an order completed 
Issue History
2011-01-13 12:33xabiermerinoNew Issue
2011-01-13 12:33xabiermerinoAssigned To => adrianromero
2011-01-13 12:33xabiermerinoModules => Core
2011-01-13 12:41xabiermerinoIssue Monitored: networkb
2011-02-10 16:19adrianromeroStatusnew => scheduled
2011-02-10 16:19adrianromerofix_in_branch => pi
2011-02-10 16:19adrianromeroTypedefect => backport
2011-02-10 16:19adrianromerofix_in_branchpi =>
2011-02-10 16:19adrianromeroIssue cloned0015931
2011-02-10 16:19adrianromeroRelationship addedblocks 0015931
2011-02-15 14:10hgbotCheckin
2011-02-15 14:10hgbotNote Added: 0034201
2011-02-15 14:10hgbotStatusscheduled => resolved
2011-02-15 14:10hgbotResolutionopen => fixed
2011-02-15 14:10hgbotFixed in SCM revision => http://code.openbravo.com/erp/stable/2.50/rev/920404a85fd06ea29ddec86715dfaa76de8364e4 [^]
2011-02-15 14:11adrianromeroNote Added: 0034202
2011-02-16 11:29jonalegriaesarteNote Added: 0034221
2011-02-16 11:29jonalegriaesarteStatusresolved => closed
2011-02-16 11:29jonalegriaesarteFixed in Version => 2.50MP27
2011-02-16 14:58adrianromeroNote Added: 0034233
2011-02-16 14:58adrianromeroStatusclosed => new
2011-02-16 14:58adrianromeroResolutionfixed => open
2011-02-16 14:58adrianromeroFixed in Version2.50MP27 =>
2011-02-18 12:00adrianromeroNote Added: 0034263
2011-02-18 12:00adrianromeroStatusnew => closed
2011-02-18 12:00adrianromeroResolutionopen => suspended
2011-02-25 12:30adrianromeroIssue cloned0016057
2011-02-25 12:30adrianromeroRelationship addedrelated to 0016057

Notes
(0034201)
hgbot   
2011-02-15 14:10   
Repository: erp/stable/2.50
Changeset: 920404a85fd06ea29ddec86715dfaa76de8364e4
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Tue Feb 15 14:08:06 2011 +0100
URL: http://code.openbravo.com/erp/stable/2.50/rev/920404a85fd06ea29ddec86715dfaa76de8364e4 [^]

Fixes issue 0015640: you are able to add a discount in an order completed
It as been added the current trigger for tables C_ORDER_DISCOUNT and C_INVOICE_DISCOUNT that checks if the document has been posted to the event INSERT

---
M src-db/database/model/triggers/C_INVOICEDISCOUNT_TRG.xml
M src-db/database/model/triggers/C_ORDERDISCOUNT_TRG.xml
---
(0034202)
adrianromero   
2011-02-15 14:11   
* Testing the issue

Kindly follow the steps to test and verify that cannot be added discounts to purchase orders completed or posted.

Because there has been modified two triggers the following tests must be performed:

- Test that cannot be added discounts in completed Purchase orders, Sales orders, Purchase invoices and sales invoices.
- Test that discounts can be added, updated and removed in draft Purchase orders, Sales orders, Purchase invoices and sales invoices.

* Other areas affected.

There can be affected other processes that creates, updates or deletes discounts in orders and invoices.
(0034221)
jonalegriaesarte   
2011-02-16 11:29   
Verfied
(0034233)
adrianromero   
2011-02-16 14:58   
Changes has been backed out because it causes a regression.
(0034263)
adrianromero   
2011-02-18 12:00   
Cannot be implemented the this because of internal database technical details. Implementing the trigger functionality to avoid to create discounts in completed orders raises a "Mutating tables" exception when saving a new order with a business partner that has discounts.

In any case this is a minor issue because new added discounts to completed orders does not affects any other functionality or flow.