Bug 1404463 - Title contains compressed string on Container Image Control Policy page
Summary: Title contains compressed string on Container Image Control Policy page
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.7.0
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: GA
: 5.10.0
Assignee: Nimrod Shneor
QA Contact: Einat Pacifici
URL:
Whiteboard: ui:control:container
Depends On:
Blocks: 1397248 1511521
TreeView+ depends on / blocked
 
Reported: 2016-12-13 22:10 UTC by Nandini Chandra
Modified: 2018-06-21 20:38 UTC (History)
8 users (show)

Fixed In Version: 5.10.0.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1511521 (view as bug list)
Environment:
Last Closed: 2018-06-21 20:38:36 UTC
Category: ---
Cloudforms Team: Container Management
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
screen shot of Container Image policy image with compressed string. (139.44 KB, image/png)
2016-12-13 22:10 UTC, Nandini Chandra
no flags Details

Description Nandini Chandra 2016-12-13 22:10:28 UTC
Created attachment 1231343 [details]
screen shot of Container Image policy image with compressed string.

Description of problem:
-----------------------
See attached screen shot.The title reads 'Containerimage Control Policy...'
instead of 'Container Image Control Policy...'


Version-Release number of selected component (if applicable):
--------------------------------
5.7.0.14


How reproducible:
----------------
Always


Steps to Reproduce:
-------------------
1.Navigate to the Control -> Explorer page.
2.From the 'Events' accordion, click any event already assigned to a Control Policy.Eg: Click the "Container Image Analysis Complete" event.Click the policy link in the 'Assigned to Policies' section.


Actual results:
--------------
Title contains compressed string on Container Image Control Policy page.
 

Expected results:
-----------------
Title shouldn't contain compressed string.


Additional info:
----------------

Comment 2 Beni Paskin-Cherniavsky 2016-12-14 12:31:07 UTC
Good catch!
Found the problematic view code, and several more like it e.g. Actions -> Initiate SmartState Analysis for Container Image -> assigned policy title.
Will give details list after I fix them.

These are all manifestation of the bug 1359909 class of bugs.
(Proposing 5.7.z? as was decided there.)
But that BZ has been re-opened too many times and is becoming impossible to understand what exactly should be verified.
QE, feel free to dup to 1359909 if you do prefer one mega-BZ.

This area definitely needs more unit tests, and less code duplication.  Discussing approaches with UI team...

Comment 3 Beni Paskin-Cherniavsky 2017-01-12 15:12:33 UTC
Status: I know how to proceed but didn't have time to start coding.

The reason these bugs repeatedly come up is the logic is replicated in too many places.  I already did several rounds of "fixed them all", and then other places still fail - this time in views.
Chatted with Martin Hradil, I'm going to centralize nodeid computation (the "xx-control_xx-..." strings) in corresponding TreeBuilder classes where it can be shared between controller and views.

Comment 4 Federico Simoncelli 2017-01-27 14:09:01 UTC
Beni is this fixed by:

https://github.com/ManageIQ/manageiq-ui-classic/pull/256

If so, can you move to POST?

Comment 5 Beni Paskin-Cherniavsky 2017-02-06 12:30:41 UTC
No, that only fixed a couple places.
I still see 4 `towhat.downcase` under app/views/miq_policy/ — at least 3 of these are bugs, other `downcase` uses there also need to be checked.

That's why I really want to refactor these and controllers to use common helper(s).

Comment 9 Federico Simoncelli 2017-06-05 21:06:18 UTC
What's the status on this?

Comment 10 Nimrod Shneor 2017-06-06 06:20:10 UTC
This is open since me and beni wanted to refactor tree_builder_policy but I never got around to do that...

Comment 11 Federico Simoncelli 2017-08-28 07:51:08 UTC
Nimrod if there are no PRs addressing this please move the Status back to "ASSIGNED" (or add a link to the code). Thanks.

Comment 12 Nimrod Shneor 2017-11-06 14:40:09 UTC
PR: https://github.com/ManageIQ/manageiq-ui-classic/pull/2639


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