Page MenuHomeIn-Portal Phabricator

MINC-219 - The Debugger JavaScript is present in the Sales Report exported CSV file
AcceptedPublic

Authored by alex on Mon, Feb 9, 4:15 AM.

Details

Reviewers
erik
Test Plan

Test Plan

Preparations

  1. ensure that:
    • Debug Mode is enabled
    • the DBG_TOOLBAR_BUTTONS key of the $dbg_options array in the /system/debug.php file is turned off
  2. apply the patch from the D547 (if not already applied)
  3. login to the Admin Console
  4. go to the Website & ContentStructure & DataProducts section
  5. create a Sub Products category/section
  6. switch to the newly created category/section
  7. create a Type=Service product + Status=Active + Price=15.00 product in it
  8. if the product price wasn't saved, then try editing that product -> specifying a price -> saving it again
  9. go to the User ManagementUsers section
  10. create a Status=Enabled user
  11. go to the E-commerceOrders section
  12. switch to the Incomplete tab
  13. create a new incomplete order:
    • use the above-created user and product
    • fill all required fields on all tabs
  14. on the Incomplete tab:
    • select the newly created sales order
    • press the Place Order toolbar button

Test Plan

  1. login to the Admin Console
  2. go to the E-commerceSales Report section
  3. run the report of each type
  4. do the CSV export from the generated report
  5. confirm that each report has non-zero data displayed
  6. do the export of each report type
  7. confirm that the exported file contents (per-report type) match to data displayed in the report grid (e.g. no Debugger JS as before)

Diff Detail

Repository
rINP In-Portal
Branch
branches/5.2.x
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 11195
Build 3895: arc lint + arc unit

Event Timeline

alex created this revision.Mon, Feb 9, 4:15 AM
alex requested review of this revision.Mon, Feb 9, 4:15 AM
alex edited the test plan for this revision. (Show Details)Mon, Feb 9, 4:19 AM
alex updated this revision to Diff 1444.Mon, Feb 9, 5:01 AM

Perform some minor CS fixes (Boyscout rule).

erik accepted this revision.Mon, Feb 9, 9:32 AM

JS code in the CSV export not detected in both cases - with patch and without patch..

Contents differs un the column names part.

Report "Overall" - differs column name.
In the grid - "GMV", in the CSV - "Amount"

Report "Overall" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "Section Name", in the CSV - "CategoryName".

Report "By User" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "First Name", in the CSV - "FirstName".
In the grid - "Last Name", in the CSV - "LastName".

Report "By Product" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "Name", in the CSV - "Product Name".

This revision is now accepted and ready to land.Mon, Feb 9, 9:32 AM
alex edited the test plan for this revision. (Show Details)Mon, Feb 9, 12:24 PM
alex added a comment.Tue, Feb 10, 4:47 AM

JS code in the CSV export not detected in both cases - with patch and without patch..

I can confirm that Erik doesn't have this bug, but Alex does. The executed code is the same. I guess this has something to do with server configuration.

Contents differs un the column names part.

Report "Overall" - differs column name.
In the grid - "GMV", in the CSV - "Amount"

Report "Overall" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "Section Name", in the CSV - "CategoryName".

Report "By User" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "First Name", in the CSV - "FirstName".
In the grid - "Last Name", in the CSV - "LastName".

Report "By Product" - differs column names.
In the grid - "GMV", in the CSV - "Amount".
In the grid - "Name", in the CSV - "Product Name".

Thank you for the observation. It looks like we're using column:la_fld_FieldName phrase translation in grid, but in export just using FieldName. I've asked Dmitry about this and he confirmed, that this is not a bug.