Bug 1102451 - content view filters controller does not honor name parameter
Summary: content view filters controller does not honor name parameter
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: API
Version: 6.0.3
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: Unspecified
Assignee: Christine Fouant
QA Contact: Ales Dujicek
URL: http://projects.theforeman.org/issues...
Whiteboard:
: 1099974 1101689 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-05-29 01:41 UTC by Justin Sherrill
Modified: 2019-09-25 20:32 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-07-02 14:05:07 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 6064 0 None None None 2016-04-22 16:46:24 UTC

Description Justin Sherrill 2014-05-29 01:41:12 UTC
Description of problem:

Currently the content view filters controller does not honor hte name parameter.  

Using hammer you can reproduce this issue:

hammer content-view filter create --organization=Example_Org1  --content-view=SOE-OS  --type=erratum --name='Restrict Errata'  --inclusion=false  
hammer content-view filter create --organization=Example_Org1  --content-view=SOE-OS  --type=erratum --name='Restrict Errata2'  --inclusion=false  
hammer content-view filter rule create --content-view=SOE-OS  --content-view-filter='Restrict Errata'     --organization=Example_Org1  --start-date=2013-11-20


will result in:

  Error: content_view_filter found more than once

Comment 2 Bryan Kearney 2014-06-03 17:47:45 UTC
This requires a change to the index method of the content views controller. Look at the products index controller on how it accepts     

param :name, String, :desc => N_("Filter products by name")

Comment 3 Bryan Kearney 2014-06-03 18:35:38 UTC
*** Bug 1101689 has been marked as a duplicate of this bug. ***

Comment 4 Bryan Kearney 2014-06-03 21:08:58 UTC
*** Bug 1099974 has been marked as a duplicate of this bug. ***

Comment 5 Christine Fouant 2014-06-04 15:38:49 UTC
Created redmine issue http://projects.theforeman.org/issues/6064 from this bug

Comment 6 Bryan Kearney 2014-06-05 19:49:28 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/6064 has been closed

Comment 9 Ales Dujicek 2014-06-16 14:26:31 UTC
Still cannot handle content view filter by name.
Now it is: Error: content_view_filter not found

# hammer content-view filter info --organization-id 284 --content-view cont-view --id 6
Filter ID:    6
Name:         Restrict
Type:         erratum
Inclusion:    false
Repositories: 

Rules:

# hammer content-view filter info --organization-id 284 --content-view cont-view --name Restrict
Error: content_view_filter not found

# hammer content-view filter rule create --content-view cont-view --content-view-filter Restrict --organization-id 284 --start-date=2013-11-20 
Could not create the filter rule:
  Error: content_view_filter not found

Comment 10 Bryan Kearney 2014-06-19 02:03:42 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/6064 has been closed

Comment 13 Ales Dujicek 2014-06-23 12:26:14 UTC
Verified. Satellite-6.0.3-RHEL-6-20140620.0

# hammer content-view filter rule create --content-view=SOE-OS  --content-view-filter='Restrict Errata'     --organization=Example_Org1  --start-date=2013-11-20
Filter rule created

# hammer content-view filter info --organization-id 4 --content-view SOE-OS --id 1
Filter ID:    1
Name:         Restrict Errata
Type:         erratum
Inclusion:    false
Repositories: 

Rules:        
 1) ID:         1
    Start Date: 2013-11-20
    Created:    2014/06/23 12:16:50
    Updated:    2014/06/23 12:16:50

Comment 14 Bryan Kearney 2014-07-02 14:05:07 UTC
This was delivered with 6.0.3, which is the Satellite 6 Beta.


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