Update adding-models.md to reflect recent changes to get_absolute_url #10412

Closed
opened 2025-12-29 21:31:08 +01:00 by adam · 0 comments
Owner

Originally created by @bctiemann on GitHub (Oct 28, 2024).

Originally assigned to: @bctiemann on GitHub.

Proposed Changes

Now that get_absolute_url has been defined in NetBoxFeatureSet, we should update adding-models.md to reflect the recommended pattern (you don't need to add your own method unless nonstandard functionality is needed).

Also add a relevant note about GraphQL unit tests possibly failing when related objects are prefetched.

Justification

The current docs are misleading in the current reality and could lead a developer to add a redundant get_absolute_url method.

Originally created by @bctiemann on GitHub (Oct 28, 2024). Originally assigned to: @bctiemann on GitHub. ### Proposed Changes Now that `get_absolute_url` has been defined in `NetBoxFeatureSet`, we should update adding-models.md to reflect the recommended pattern (you don't need to add your own method unless nonstandard functionality is needed). Also add a relevant note about GraphQL unit tests possibly failing when related objects are prefetched. ### Justification The current docs are misleading in the current reality and could lead a developer to add a redundant `get_absolute_url` method.
adam added the status: acceptedtype: housekeepingnetbox labels 2025-12-29 21:31:08 +01:00
adam closed this issue 2025-12-29 21:31:09 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#10412