Openbravo Issue Tracking System - Modules
View Issue Details
0055892ModulesAdvanced Warehouse Operationspublic2024-07-02 18:262024-07-02 18:26
AtulOpenbravo 
Triage Omni WMS 
normalminorsometimes
newopen 
5
 
 
0055892: Warning when confirming a task with DIFFERENT delta response
When confirming a task with DIFFERENT delta response, warning message is raised as below:

WARN org.openbravo.dal.core.OBInterceptor - The object OBAWO_Task(D2CECE9918C043DCA16B9ABAE1F0EA4C) (product: F4901CE835DA4353831DEF0396C9054E, expectedQuantity: 10, expectedAttribute: 0, expectedLocatorFrom: 1C925EC3A6694B0EB41EF51703C14682, expectedLocatorTo: 60A18684104E46F7A171A80B05253311, batchOfTasks: A0B89A5ED1D14C32A4F7EFD8538D377A) is detected as not new (is its id != null?) but it does not have a current state in the database. This can happen when the id is set but not setNewObject(true); has been called.

In Class: DeltaManagerDifferent, method: setOriginalTaskBackToAvailable, after the flush warning is raised.

Refreshing the object originalTask avoids this warning.
- Login in AWO-QAAdmin
- Create a Distribution Order in US West Coast, Issue Warehouse - US West Coast, Receipt Warehouse: US East Coast
- Add product Ale Beer in the line and set Quantity as 10.
- Book the DO.
- Generate Picking task for the DO Issue Line.
- Navigate to Task Tab and set Confirmed Quantity as 8.
- Click on Confirm button and choose Delta Response as Different
- Confirm the task
- Realize warning in console is raised as

"WARN org.openbravo.dal.core.OBInterceptor - The object OBAWO_Task(D2CECE9918C043DCA16B9ABAE1F0EA4C) (product: F4901CE835DA4353831DEF0396C9054E, expectedQuantity: 10, expectedAttribute: 0, expectedLocatorFrom: 1C925EC3A6694B0EB41EF51703C14682, expectedLocatorTo: 60A18684104E46F7A171A80B05253311, batchOfTasks: A0B89A5ED1D14C32A4F7EFD8538D377A) is detected as not new (is its id != null?) but it does not have a current state in the database. This can happen when the id is set but not setNewObject(true); has been called."
diff --git a/src/org/openbravo/warehouse/advancedwarehouseoperations/centralbroker/DeltaManagerDifferent.java b/src/org/openbravo/warehouse/advancedwarehouseoperations/centralbroker/DeltaManagerDifferent.java
index dfdaa48a..a15c477f 100644
--- a/src/org/openbravo/warehouse/advancedwarehouseoperations/centralbroker/DeltaManagerDifferent.java
+++ b/src/org/openbravo/warehouse/advancedwarehouseoperations/centralbroker/DeltaManagerDifferent.java
@@ -114,6 +114,7 @@ class DeltaManagerDifferent {
   }
 
   private void setOriginalTaskBackToAvailable(final OBAWOTask originalTask) {
+ OBDal.getInstance().refresh(originalTask);
     originalTask.setStatus(OBAWO_Constants.STATUS_AVAILABLE);
     OBDal.getInstance().save(originalTask);
     OBDal.getInstance().flush(); // Required


It is important to review changes in originalTask prior to refresh might loose the changes to the object as object will be fetched from database and re-attached to the session.

No tags attached.
related to feature request 0055535 closed vmromanos Receive Delivery Note linked to a Distribution Order 
Issue History
2024-07-02 18:26AtulOpenbravoNew Issue
2024-07-02 18:26AtulOpenbravoAssigned To => Triage Omni WMS
2024-07-03 08:45caristuRelationship addedrelated to 0055535

There are no notes attached to this issue.