Project

General

Profile

Bug #6276

Couldn't update versions for package rules defined under package filters

Added by Brad Buckingham over 6 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Category:
Web UI
Target version:
Difficulty:
easy
Triaged:
Yes
Bugzilla link:
Pull request:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1106378
Description of problem:
I created a package filter and defined a package rule that filter should include a package zsh whose version equal to = '2.2'

Later I tried to update the version from 'Equal To' to 'Greater Than', UI neither saves the changes nor raises any error. Seems like updation is not working.

And production.log is throwing following error:

Processing by Katello::Api::V2::ContentViewFilterRulesController#update as JSON
Parameters: {"id"=>"1", "name"=>"zsh", "created_at"=>"2014-06-09T07:05:51Z", "updated_at"=>"2014-06-09T08:13:40Z", "content_view_filter_id"=>"2", "version"=>"2.2", "type"=>"greater", "editMode"=>true, "min_version"=>"2.2", "working"=>false, "api_version"=>"v2", "content_view_filter_rule"=>{"id"=>"1", "name"=>"zsh", "created_at"=>"2014-06-09T07:05:51Z", "updated_at"=>"2014-06-09T08:13:40Z", "content_view_filter_id"=>"2", "version"=>"2.2", "type"=>"greater", "editMode"=>true, "min_version"=>"2.2", "working"=>false}}
ActiveRecord::RecordInvalid
base: ["Invalid filter rule specified, 'version' cannot be specified in the same tuple as 'min_version' or 'max_version'"]
Completed 422 Unprocessable Entity in 50ms (Views: 0.8ms | ActiveRecord: 2.7ms)

Version-Release number of selected component (if applicable):
sat6 beta snap8 (Satellite-6.0.3-RHEL-6-20140604.0)

How reproducible:
always

Steps to Reproduce:
1. create package filter
2. add rule to filter package with name zsh and version 'Equal To' 2.2
3. now edit this rule and change version 'Greater Than' value '2.2'
4. click save

Actual results:
couldn't update the version of selected package rule. Firebug throws NetworkError.

Expected results:
Either UI should throw proper error or update the version for selected package rule.

Additional info:

Associated revisions

Revision 7e8043b7 (diff)
Added by Brad Buckingham over 6 years ago

fixes #6276 / BZ 1106378 - content view package filter - allow user to change existing rules

Without this change, a user cannot modify a package filter rule, if the
change involves going from an equal filter to greater/less/range filter
(or vice versa).

It also allows a user to 'Edit' the filter and then 'Cancel' returning
the entry to it's previous state.

Revision 4a2e1e23
Added by Brad Buckingham over 6 years ago

Merge pull request #4321 from bbuckingham/issue-6276

fixes #6276 / BZ 1106378 - content view package filter - allow user to change existing rules

History

#1 Updated by Eric Helms over 6 years ago

  • Assignee set to Brad Buckingham
  • Target version set to 48
  • Difficulty set to easy
  • Triaged set to Yes

#2 Updated by Brad Buckingham over 6 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

Applied in changeset katello|commit:7e8043b770a40ee776c8902f46e5e452826d0828.

#3 Updated by Eric Helms over 6 years ago

  • Legacy Backlogs Release (now unused) set to 13

Also available in: Atom PDF