Openbravo Issue Tracking System - Modules
View Issue Details
0039607ModulesAdvanced Warehouse Operationspublic2018-11-08 17:572018-11-09 14:39
ngarcia 
nonofrancisco 
urgentmajoralways
closedfixed 
5
 
 
vmromanos
0039607: Cannot close a Distribution Order Receipt
Cannot close a Distribution Order Receipt
In https://livebuilds.openbravo.com/retail_modules_pgsql_pi [^]

Log in with AWO-QA Admin
Create a Distribution Order Receipt for US
Add a line to it and book it
Navigate to the related Distribution Order Issue
Confirm it
Return to Distribution Order Receipt and try to close it
You will get the following error:
   "Can not close an Order with Tasks in status 'Available' or 'Reserved'"

The log shows:

   ERROR org.openbravo.base.exception.OBException - Can not close an Order with Tasks in status 'Available' or 'Reserved'
org.openbravo.base.exception.OBException: Can not close an Order with Tasks in status 'Available' or 'Reserved'
    at org.openbravo.warehouse.advancedwarehouseoperations.distributionorders.hook.AfterDOAWOProcessedHook.run(AfterDOAWOProcessedHook.java:53)
    at org.openbravo.distributionorder.hooks.AfterDistributionOrderProcessedHookRunner.run(AfterDistributionOrderProcessedHookRunner.java:73)
    at org.openbravo.distributionorder.erpCommon.utility.ProcessDistributionOrderUtil.runAfterDistributionOrderProcessedHooks(ProcessDistributionOrderUtil.java:531)
    at org.openbravo.distributionorder.erpCommon.utility.ProcessDistributionOrderUtil.processDistributionOrder(ProcessDistributionOrderUtil.java:106)
    at org.openbravo.distributionorder.actionHandler.ProcessDistributionOrder.doExecute(ProcessDistributionOrder.java:50)
No tags attached.
caused by design defect 0038911 closed nonofrancisco When a picked but not issued DOi is CLOSED, the reservations are not deleted. 
Issue History
2018-11-08 17:57ngarciaNew Issue
2018-11-08 17:57ngarciaAssigned To => Triage Finance
2018-11-08 17:58ngarciaRelationship addedcaused by 0038911
2018-11-08 17:58ngarciaIssue Monitored: networkb
2018-11-08 17:59vmromanosStatusnew => scheduled
2018-11-08 17:59vmromanosAssigned ToTriage Finance => nonofrancisco
2018-11-08 18:47vmromanosNote Added: 0107808
2018-11-09 08:46ngarciaResolution time => 1543446000
2018-11-09 09:41hgbotCheckin
2018-11-09 09:41hgbotNote Added: 0107815
2018-11-09 09:41hgbotStatusscheduled => resolved
2018-11-09 09:41hgbotResolutionopen => fixed
2018-11-09 09:41hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/2c63586d1ddf00fb460652e49860777f0798de89 [^]
2018-11-09 09:41hgbotCheckin
2018-11-09 09:41hgbotNote Added: 0107816
2018-11-09 09:52hgbotCheckin
2018-11-09 09:52hgbotNote Added: 0107818
2018-11-09 09:52hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/2c63586d1ddf00fb460652e49860777f0798de89 [^] => http://code.openbravo.com/retail/backports/AWO/3.0RR18Q3/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/670fef40392910d5b25293cde8591cfd27d9f2f1 [^]
2018-11-09 09:52vmromanosReview Assigned To => vmromanos
2018-11-09 09:52vmromanosNote Added: 0107822
2018-11-09 09:52vmromanosStatusresolved => closed
2018-11-09 14:39nonofranciscoNote Added: 0107826
2022-09-06 17:18caristuCategoryAdvance Warehouse Operations => Advanced Warehouse Operations

Notes
(0107808)
vmromanos   
2018-11-08 18:47   
Workaround meanwhile we fix it: declare "Delete tasks and reservations when closing DO" preference to Y
(0107815)
hgbot   
2018-11-09 09:41   
Repository: erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders
Changeset: 2c63586d1ddf00fb460652e49860777f0798de89
Author: Nono Carballo <nonofce <at> gmail.com>
Date: Thu Nov 08 14:45:01 2018 -0500
URL: http://code.openbravo.com/erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/2c63586d1ddf00fb460652e49860777f0798de89 [^]

Fixes issue 39607: Cannot close a Distribution Order Receipt

- When closing a Distribution Order and preference
  "OBDOA_DeleteNonConfTaskAndResWhenCloseDO"is not set, an exception is
  thrown only if there are non confirmed task for any of distribution order
  lines.
- An automated test was added.

---
M src-test/org/openbravo/warehouse/advancedwarehouseoperations/distributionorders/test/OBDOAWOCloseDistributionOrder.java
M src/org/openbravo/warehouse/advancedwarehouseoperations/distributionorders/hook/AfterDOAWOProcessedHook.java
---
(0107816)
hgbot   
2018-11-09 09:41   
Repository: erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders
Changeset: d45377f73bc5e489e3ff1de0fbac609ab672ae26
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Fri Nov 09 09:35:32 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/d45377f73bc5e489e3ff1de0fbac609ab672ae26 [^]

Related to issue 39607: Code review improvements
Simplified code
Renamed updateQuery -> query

---
M src/org/openbravo/warehouse/advancedwarehouseoperations/distributionorders/hook/AfterDOAWOProcessedHook.java
---
(0107818)
hgbot   
2018-11-09 09:52   
Repository: retail/backports/AWO/3.0RR18Q3/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders
Changeset: 670fef40392910d5b25293cde8591cfd27d9f2f1
Author: Nono Carballo <nonofce <at> gmail.com>
Date: Thu Nov 08 14:45:01 2018 -0500
URL: http://code.openbravo.com/retail/backports/AWO/3.0RR18Q3/org.openbravo.warehouse.advancedwarehouseoperations.distributionorders/rev/670fef40392910d5b25293cde8591cfd27d9f2f1 [^]

Fixes issue 39607: Cannot close a Distribution Order Receipt

- When closing a Distribution Order and preference
  "OBDOA_DeleteNonConfTaskAndResWhenCloseDO"is not set, an exception is
  thrown only if there are non confirmed task for any of distribution order
  lines.
- An automated test was added.

---
M src-test/org/openbravo/warehouse/advancedwarehouseoperations/distributionorders/test/OBDOAWOCloseDistributionOrder.java
M src/org/openbravo/warehouse/advancedwarehouseoperations/distributionorders/hook/AfterDOAWOProcessedHook.java
---
(0107822)
vmromanos   
2018-11-09 09:52   
Code review + testing OK
(0107826)
nonofrancisco   
2018-11-09 14:39   
Test Plan

Log in with AWO-QA Admin
Create a Distribution Order Receipt for US
Add a line to it and book it
Navigate to the related Distribution Order Issue
Confirm it
Return to Distribution Order Receipt and try to close it
Verify the Distribution Order Receipt can be closed successfully.