[PR #18602] [MERGED] Fixes: 18593 - "Create & Add Another" broken for new IP addresses #15389

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

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/18602
Author: @renatoalmeidaoliveira
Created: 2/7/2025
Status: Merged
Merged: 2/11/2025
Merged by: @jeremystretch

Base: mainHead: 18593-Create_and_add_another_fix


📝 Commits (2)

  • bea5373 update IPAddressEditView get_extra_addanother_params
  • a682351 Simplify get_extra_addanother_params

📊 Changes

1 file changed (+1 additions, -0 deletions)

View changed files

📝 netbox/ipam/views.py (+1 -0)

📄 Description

Fixes: #18593 - "Create & Add Another" broken for new IP addresses

  • Changes IPAddressEditView's get_extra_addanother_params to return super().get_extra_addanother_params(request) when the GET params interface or vminterface

Its also possible to solve this issue returning {} if there aren't any match in the if clauses, IMO returning super().get_extra_addanother_params(request) could be more flexible in the future.
Please let me know if you prefer to use another approach.


🔄 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/18602 **Author:** [@renatoalmeidaoliveira](https://github.com/renatoalmeidaoliveira) **Created:** 2/7/2025 **Status:** ✅ Merged **Merged:** 2/11/2025 **Merged by:** [@jeremystretch](https://github.com/jeremystretch) **Base:** `main` ← **Head:** `18593-Create_and_add_another_fix` --- ### 📝 Commits (2) - [`bea5373`](https://github.com/netbox-community/netbox/commit/bea5373b78c8de6aa482e049883e1164258494c5) update IPAddressEditView get_extra_addanother_params - [`a682351`](https://github.com/netbox-community/netbox/commit/a682351e587859ab3626ebc9914b0b61001a0464) Simplify get_extra_addanother_params ### 📊 Changes **1 file changed** (+1 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `netbox/ipam/views.py` (+1 -0) </details> ### 📄 Description ### Fixes: #18593 - "Create & Add Another" broken for new IP addresses * Changes IPAddressEditView's get_extra_addanother_params to return `super().get_extra_addanother_params(request)` when the GET params `interface` or `vminterface` Its also possible to solve this issue returning `{}` if there aren't any match in the if clauses, IMO returning `super().get_extra_addanother_params(request)` could be more flexible in the future. Please let me know if you prefer to use another approach. --- <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:38 +01:00
adam closed this issue 2025-12-30 00:21:39 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#15389