Bug 1349894

Summary: All datastores add clear link after advanced search open and close
Product: Red Hat CloudForms Management Engine Reporter: Matouš Mojžíš <mmojzis>
Component: UI - OPSAssignee: Eric Hayes <ehayes>
Status: CLOSED CURRENTRELEASE QA Contact: Matouš Mojžíš <mmojzis>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.6.0CC: dajohnso, dclarizi, hkataria, jhardy, mpovolny, obarenbo, simaishi
Target Milestone: GAKeywords: TestOnly, ZStream
Target Release: 5.7.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: ui:search
Fixed In Version: 5.7.0.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1353300 (view as bug list) Environment:
Last Closed: 2017-01-11 20:17:06 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1353300    

Description Matouš Mojžíš 2016-06-24 13:10:57 UTC
Description of problem:


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

How reproducible:
Always

Steps to Reproduce:
1. Compute -> Infrastructure -> Datastores
2. Select a filter and click on clear
3. Now in All datastores Datastores select advanced search 
4. Exit that advanced search

Actual results:
Clear link appears next to All datastores Datastores

Expected results:
No clear button should appear

Additional info:

Comment 2 Harpreet Kataria 2016-06-27 17:38:30 UTC
Eric,

Can you investigate and see what is making "Clear" link to appear even when user has not applied any filters. Can you check to see if same issue exists on any of the other list views.

Thanks,
~Harpreet

Comment 3 Eric Hayes 2016-06-27 22:55:56 UTC
My current theory is that the filters are not properly cleared after step 2. Then the clear_search_show_or_hide method is returning true here: https://github.com/ManageIQ/manageiq/blob/master/app/controllers/application_controller/filter.rb#L468 —causing the clear_search link to appear.

I could not reproduce it on other list views with advanced search. Investigating whether the answer lies in one of these other views.

Comment 5 CFME Bot 2016-07-05 21:46:19 UTC
New commit detected on ManageIQ/manageiq/master:
https://github.com/ManageIQ/manageiq/commit/308143763c529325973e6549c1f23801151f4fb8

commit 308143763c529325973e6549c1f23801151f4fb8
Author:     Eric Hayes <eric>
AuthorDate: Tue Jun 28 10:13:55 2016 -0700
Commit:     Eric Hayes <eric>
CommitDate: Tue Jun 28 10:46:08 2016 -0700

    Properly clear search for Datastores filters
    
    Addresses:
    https://bugzilla.redhat.com/show_bug.cgi?id=1349894
    https://bugzilla.redhat.com/show_bug.cgi?id=1349888

 app/controllers/application_controller/filter.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comment 7 Matouš Mojžíš 2016-09-30 13:44:06 UTC
Verified in 5.7.0.3. No clear link appeared.