Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0033165Openbravo ERP04. Warehouse managementpublic2016-06-06 17:342016-06-17 19:38
ngarcia 
Sanjota 
urgentmajoralways
closedfixed 
5
 
3.0PR16Q3 
aferraz
Core
No
0033165: Improve Create Shipments From Orders message allowing negative stock and not having stock of product with mandatory attribute
Improve Create Shipments From Orders message allowing negative stock and not having stock of product with mandatory attribute
As group admin role:
   Set Allow Negative Stock at Client level
   Create an Attribute Set
   Set it as Lot and Require At Least One Value
   Create a Product and assign the previously created attribute set
   Add a sales price list to it
   Create a Sales Order, add the previously created product and book it
   Go to Create Shipments From Orders window and select the previously created order
   The following error is shown:
      Error: In line 10 the product has no attribute set
   The line number shown is the line number of the shipment is trying to create. It is not possible to know which product does not have stock
In M_InOut_Post, when throwing productWithoutAttributeSet error, in case M_InOutLine has related C_OrderLine, instead of showing following error:
"In line <M_InOutLine.line> the product has no attribute set",
show the following one:
"In line <M_InOutLine.line> the product has no attribute set: Order <C_Order.documentno> line <C_OrderLine.line>.
No tags attached.
Issue History
2016-06-06 17:34ngarciaNew Issue
2016-06-06 17:34ngarciaAssigned To => Triage Finance
2016-06-06 17:34ngarciaModules => Core
2016-06-06 17:34ngarciaTriggers an Emergency Pack => No
2016-06-06 17:34ngarciaIssue Monitored: networkb
2016-06-07 11:14aferrazAssigned ToTriage Finance => Sanjota
2016-06-07 11:36aferrazProposed Solution updated
2016-06-08 17:10SanjotaStatusnew => scheduled
2016-06-09 13:31SanjotaNote Added: 0087117
2016-06-15 11:06psanjuanNote Added: 0087293
2016-06-15 11:07psanjuanNote Edited: 0087293bug_revision_view_page.php?bugnote_id=0087293#r12393
2016-06-15 11:12psanjuanNote Edited: 0087293bug_revision_view_page.php?bugnote_id=0087293#r12394
2016-06-15 11:12psanjuanNote Edited: 0087117bug_revision_view_page.php?bugnote_id=0087117#r12396
2016-06-15 11:15psanjuanNote Edited: 0087293bug_revision_view_page.php?bugnote_id=0087293#r12397
2016-06-15 11:27psanjuanNote Edited: 0087293bug_revision_view_page.php?bugnote_id=0087293#r12398
2016-06-15 11:30psanjuanNote Edited: 0087293bug_revision_view_page.php?bugnote_id=0087293#r12399
2016-06-16 11:20hgbotCheckin
2016-06-16 11:20hgbotNote Added: 0087336
2016-06-16 11:20hgbotStatusscheduled => resolved
2016-06-16 11:20hgbotResolutionopen => fixed
2016-06-16 11:20hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/e6e019dabbbb961a143a656be78879672a46124e [^]
2016-06-16 11:20hgbotCheckin
2016-06-16 11:20hgbotNote Added: 0087337
2016-06-16 11:21aferrazReview Assigned To => aferraz
2016-06-16 11:21aferrazNote Added: 0087338
2016-06-16 11:21aferrazStatusresolved => closed
2016-06-16 11:21aferrazFixed in Version => 3.0PR16Q3
2016-06-17 19:38hudsonbotCheckin
2016-06-17 19:38hudsonbotNote Added: 0087628
2016-06-17 19:38hudsonbotCheckin
2016-06-17 19:38hudsonbotNote Added: 0087629

Notes
(0087117)
Sanjota   
2016-06-09 13:31   
(edited on: 2016-06-15 11:12)
Test Plan
As group admin role:
   * Set Allow Negative Stock at Client level
   * Create an Attribute Set
     Set it as Lot and Require At Least One Value
   * Create a Product and assign the previously created attribute set
   * Add a sales price list to it
   * Create a Sales Order, add the previously created product and book it
   * Go to Create Shipments From Orders window and select the previously created order
   Observe that the error message contains inoutlineNo with order no and orderlineNo.
Example : "In line <M_InOutLine.line> the product has no attribute set: Order <C_Order.documentno> Orderline <C_OrderLine.line>.

(0087293)
psanjuan   
2016-06-15 11:06   
(edited on: 2016-06-15 11:30)
Issue here is that if the user selects more than one order to create shipments from, and there is at least one order including a product that requires an attribute set, no shipment will be created and besides that the error shown is not intuitive as it does not detail the order which includes a product that requires an attribute set.

Besides the above, it is not possible to run this process "Create Shipments from Orders" for those orders which does include a product (s) which requires an attribute set.

Proposed solution:

Correct message should be

"In line <M_InOutLine.line> the product has no attribute set. Line related to Order <C_Order.documentno> and Orderline <C_OrderLine.line>".

(0087336)
hgbot   
2016-06-16 11:20   
Repository: erp/devel/pi
Changeset: e6e019dabbbb961a143a656be78879672a46124e
Author: Sanjota <sanjota.nelagi <at> promantia.com>
Date: Wed Jun 15 16:55:44 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/e6e019dabbbb961a143a656be78879672a46124e [^]

Fixes issue 33165: Improve attribute error message when processing a shipment

Give related order and order line information when throwing productWithoutAttributeSet error message to be able to know which order line is wrong when generating a shipment from Create Shipments From Orders window.

---
M src-db/database/model/functions/M_INOUT_POST.xml
---
(0087337)
hgbot   
2016-06-16 11:20   
Repository: erp/devel/pi
Changeset: e67484476dfddf9478d3313ed5af1bca1ab90548
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Thu Jun 16 11:17:08 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/e67484476dfddf9478d3313ed5af1bca1ab90548 [^]

Related to issue 33165: Code review improvements

---
M src-db/database/model/functions/M_INOUT_POST.xml
---
(0087338)
aferraz   
2016-06-16 11:21   
Code review + Testing OK
(0087628)
hudsonbot   
2016-06-17 19:38   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/0dc7be081b1c [^]
Maturity status: Test
(0087629)
hudsonbot   
2016-06-17 19:38   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/0dc7be081b1c [^]
Maturity status: Test