[PR #18607] [MERGED] Fixes 18555: Fix model URL generator for plugins #15394

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

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/18607
Author: @alehaa
Created: 2/8/2025
Status: Merged
Merged: 2/18/2025
Merged by: @jeremystretch

Base: mainHead: 18555-model-url


📝 Commits (7)

  • bb3b933 Fix model URL generator for plugins
  • f07642b Fix reverse accessor warning
  • 1f07b07 Revert "Fix reverse accessor warning"
  • 8b0af50 Add URL test case for regular models
  • 2a6702e Split dummy models
  • 2f1b66b Fix filterset test case error
  • 9aaa244 Rename test module

📊 Changes

7 files changed (+82 additions, -2 deletions)

View changed files

📝 netbox/extras/tests/test_filtersets.py (+1 -0)
📝 netbox/netbox/models/__init__.py (+2 -1)
netbox/netbox/tests/dummy_plugin/migrations/0002_dummynetboxmodel.py (+30 -0)
📝 netbox/netbox/tests/dummy_plugin/models.py (+6 -0)
📝 netbox/netbox/tests/dummy_plugin/urls.py (+2 -0)
📝 netbox/netbox/tests/dummy_plugin/views.py (+18 -1)
netbox/netbox/tests/test_models.py (+23 -0)

📄 Description

Fixes: #18555

The default get_absolute_url() implementation can now return the URL for plugins.


🔄 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/18607 **Author:** [@alehaa](https://github.com/alehaa) **Created:** 2/8/2025 **Status:** ✅ Merged **Merged:** 2/18/2025 **Merged by:** [@jeremystretch](https://github.com/jeremystretch) **Base:** `main` ← **Head:** `18555-model-url` --- ### 📝 Commits (7) - [`bb3b933`](https://github.com/netbox-community/netbox/commit/bb3b9331155f746580177272eb1322a64caaebc0) Fix model URL generator for plugins - [`f07642b`](https://github.com/netbox-community/netbox/commit/f07642bb997910205d0acc09fc8df3dde30c7981) Fix reverse accessor warning - [`1f07b07`](https://github.com/netbox-community/netbox/commit/1f07b07bf7ac18075ed06a0c1ae3683495b56f9c) Revert "Fix reverse accessor warning" - [`8b0af50`](https://github.com/netbox-community/netbox/commit/8b0af50019fa5f197d5901d95190111ed8ea215c) Add URL test case for regular models - [`2a6702e`](https://github.com/netbox-community/netbox/commit/2a6702e88baf11521ecf03c8365a13dd4c5dd0ca) Split dummy models - [`2f1b66b`](https://github.com/netbox-community/netbox/commit/2f1b66b12e69261a27acbac388083f8e78ebafbd) Fix filterset test case error - [`9aaa244`](https://github.com/netbox-community/netbox/commit/9aaa2449037f5ac7d67c11979cc0a8b799bbd0b6) Rename test module ### 📊 Changes **7 files changed** (+82 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `netbox/extras/tests/test_filtersets.py` (+1 -0) 📝 `netbox/netbox/models/__init__.py` (+2 -1) ➕ `netbox/netbox/tests/dummy_plugin/migrations/0002_dummynetboxmodel.py` (+30 -0) 📝 `netbox/netbox/tests/dummy_plugin/models.py` (+6 -0) 📝 `netbox/netbox/tests/dummy_plugin/urls.py` (+2 -0) 📝 `netbox/netbox/tests/dummy_plugin/views.py` (+18 -1) ➕ `netbox/netbox/tests/test_models.py` (+23 -0) </details> ### 📄 Description <!-- Thank you for your interest in contributing to NetBox! Please note that our contribution policy requires that a feature request or bug report be approved and assigned prior to opening a pull request. This helps avoid waste time and effort on a proposed change that we might not be able to accept. IF YOUR PULL REQUEST DOES NOT REFERENCE AN ISSUE WHICH HAS BEEN ASSIGNED TO YOU, IT WILL BE CLOSED AUTOMATICALLY. Please specify your assigned issue number on the line below. --> ### Fixes: #18555 <!-- Please include a summary of the proposed changes below. --> The default `get_absolute_url()` implementation can now return the URL for plugins. --- <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:21:40 +01:00
adam closed this issue 2025-12-30 00:21:40 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#15394