Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0039566
TypeCategorySeverityReproducibilityDate SubmittedLast Update
design defect[Openbravo ERP] 07. Sales managementmajoralways2018-10-30 10:422018-10-31 17:28
ReporterngarciaView Statuspublic 
Assigned ToTriage Finance 
PriorityurgentResolutionopenFixed in Version
StatusacknowledgedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0039566: Create Credit button for Return From Customer is only shown if there exists a line related with an invoiced order line

DescriptionCreate Credit button for Return From Customer is only shown if there exists a line related with an invoiced order line. Then, the lines without any original order related are also invoices, so the button should be always shown
Steps To ReproduceAs group admin role:
   Set 'RM Allow Orphan Line' preference to Y
   Log out and log in

   Create a Sales Order, Goods Shipment and Sales Invoice
   Create a Goods Shipment (without sales order) and sales invoice
   Create a Return From Customer header
   Click on Pick/Edit and select the previously created two shipments (do not return the whole quantity)
   Click in Insert Orphan line and add a product to it
   Book the RFC
   Create a Return Material Receipt from the RFC
   Return to the RFC and launch Create Credit process
   Check the 3 lines are included in the Sales Invoice created

   Create a new Return From Customer
   Insert Orphan line
   Book it
   Create Return Material Receipt
   Return to RFC and check the Create Credit button is not shown. It should be shown

   Create a new Return From Customer
   Click on Pick/edit Lines and select the 2nd goods shipment created (the one without sales order)
   Book it
   Create Return Material Receipt
   Return to RFC and check the Create Credit button is not shown. It should be shown
TagsNo tags attached.
Attached Filesdiff file icon 39566.diff [^] (1,498 bytes) 2018-10-31 16:52 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0107680)
markmm82 (developer)
2018-10-31 03:25

Test Plan:
As group admin role:
   Set 'RM Allow Orphan Line' preference to Y
   Log out and log in

   Create a Sales Order, Goods Shipment and Sales Invoice
   Create a Goods Shipment (without sales order) and sales invoice
   Create a Return From Customer header
   Click on Pick/Edit and select the previously created two shipments (do not return the whole quantity)
   Click in Insert Orphan line and add a product to it
   Book the RFC
   Create a Return Material Receipt from the RFC
   Return to the RFC and launch Create Credit process
   Check the 3 lines are included in the Sales Invoice created

   Create a new Return From Customer
   Insert Orphan line
   Book it
   Create Return Material Receipt
   Return to RFC and check the Create Credit button is shown. Execute it and check the line is included in the Sales Invoice created

   Create a new Return From Customer
   Click on Pick/edit Lines and select the 2nd goods shipment created (the one without sales order)
   Book it
   Create Return Material Receipt
   Return to RFC and check the Create Credit button is shown.
   Execute it and check the line is included in the Sales Invoice created
(0107702)
vmromanos (developer)
2018-10-31 16:52

Moved to Design Defect.

The proposed solution (to relax the display logic to always show the button) implies an API functional change, which in fact could be perceived as a regression by the existing users.

See documentation: http://wiki.openbravo.com/wiki/Return_from_Customer [^]
"A new button Create credit might appear or not based on the original sales order. If the order is already invoiced then it will be present if not it won't."

As a general rule, from a functional perspective it makes all the sense to show the button only for the orders that have been previously invoiced.
Both the documentation and the code are indeed developed this way.


The concrete problem in this issue is that, when any order line was originally invoiced, the system wrongly allows to invoice every line included in the order (previously invoiced or not).
The way to properly fix this bug is by making sure you can only invoice the lines that were invoiced in the past.

However implementing this fix is very difficult, and it would require an important effort. Right now the code wrongly assumes all the lines in the order should be invoiced and calls the C_Invoice_Create process for the whole order. Instead only the previously invoiced order lines should be invoiced.
That's why we move this design defect.

Finally, as a workaround only for the customers that really want to always show this button, we have attached a patch which can be easily exported to a custom template.

- Issue History
Date Modified Username Field Change
2018-10-30 10:42 ngarcia New Issue
2018-10-30 10:42 ngarcia Assigned To => Triage Finance
2018-10-30 10:42 ngarcia Modules => Core
2018-10-30 10:42 ngarcia Triggers an Emergency Pack => No
2018-10-30 10:43 ngarcia Issue Monitored: networkb
2018-10-30 16:37 vmromanos Assigned To Triage Finance => markmm82
2018-10-30 18:45 markmm82 Status new => scheduled
2018-10-31 03:25 markmm82 Note Added: 0107680
2018-10-31 16:52 vmromanos Note Added: 0107702
2018-10-31 16:52 vmromanos Type defect => design defect
2018-10-31 16:52 vmromanos File Added: 39566.diff
2018-10-31 17:28 vmromanos Assigned To markmm82 => Triage Finance
2018-10-31 17:28 vmromanos Status scheduled => acknowledged


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker