Bug 1641771 - Copying a custom report from a custom report menu changes source report name
Summary: Copying a custom report from a custom report menu changes source report name
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.9.4
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: GA
: 5.9.6
Assignee: Harpreet Kataria
QA Contact: Parthvi Vala
Red Hat CloudForms Documentation
URL:
Whiteboard:
Depends On: 1632847
Blocks: 1622587
TreeView+ depends on / blocked
 
Reported: 2018-10-22 17:04 UTC by Satoe Imaishi
Modified: 2022-07-09 10:14 UTC (History)
6 users (show)

Fixed In Version: 5.9.6.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1632847
Environment:
Last Closed: 2018-12-13 15:15:30 UTC
Category: ---
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2018:3816 0 None None None 2018-12-13 15:15:40 UTC

Comment 3 Parthvi Vala 2018-10-24 09:45:39 UTC
Verified on 5.9.5.3.20181023135339_256263f. FAILED.

With the changes introduced in the PR(https://github.com/ManageIQ/manageiq-ui-classic/pull/4699), it's now possible to add and copy a report with `Add` and `Copy` roles, but copying the report replaces the original report.

Steps taken to verify this BZ:
1) Navigate to Configuration > Access Control.
2) Create role `Role-reporting` with `Add` and `Copy` roles for `Reports`.
3) Create a group `Group-reporting` with `Role-reporting` role.
4) Create a user `Test RBAC User` which is part of `Group-reporting` and Super administrator groups.
5) Login with the new user. Check the group after login, it should be `Role-reporting`.
6) Navigate to Cloud Intel > Reports.
7) Click on `Configuration`, select `Add a new Report` and add the new report.[Thus, verifying `Add` role change.]
8) Navigate to `Edit Report Menus` accordion.
9) Create a new menu `My` and a sub-menu `Reports` under it. Move the newly created report to this sub-menu. Commit and Save the new changes.
10) Refresh the browser and see if the new changes are reflected.
11) Select the newly moved report under `My / Reports` menu.
12) Click on `Configuration` and select `Copy this Report`.
13) Make some changes to the report if required and save the report.[Thus verifying `Copy` role change.]
14) Refresh the browser.
15) Observe `My / Reports` menu. The old report is replaced by the newly copied report.

Check Video attachment for better understanding.

Conclusion:
Copying a custom report from custom report menu doesn't just change the name of that report, but replaces the whole report from under the menu.


Failing this BZ.

Comment 7 CFME Bot 2018-10-25 10:11:38 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/fc669afde15b06b3c12e5bb8f6502c0cd73ef3ba
commit fc669afde15b06b3c12e5bb8f6502c0cd73ef3ba
Author:     Harpreet Kataria <hkataria>
AuthorDate: Wed Oct 24 15:00:22 2018 -0400
Commit:     Harpreet Kataria <hkataria>
CommitDate: Wed Oct 24 15:00:22 2018 -0400

    Only update report name in group reports menu when editing a report

    Only update report name for user's group menu when editing an existing report. Since report are saved by name in user's group record for menus, updating report name while copying a report was causing an issue of showing incorrect reports in user created custom folders. Newly added and copied reports by default get added into My Company/Custom folder.

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1641771

 app/controllers/report_controller/reports/editor.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 9 CFME Bot 2018-11-05 17:28:04 UTC
New commit detected on ManageIQ/manageiq-ui-classic/gaprindashvili:

https://github.com/ManageIQ/manageiq-ui-classic/commit/0e644ab3961ab4e76c5bae2cea19c88ea302cc2b
commit 0e644ab3961ab4e76c5bae2cea19c88ea302cc2b
Author:     Milan Zázrivec <mzazrivec>
AuthorDate: Thu Oct 25 06:08:31 2018 -0400
Commit:     Milan Zázrivec <mzazrivec>
CommitDate: Thu Oct 25 06:08:31 2018 -0400

    Merge pull request #4824 from h-kataria/fix_copying_of_report

    Only update report name in group reports menu when editing a report

    (cherry picked from commit c0034b914089ccdf8eead1906283cd28e4e25ba2)

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1641771

 app/controllers/report_controller/reports/editor.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 10 Parthvi Vala 2018-11-08 07:33:30 UTC
FIXED. Verified on 5.9.6.0.20181105224828_652732b.

Comment 12 errata-xmlrpc 2018-12-13 15:15:30 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:3816


Note You need to log in before you can comment on or make changes to this bug.