Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interface assignment get lost after IP address "create and add another" #4629

Closed
JulianJacobi opened this issue May 12, 2020 · 2 comments
Closed
Assignees
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application

Comments

@JulianJacobi
Copy link
Contributor

JulianJacobi commented May 12, 2020

Environment

  • Python version: 3.7 (should be on any)
  • NetBox version: 2.8.3

Steps to Reproduce

  1. Disable any installed plugins by commenting out the PLUGINS setting in
    configuration.py.
  2. Navigate to any device with an interface
  3. Click the + at the and of the interface row in the interface table to add an IP address to an interface
  4. Fill out the form and click "Create and add another"

Expected Behavior

  • Another IP address form with filled out interface assignment appears.
  • interface GET-parameter is set to the appropriate interface-ID.

Observed Behavior

  • Another IP address form without filled out interface assignment appears.
  • interface GET-parameter is missing.

Further information

With the implementation of clone able models in the ObjectEditView.post() function the redirection GET-parameters are build only from clone_fields and other maybe existing GET-parameters are fully ignored.

JulianJacobi added a commit to wobcom/netbox that referenced this issue May 12, 2020
- add get_clone_fields to get clone fields get parameters as QueryDict
- change prepare_clone_fields to use get_clone_fields and build
querystring with urlencode function instead of manual building.
- add non clone_field GET-parameters to params QueryDict on
ObjectEditView.post()

fix netbox-community#4629
@jeremystretch
Copy link
Member

Please specify the exact release on which this issue can be reproduced.

@jeremystretch jeremystretch added the status: revisions needed This issue requires additional information to be actionable label May 13, 2020
@JulianJacobi
Copy link
Contributor Author

The issue first appeared in v2.8.0 but is already there in v2.8.3

@jeremystretch jeremystretch added status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application and removed status: revisions needed This issue requires additional information to be actionable labels May 13, 2020
@jeremystretch jeremystretch self-assigned this May 13, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants