Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0013224Openbravo ERP03. Procurement managementpublic2010-05-05 10:242010-05-18 21:43
harikrishnan 
harikrishnan 
normalmajoralways
closedfixed 
5
pi 
pi 
Core
No
0013224: When completing or processing documents the updatedby column is not updated properly
These are the places where the audit fields are not properly updated.

1.Matched Purchase Orders
2.Matched Invoices
3.Create Purchase Invoices from Deliveries

-Create a document with one user
Process or complete with other user
See that the updatedby is not properly updated.
No tags attached.
depends on backport 0013230pi closed harikrishnan When completing or processing documents the updatedby column is not updated properly 
Issue History
2010-05-05 10:24harikrishnanNew Issue
2010-05-05 10:24harikrishnanAssigned To => adrianromero
2010-05-05 10:46harikrishnanDescription Updatedbug_revision_view_page.php?rev_id=323#r323
2010-05-05 14:06arunkumarStatusnew => scheduled
2010-05-05 14:06arunkumarfix_in_branch => pi
2010-05-06 11:14harikrishnanAssigned Toadrianromero => harikrishnan
2010-05-06 11:17hgbotCheckin
2010-05-06 11:17hgbotNote Added: 0026978
2010-05-06 11:17hgbotStatusscheduled => resolved
2010-05-06 11:17hgbotResolutionopen => fixed
2010-05-06 11:17hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/d2cb958569665fa0be92726b68f6dec3bf66906d [^]
2010-05-06 11:21harikrishnanNote Added: 0026979
2010-05-15 18:38sureshbabuNote Added: 0027333
2010-05-17 08:41sureshbabuNote Added: 0027350
2010-05-17 08:41sureshbabuStatusresolved => closed
2010-05-18 00:01anonymoussf_bug_id0 => 3002962
2010-05-18 21:43hudsonbotCheckin
2010-05-18 21:43hudsonbotNote Added: 0027485

Notes
(0026978)
hgbot   
2010-05-06 11:17   
Repository: erp/devel/pi
Changeset: d2cb958569665fa0be92726b68f6dec3bf66906d
Author: Harikrishnan Raja <harikrishnan.raja <at> openbravo.com>
Date: Thu May 06 14:46:25 2010 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/d2cb958569665fa0be92726b68f6dec3bf66906d [^]

Fixes issue 13224: When completing or processing documents the updated-by column is not updated properly.

---
M src-db/database/model/functions/C_INVOICE_POST.xml
M src-db/database/model/functions/C_ORDER_POST1.xml
M src-db/database/model/functions/C_ORDER_PO_CREATE.xml
---
(0026979)
harikrishnan   
2010-05-06 11:21   
Steps to test:
*Create two new user.
    1.UserA
    2.userB
*Login as UserA
*Create new record in each above mentioned section(Don't complete it or process it)
*Login as UserB and complete all the record above created.


Root cause & solution:
Audit fields are not properly updated.Hence the user id is taken from the pinstance table and used in update and insert statement.

Impact:
These are the files that are affected by this fix.

C_INVOICE_CANCEL.xml
C_INVOICE_CREATE.xml
C_INVOICE_POST0.xml
C_ORDER_POST.xml
M_REQUISITION_CREATEPO.xml
(0027333)
sureshbabu   
2010-05-15 18:38   
@ Hari,

Sorry the documents you have mentioned above are created by the system automatically after performing respective actions. So please update the steps to reproduce in detail. or contact me so that we can discuss on this.
(0027350)
sureshbabu   
2010-05-17 08:41   
Right now system updates the documents with the user name instead of system id.
(0027485)
hudsonbot   
2010-05-18 21:43   
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/d2cb95856966 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/aa11838d5f80 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17380.obx [^]