Class: Katello::ContentViewDockerFilterRule
- Includes:
- Katello::Concerns::ContentViewFilterRuleCommon, ScopedSearchExtensions
- Defined in:
- app/models/katello/content_view_docker_filter_rule.rb
Instance Method Summary collapse
Methods inherited from Model
Instance Method Details
#ensure_unique_attributes ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'app/models/katello/content_view_docker_filter_rule.rb', line 13 def ensure_unique_attributes other = self.class.where(:name => self.name, :content_view_filter_id => self.content_view_filter_id) other = other.where.not(:id => self.id) if self.id if other.exists? errors.add(:base, "This docker manifest filter rule already exists.") end end |