Openbravo Issue Tracking System - Modules
View Issue Details
0021391ModulesDunning Letterspublic2012-08-20 14:182012-08-30 10:13
mtaal 
mtaal 
normalmajorhave not tried
closedfixed 
5
 
1.0.41.0.4 
0021391: Dunning work flow gives error on OBContext handling and starts work flow in same thread
The dunning work flow does not correctly set the OBContext resulting in a NPE. The process implementation should extend DalBaseProcess.

The work flows are started in the same thread as the start work flow thread itself. This results in clashes on thread variables such as the hibernate session. The work flow should start in a separate thread.
.
No tags attached.
Issue History
2012-08-20 14:18mtaalNew Issue
2012-08-20 14:18mtaalAssigned To => mtaal
2012-08-20 14:18mtaalStatusnew => scheduled
2012-08-20 14:18mtaalNote Added: 0051380
2012-08-20 14:18mtaalfix_in_branch => pi
2012-08-20 14:18mtaalNote Added: 0051381
2012-08-20 14:18mtaalStatusscheduled => resolved
2012-08-20 14:18mtaalFixed in Version => 1.0.4
2012-08-20 14:18mtaalResolutionopen => fixed
2012-08-20 14:20mtaalNote Added: 0051382
2012-08-20 14:28hgbotCheckin
2012-08-20 14:28hgbotNote Added: 0051383
2012-08-30 10:13marvintmStatusresolved => closed

Notes
(0051380)
mtaal   
2012-08-20 14:18   
.
(0051381)
mtaal   
2012-08-20 14:18   
resolved
(0051382)
mtaal   
2012-08-20 14:20   
Note to test/reproduce:
install the activiti and dunning modules.
install the dunning data through enterprise module management
set the dunning policy for a business partner
Create sales invoices (for that business partner) with a payment due date of a few days back (not more than 5 days late). Note that the sales invoice often have a payment term of 30 days, so the invoice due date should be set to 31-35 days before today to test this feature
Create a process request for the 'start dunning work flow'
Run it
Go to the Payment in plan and check the dunning log for the payment schedules of the created invoices.
(0051383)
hgbot   
2012-08-20 14:28   
Repository: erp/pmods/org.openbravo.financial.dunningletters
Changeset: 34ad3eca0a3d670270a7462c2cad5f7fd67faeb4
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Mon Aug 20 14:28:26 2012 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.financial.dunningletters/rev/34ad3eca0a3d670270a7462c2cad5f7fd67faeb4 [^]

Related to issue 21391: Dunning work flow gives error on OBContext handling and starts work flow in same thread
Transaction handling is already done by base dalprocess, let it be done there

---
M src/org/openbravo/financial/dunningletters/StartDunningWorkFlowProcess.java
---