Bug 1552747 - Error when applying a filter in My Services from Adv search
Summary: Error when applying a filter in My Services from Adv search
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.9.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: GA
: 5.10.0
Assignee: Oleg Barenboim
QA Contact: Niyaz Akhtar Ansari
URL:
Whiteboard:
Depends On:
Blocks: 1552762
TreeView+ depends on / blocked
 
Reported: 2018-03-07 16:28 UTC by Hilda Stastna
Modified: 2019-02-11 14:09 UTC (History)
5 users (show)

Fixed In Version: 5.10.0.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1552762 (view as bug list)
Environment:
Last Closed: 2019-02-11 14:09:48 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Actual result - Adv Search remains open (177.82 KB, image/png)
2018-03-07 16:28 UTC, Hilda Stastna
no flags Details
Expected result - Adv Search closed and filter applied (102.01 KB, image/png)
2018-03-07 16:30 UTC, Hilda Stastna
no flags Details

Description Hilda Stastna 2018-03-07 16:28:41 UTC
Created attachment 1405455 [details]
Actual result - Adv Search remains open

Description of problem:
There is an error when clicking on Apply button in Adv search in My Services page when applying a loaded filter. The filter does not apply successfully. After closing Advanced search, no filter is applied on services and Search with Advanced search are missing in the page.

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

How reproducible:
100%

Steps to Reproduce:
1. Go to Services -> My Services (you can see Active services)
2. Open Advanced search and create a filter if no filter exists
3. Click on Load button in Adv search to load some existing filter; choose some filter
4. Click on Load again and you should now see: Service search "..." was successfully loaded
5. Click on Apply button

Actual results:
Error occurs in log and the Adv search window remains open with no change!

Expected results:


Additional info:
[1] pry(#<ServiceController>)> 
F, [2018-01-15T17:34:57.696713 #24064] FATAL -- : Error caught: [NoMethodError] undefined method `+' for nil:NilClass
/home/hstastna/manageiq/manageiq-ui-classic/app/controllers/service_controller.rb:328:in `get_node_info'
/home/hstastna/manageiq/manageiq-ui-classic/app/controllers/service_controller.rb:397:in `replace_right_cell'
/home/hstastna/manageiq/manageiq-ui-classic/app/controllers/application_controller/advanced_search.rb:145:in `adv_search_button_apply'
/home/hstastna/manageiq/manageiq-ui-classic/app/controllers/application_controller/advanced_search.rb:254:in `adv_search_button'

When adv_search_button_apply method is called, x_node is changed to "root" node because we are in explorer screen. BUT there is no root node in My Services! So then @right_cell_text is nil (and it shouldn't be) so it throws an error.
The issue is not present if you apply a filter by clicking on a name of the filter from accordion.

Comment 2 Hilda Stastna 2018-03-07 16:29:15 UTC
fixing https://github.com/ManageIQ/manageiq-ui-classic/pull/3255

Comment 3 Hilda Stastna 2018-03-07 16:30:30 UTC
Created attachment 1405456 [details]
Expected result - Adv Search closed and filter applied

Comment 5 Niyaz Akhtar Ansari 2018-10-08 06:57:31 UTC
Verified in Version 5.10.0.18.20181003162715_dfcff5a


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