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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0039517
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 07. Sales managementmajoralways2018-10-23 17:052018-12-11 20:22
ReporterngarciaView Statuspublic 
Assigned Tomarkmm82 
PriorityurgentResolutionfixedFixed in Version3.0PR19Q1
StatusclosedFix in branchFixed in SCM revision7ba289b96606
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tovmromanos
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0039517: Sales Invoice Dimensional Report is showing a positive Margin % when the Profit is negative

DescriptionSales Invoice Dimensional Report is showing a positive Margin % when the Profit is negative
Steps To ReproduceAs group admin role:
   Create a Sales Order
   Add a product to it
   Set a Net Unit Price below the current average cost of the product
   Book it
   Create a goods shipment from it
   Create a sales invoice to it
   
   Launch the Costing Background Process and check it finishes successfully

   Go to Sales Invoice Dimensional Report:
      From Date: today
      To Date: today
      Organization: select invoice's organization
      Dimensions:
         Documentno
         Product

   Check the Profit is shown in negative as it is Amount - Cost
   Check the Margin is shown as positive. This is wrong
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00274613.0PR15Q1 closedvmromanos The cost on the Sales invoice Dimensional Report should be different for Credit Memo invoices 

-  Notes
(0107605)
markmm82 (developer)
2018-10-25 20:35
edited on: 2018-10-29 17:21

Test plan 1: Cases defined when the Profit is negative
 As group admin role:
   Create a Sales Order
   Add a product to it
   Set a Net Unit Price below the current average cost of the product
   Book it
   Create a goods shipment from it
   Create a sales invoice to it
   
   Launch the Costing Background Process and check it finishes successfully

   Go to Sales Invoice Dimensional Report:
      From Date: today
      To Date: today
      Organization: select invoice's organization
      Dimensions:
         Documentno
         Product

   Check the Profit is shown in negative as it is Amount - Cost
   Check the Margin is shown as negative.
  Export the report as PDF as well as XLS and notice the Margin is shown in negative too.

   Check Comparative report flag and define today as From/To Reference Day.
   If you export the report as HTML, PDF or XLS you will notice that the Margin is shown in negative too, also the Margin reference is negative too.

(0107645)
markmm82 (developer)
2018-10-29 19:19

Test cases related to issue 27461

Test plan 2: Credit Memo non comparative Product dimension report

1- Login into Openbravo ERP
2- Go to Goods Shipment window, create a new register: España Región Norte.
3- Go to lines tab, add Producto: Vino Tinto 0,75L with Qty: 1
4- Complete it.
5- Go to Sales invoice window, create a new register: España región Norte.
6- Click on Create Lines From Shipment button and select the Goods Shipment created before.
7- Change the Document type to AR Credit Memo. Process it.
8- Check that the Costing Background Process has finished successfully.
9- Go to Sales invoice Dimensional Report. Select Date from: today and Date to: today
10- Filter by Vino Tinto.
11- Select Product in dimensions filters and launch HTML format report.
12- Realise that fields Quantity, Amount, Cost, Profit and Margin are taking negative values
13- Select printing in PDF and XLS format
14- Also fields Quantity, Amount, Cost, Profit and Margin are taking negative values

Test plan 3: Credit Memo non comparative Business Partner dimension report

1- Login into Openbravo ERP
2- Repeat 2-10 steps.
11- Select Business Partner in dimensions filters and launch HTML format report.
12- Realise that fields Amount, Cost, Profit and Margin are taking negative values
13- Select printing in PDF adn XLS format
14- Also fields Amount, Cost, Profit and Margin are taking negative values. Also check the Margin reference is negative too.

Test plan 4: Credit Memo non comparative DocumentNo dimension report

1- Login into Openbravo ERP
2- Repeat 2-10 steps.
11- Select DocumentNo in dimensions filters and launch HTML format report.
12- Realise that fields Amount, Cost, Profit and Margin are taking negative values for created Sales Invoice.
13- Select printing in PDF and XLS format
14- Also fields Amount, Cost, Profit and Margin are taking negative values.

Test plan 5: Credit Memo non comparative multi dimensional report

