Actions
Bug #39419
closedCVECF priorities not set during initial host registration
Status:
Duplicate
Priority:
Normal
Assignee:
-
Category:
Content Views
Target version:
-
Description
When a host is first registered with multiple content view environments, all CVECF records get priority: 0. The content_view_environments= setter calls reprioritize_for_content_facet
immediately after super, but for a new (unsaved) content facet, the CVECF join records only exist in memory — not in the database. Since reprioritize_for_content_facet uses find_by (a
database query), it finds nothing and sets no priorities. When content_facet.save! runs later in populate_content_facet, all CVECFs are persisted with the default priority of 0.
Fix: Call reprioritize_for_content_facet again in populate_content_facet after content_facet.save! when the content facet was a new record.
Updated by Ian Ballou 2 months ago
- Target version set to Katello 4.21.1
- Triaged changed from No to Yes
Updated by Pavan Soma Shekar 8 days ago
- Status changed from New to Duplicate
Closing this as duplicate. Refer to https://projects.theforeman.org/issues/39503
Actions