Bug 1247984

Summary: [RFE] Bookmark searches should only need to be unique within their controller
Product: Red Hat Satellite Reporter: Maxim Burgerhout <mburgerh>
Component: WebUIAssignee: alon <agoldboi>
WebUI sub component: Foreman QA Contact: Roman Plevka <rplevka>
Status: CLOSED ERRATA Docs Contact:
Severity: medium    
Priority: unspecified CC: bbuckingham, cwelton, fsimonce, rplevka
Version: 6.1.0Keywords: FutureFeature, Triaged
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
URL: http://projects.theforeman.org/issues/11451
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-27 08:54:21 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Maxim Burgerhout 2015-07-29 11:44:34 UTC
Description of problem:
In Satellite 6, I can bookmark searches. These bookmarked search are coupled to a controller in which they are available.

I can make a search in the puppetclasses controller named 'ntp' for example, to search for the ntp class. The fact that the name of the bookmarked search needs to be globally unique means that I cannot create another bookmarked search for the lookup_keys controller named 'ntp' (which I'll probably want to do, since it's similar content as puppetclasses).

Version-Release number of selected component (if applicable):
foreman-1.7.2.32-1.el7sat.noarch

How reproducible:


Steps to Reproduce:
1. Create bookmarked search called 'ntp' in puppetclasses controller
2. Try to create a bookmarked search in another controller with the same name
3.

Actual results:
Cannot save second search

Expected results:
Bookmarked search should only need to be unique within the context of a single controller. Then I could save a second bookmarked search in the lookup_keys controller called 'ntp' as well.

Additional info:

Comment 1 alon 2015-08-23 12:31:56 UTC
Created redmine issue http://projects.theforeman.org/issues/11451 from this bug

Comment 3 Bryan Kearney 2015-08-25 14:06:02 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/11451 has been closed
-------------
Alon Goldboim
Applied in changeset commit:a5a7bc71980454ae17c0eb43253276acb3a01910.

Comment 6 Roman Plevka 2016-04-22 10:08:15 UTC
VERIFIED
on sat 6.2.0 snap 9.0

# curl -u admin:changeme -H 'Content-Type: application/json' -d '{"name": "test", "query":"foo", "controller": "puppetclasses"}' 'https://sat6.com/api/v2/bookmarks'
{"name":"test","controller":"puppetclasses","query":"foo","public":null,"id":22,"owner_id":3,"owner_type":"User"}

# curl -u admin:changeme -H 'Content-Type: application/json' -d '{"name": "test", "query":"foo", "controller": "users"}' 'https://sat6.com/api/v2/bookmarks'
{"name":"test","controller":"users","query":"foo","public":null,"id":23,"owner_id":3,"owner_type":"User"}

verified also via UI

Comment 8 errata-xmlrpc 2016-07-27 08:54:21 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/RHBA-2016:1500