1- Login into Openbravo ERP
2- Repeat 2-10 steps.
11- Select Product, Product Group, Business Partner Group, Business Partner and DocumentNo in dimensions filters and launch HTML format report.
12- Realise that a report with 5 levels of grouping is shown. Fields Quantity, Amount, Cost, Profit and Margin are taking negative values.
13- Select printing in PDF format
14- Also a report with 5 levels of grouping is shown. Fields Amount, Cost, Profit and Margin are taking negative values.

Test plan 6: Credit Memo comparative Product dimensional report

1- Login into Openbravo ERP
2- Go to Goods Shipment window, create a new register: España Región Norte.
3- Go to lines tab, add Producto: Vino Tinto 0,75L with Qty: 1
4- Complete it.
5- Go to Sales invoice window, create a new register: España región Norte
6- Click on Create Lines From Shipment button and select the Goods Shipment created before.
7- Change the Document type to AR Credit Memo and process it.
8- Check that the Costing Background Process has finished successfully.
9- Go to Sales invoice Dimensional Report. Select Date from: today and Date to: today
10- Check Comparative Report option and select From Reference Date: today and To Reference Date: today
11- Filter by Vino Tinto.
12- Select Product in dimensions filters and launch HTML format report.
13- Realise that fields Quantity, Amount, Cost, Profit and Margin are taking negative values. Also References for these fields take negative values too.
13- Select printing in PDF format
14- Also fields Quantity, Amount, Cost, Profit and Margin are taking negative values.

Test plan 7: Credit Memo comparative multi dimensional report

1- Login into Openbravo ERP
2- Repeat 2-11 steps.
12- Select Product, Product Group, Business Partner and DocumentNo in dimensions filters and launch HTML format report.
13- Realise that a report with 4 levels of grouping is shown. Fields Quantity, Amount, Cost, Profit and Margin are taking negative values. Also References for these fields take negative values too.
14- Select printing in PDF format
15- Also a report with 4 levels of grouping is shown. Fields Amount, Cost, Profit and Margin and their respective references are taking negative values.

In all these cases dimensional options XSL format ReportInvoiceCustomerDimensional sheet shows the same structure with fields Amount, Cost, Profit and Margin taking negative values.

Test plan 8: AR Invoice non comparative Product dimension report

1- Login into Openbravo ERP
2- Go to Goods Shipment window, create a new register: España Región Norte.
3- Go to lines tab, add Producto: Vino Tinto 0,75L with Qty: 1
4- Complete it.
5- Go to Sales invoice window, create a new register: España región Norte
6- Select another date for example: a day after today.
7- Click on Create Lines From Shipment button and select the Goods Shipment created before.
8- Change the Document type to AR Credit Memo and process it.
9- Check that the Costing Background Process has finished successfully.
10- Go to Sales invoice Dimensional Report. Select Date from: a day after today and Date to: a day after today
11- Filter by Vino Tinto.
12- Select Product in dimensions filters and launch HTML format report.
13- Realise that fields Quantity, Amount, Cost, Profit and Margin are taking positive values
14- Select printing in PDF format
15- Also fields Quantity, Amount, Cost, Profit and Margin are taking positive values

Test plan 9: AR Invoice non comparative multi dimensional report

1- Login into Openbravo ERP
2- Repeat 2-11 previous steps.
12- Select Product, Product Group, Business Partner Group, Business Partner and DocumentNo in dimensions filters and launch HTML format report.
13- Realise that a report with 5 levels of grouping is shown. Fields Amount, Cost, Profit and Margin are taking positive values.
14- Select printing in PDF format
15- Also a report with 5 levels of grouping is shown. Fields Amount, Cost, Profit and Margin are taking positive values.

Test plan 10: AR Invoice comparative multi dimensional report

