* fixes client ip detection for v6
* adds test for get_client_ip
* Employ urlparse() to strip port numbers from IPs
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* initial work to render hierarchical region #13735
* adds site display #13735
* cleanup #13735
* adds display region tag #13735
* refactored region hierarchy #13735
* refactored region hierarchy #13735
* renamed display_region to nested_tree #13735
* Make render_tree suitable for generic use
* Remove errant item from __all__
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Fixed password was not hashed on REST API update
* When we updated a user password with a REST API call the password was
stored in clear in plain text in the database.
* Following code review
* Move test on UserTest class
* Call `super().update()` in overriding `update` method
* Return directly the result of `super().update()`
In PR #13958 (commit 8224644) _get_report was modified to do the call on the variable without changing the call later on.
This commit fixes that and removes the call on the variable.
Signed-off-by: Josef Johansson <josef@oderland.se>
* Move L2VPN and L2VPNTermination models from ipam to vpn
* Move L2VPN resources from ipam to vpn
* Extend migration to update content types
* Misc cleanup
- Introduces a new `vpn` app with the following models:
- Tunnel
- TunnelTermination
- IKEProposal
- IKEPolicy
- IPSecProposal
- IPSecPolicy
- IPSecProfile
* Move ConfigRevision model & write migrations
* Move ConfigRevision resources from extras to core
* Extend migration to update original content type for ConfigRevision
* 8356 add virtual disk model
* 8356 add supplemental forms
* 8356 add menu
* 8356 cleanup views
* 8356 virtual machine tab
* 8356 migrations
* 8356 vm disk tables
* 8356 cleanup
* 8356 graphql
* 8356 graphql
* 8356 add components button
* 8356 bulk add on virtualmachine
* 8356 bulk add fixes
* 8356 api tests
* 8356 news tests add rename
* 8356 VirtualDiskCreateForm
* 8356 fix test
* 8356 add todo to remove disk from vm
* 8356 review changes
* 8356 fix test
* 8356 deprecate disk field
* 8356 review changes
* 8356 fix test
* 8356 fix test
* Simplify view actions
* 8356 review changes
* 8356 split trans tag
* 8356 add total virtual disk size to api
* 8356 add virtual disk list to virtual machine detail view
* 8356 move virtual disk size to property
* 8356 revert property
* Tweak display of deprecated disk field
* 8356 render single disk field
* 8356 update serializer
* 8356 model property
* 8356 fix test
* 8356 review changes
* Revert disk space annotation
* Use existing disk field to store aggregate virtual disk size
* Introduce abstract ComponentModel for VM components
* Add search index for VirtualDisk
* Misc cleanup
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Closes#13794: Dynamically populate related objects list under tenant view
* get_related_models() should sort models alphabetically by default
* Reference Meta.related_objects instead of calling get_fields()
* WIP
* Add display_attrs for all indexers
* Linkify object attributes
* Clean up prefetch logic
* Use tooltips for display attributes
* Simplify template code
* Introduce get_indexer() utility function
* Add to examples in docs
* Use tooltips to display long strings
* adds unit to the power port draw #13587
* review changes #13587
* moved units to header #13587
* Abbreviate unit for consistency with e.g. PowerFeedTable available_power column
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Add primary_ip4 and primary_ip6 filters for VirtualMachine and VirtualDeviceContext filtersets (#13936)
* Add PrimaryIPFilterSet to __all__
---------
Co-authored-by: Artem I. Kotik <artem.i.kotik@ringcentral.com>
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Add manufacturer for filters in the virtual machine and device #12741
* reverse the filtersets of device and vm
* revert the filtersets of vm
* add advance selector in platform
* remove manufacture from imports
* show objects that would be deleted by cascade
* some items were not showing (eg ips on devices)
* dont include the item being deleted in the list of related items
* Revert "dont include the item being deleted in the list of related items"
This reverts commit 298a7860b2.
* cleanup
- migrate code to use collector directly instead of the NestedObjects wrapper from admin.utils
- adjust object names and text output
* requested adjustments
* remove comma from end of list
* linting
* refactor, add accordion
* migrate to defaultdict, use title for capitalisation of accordian titles
* Misc cleanup
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Closes#12135: Prevent the deletion of interfaces with children
* Change PROTECT to RESTRICT
* Extend handle_protectederror() to also handle RestrictedError
* Fix string translation
* Update migrations
* Support bulk removal of parent interfaces via UI if all children are included
* Add support for the bulk deletion of restricted objects via REST API
* Initial work on #13381
* Fix backend type display in table column
* Fix data source type choices during bulk edit
* Misc cleanup
* Move backend utils from core app to netbox
* Move backend type validation from serializer to model
* 13230 add exclusion flag to device type
* 13230 forms, detail views
* 13230 add tests
* 13230 extraneous model field
* 13230 extraneous form field
* Update netbox/dcim/forms/bulk_edit.py
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* 13230 review feedback
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* 12216 add color to model
* 12216 add forms, serializers for color
* 12216 color to detail view, add type to svg
* 12216 add color to svg
* 12216 review changes
* Move extras.plugins to netbox.plugins & add deprecation warnings
* Move plugin template tags from extras to utilities
* Move plugins tests from extras to netbox
* Add TODO reminders for v4.0
* 14025 fix script name checking
* 14025 fix script name checking
* 14025 add file extension validation and simplify get logic
* 14025 match start of string with regex
* 14025 backout changes to model_forms
* 14025 add filepatch checking to reports
* Catch AssertionError's in signals. Handle accordingly
* Alter cable logic to handle certain additional path types.
* Fix failures and add test
* More tests
* Remove not needed tests, add additional tests
* Finish tests, correct some behaviour
* Add check for mid-span device not allowed condition
* Remove excess import
* Remove logging import
* Remove logging import
* Minor tweaks based on Arthur's feedback
* Update netbox/dcim/tests/test_cablepaths.py
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Update netbox/dcim/models/cables.py
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Changes to account for required SVG rendering changes and based on feedback
* More tweaks for cable path checking
* Improve handling of links with multi-terminations
* Improved SVG rendering of multiple rear ports (with positions) per path trace. Include asymmetric path detection
* Include missing assert to ensure links are same type.
* Clean up tests
* Remove unused objects from tests
* Changes requested to tests and update comments/doctstrings
* Fix parent reference
---------
Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
* Update VLANGroup bulk edit form to support all scope types
* Fixes#13843: Fix scope assignment for VLAN groups during bulk edit
* Add missed static file
* Restore graphiql static assets