[PR #19994] [MERGED] Fixes #19987: Show changelog_message field only for models which support change logging #15788

Closed
opened 2025-12-30 00:24:04 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/19994
Author: @jeremystretch
Created: 7/31/2025
Status: Merged
Merged: 8/1/2025
Merged by: @jeremystretch

Base: featureHead: 19987-delete-forms-changelog


📝 Commits (1)

  • 5ae435c Fixes #19987: Show changelog_message field only for models which support change logging

📊 Changes

10 files changed (+66 additions, -50 deletions)

View changed files

📝 netbox/dcim/forms/bulk_edit.py (+2 -2)
📝 netbox/dcim/forms/model_forms.py (+2 -2)
📝 netbox/extras/forms/bulk_edit.py (+11 -11)
📝 netbox/extras/forms/model_forms.py (+10 -10)
📝 netbox/netbox/forms/base.py (+3 -3)
📝 netbox/netbox/forms/mixins.py (+2 -2)
📝 netbox/netbox/views/generic/bulk_views.py (+3 -16)
📝 netbox/netbox/views/generic/object_views.py (+2 -2)
📝 netbox/utilities/forms/bulk_import.py (+2 -2)
📝 netbox/utilities/forms/forms.py (+29 -0)

📄 Description

Fixes: #19987

  • Rename the ChangeLoggingMixin form mixin to ChangelogMessageMixin to avoid confusion
  • Move BulkDeleteForm to a proper class, defined outside the view
  • Alter signature of DeleteForm to support passing a model instance
  • Alter signature of BulkDeleteForm to require passing a model class
  • Tweak both forms to omit the changelog_message field is the associated model does not support change logging

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbox-community/netbox/pull/19994 **Author:** [@jeremystretch](https://github.com/jeremystretch) **Created:** 7/31/2025 **Status:** ✅ Merged **Merged:** 8/1/2025 **Merged by:** [@jeremystretch](https://github.com/jeremystretch) **Base:** `feature` ← **Head:** `19987-delete-forms-changelog` --- ### 📝 Commits (1) - [`5ae435c`](https://github.com/netbox-community/netbox/commit/5ae435cb43fad1f6ccd26772521fbc86deced5f7) Fixes #19987: Show changelog_message field only for models which support change logging ### 📊 Changes **10 files changed** (+66 additions, -50 deletions) <details> <summary>View changed files</summary> 📝 `netbox/dcim/forms/bulk_edit.py` (+2 -2) 📝 `netbox/dcim/forms/model_forms.py` (+2 -2) 📝 `netbox/extras/forms/bulk_edit.py` (+11 -11) 📝 `netbox/extras/forms/model_forms.py` (+10 -10) 📝 `netbox/netbox/forms/base.py` (+3 -3) 📝 `netbox/netbox/forms/mixins.py` (+2 -2) 📝 `netbox/netbox/views/generic/bulk_views.py` (+3 -16) 📝 `netbox/netbox/views/generic/object_views.py` (+2 -2) 📝 `netbox/utilities/forms/bulk_import.py` (+2 -2) 📝 `netbox/utilities/forms/forms.py` (+29 -0) </details> ### 📄 Description ### Fixes: #19987 - Rename the ChangeLoggingMixin _form_ mixin to ChangelogMessageMixin to avoid confusion - Move BulkDeleteForm to a proper class, defined outside the view - Alter signature of DeleteForm to support passing a model instance - Alter signature of BulkDeleteForm to require passing a model class - Tweak both forms to omit the `changelog_message` field is the associated model does not support change logging --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-30 00:24:04 +01:00
adam closed this issue 2025-12-30 00:24:05 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#15788