1- Login into Openbravo ERP
2- Go to Goods Shipment window, create a new register: España Región Norte.
3- Go to lines tab, add Producto: Vino Tinto 0,75L with Qty: 1
4- Complete it.
5- Go to Sales invoice window, create a new register: España región Norte.
6- Select another date for example: a day after today.
7- Click on Create Lines From Shipment button and select the Goods Shipment created before.
8- Change the Document type to AR Credit Memo and process it.
9- Check that the Costing Background Process has finished successfully.
10- Go to Sales invoice Dimensional Report. Select Date from: a day after today and Date to: a day after today
11- Check Comparative Report option and select From Reference Date: a day after today and To Reference Date: a day after today
12- Select Product, Product Group, Business Partner and DocumentNo in dimensions filters and launch HTML format report.
13- Realise that a report with 4 levels of grouping is shown. Fields Quantity, Amount, Cost, Profit and Margin are taking positive values. Also References for these fields take positive values too.
14- Select printing in PDF format
15- Also a report with 4 levels of grouping is shown. Fields Amount, Cost, Profit and Margin and their respective references are taking positive values.

In these 2 last cases dimensional options XSL format ReportInvoiceCustomerDimensional sheet shows the same structure with fields Amount, Cost, Profit and Margin taking positive values.

Test plan 11: Credit Memo and AR Invoice comparative product dimension report.

1- Login into Openbravo ERP
2- Go to Sales invoice Dimensional Report. Select Date from: today and Date to: today
3- Check Comparative Report option and select From Reference Date: a day after today and To Reference Date: a day after today
4- Filter by Vino Tinto.
5- Select Product in dimensions filters and launch HTML format report.
6- Realise that negative values are reflected for normal fields (today Credit Memo) and positive ones for the references (a day after today AR Invoice).
(0107698)
hgbot (developer)
2018-10-31 12:34

Repository: erp/devel/pi
Changeset: 7ba289b96606324c420fcdbc57850f53454de02e
Author: Mark <markmm82 <at> gmail.com>
Date: Mon Oct 29 12:14:27 2018 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/7ba289b96606324c420fcdbc57850f53454de02e [^]

Fixes issue 39517: Sales Invoice Dimensional Report is showing a positive Margin
% when the Profit is negative

Set the Margin % with the same sign of the profit.

---
M src/org/openbravo/erpCommon/ad_reports/ReportInvoiceCustomerDimensionalAnalysesComparativeJR.jrxml
M src/org/openbravo/erpCommon/ad_reports/ReportInvoiceCustomerDimensionalAnalysesJR_data.xsql
M src/org/openbravo/erpCommon/ad_reports/ReportInvoiceCustomerDimensionalAnalysesNoComparativeJR.jrxml
M src/org/openbravo/erpCommon/ad_reports/ReportInvoiceCustomerDimensionalAnalysesXLS.jrxml
---
(0107699)
vmromanos (developer)
2018-10-31 12:34

Code review + testing OK
(0108450)
hudsonbot (developer)
2018-12-11 20:22

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/470e3cd384c5 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2018-10-23 17:05 ngarcia New Issue
2018-10-23 17:05 ngarcia Assigned To => Triage Finance
2018-10-23 17:05 ngarcia Modules => Core
2018-10-23 17:05 ngarcia Triggers an Emergency Pack => No
2018-10-23 17:12 rafaroda Issue Monitored: rafaroda
2018-10-24 08:43 dmiguelez Assigned To Triage Finance => markmm82
2018-10-25 02:08 markmm82 Status new => scheduled
2018-10-25 20:35 markmm82 Note Added: 0107605
2018-10-29 17:21 markmm82 Note Edited: 0107605 View Revisions
2018-10-29 19:19 markmm82 Note Added: 0107645
2018-10-29 19:19 markmm82 Relationship added related to 0027461
2018-10-31 12:34 hgbot Checkin
2018-10-31 12:34 hgbot Note Added: 0107698
2018-10-31 12:34 hgbot Status scheduled => resolved
2018-10-31 12:34 hgbot Resolution open => fixed
2018-10-31 12:34 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/7ba289b96606324c420fcdbc57850f53454de02e [^]
2018-10-31 12:34 vmromanos Review Assigned To => vmromanos
2018-10-31 12:34 vmromanos Note Added: 0107699
2018-10-31 12:34 vmromanos Status resolved => closed
2018-10-31 12:34 vmromanos Fixed in Version => 3.0PR19Q1
2018-12-11 20:22 hudsonbot Checkin
2018-12-11 20:22 hudsonbot Note Added: 0108450


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker