1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

636 Commits

Author SHA1 Message Date
94c31622ac 15588 set readonly nullable fields as allow_null=True 2024-04-19 16:17:28 -04:00
7ac21690e5 Fixes #15356: Fix assignment of front & rear images to device types via REST API 2024-03-13 19:10:30 -04:00
edb7d24b45 Added installed_module on NestedModuleBaySerializer (#15245)
* added installed_module on NestedModuleBaySerializer #15243

* Update test

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2024-02-23 15:54:47 -05:00
1780acc8a6 Fixes the rackelevation api schema (#15214)
* fixes the rackelevation api schema #15101

* fixes the rackelevation api schema #15101
2024-02-21 13:39:32 -05:00
839609d101 Added allow_null for front and rear image on api (#15200)
* added allow_null for front and rear image on api #15184

* added allow_null for front and rear image on api #15184
2024-02-20 13:53:56 -05:00
d2fea4edc4 Closes #14311: Move L2VPN models from ipam to vpn (#14358)
* Move L2VPN and L2VPNTermination models from ipam to vpn

* Move L2VPN resources from ipam to vpn

* Extend migration to update content types

* Misc cleanup
2023-11-28 13:45:00 -05:00
e13bf48a35 Add /api/virtualization/virtual-machines/{id}/render-config/ endpoint (#14287)
* Add /api/virtualization/virtual-machines/{id}/render-config/ endpoint

* Update Docstring "Device" -> "Virtual Machine"

Docstring should mention "..this Virtual Machine" instead of "...this Device", thanks @LuPo!

* Move config rendering logic to new RenderConfigMixin

* Add tests for render-config API endpoint

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-11-17 08:32:58 -05:00
944008d475 Closes #12135: Prevent the deletion of interfaces with children (#14091)
* 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
2023-11-01 13:47:14 -04:00
7274e75b26 13230 Allow Devices to be excluded from Rack utilization (#14099)
* 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>
2023-10-24 11:29:24 -04:00
d77d45e795 12336 make region API calls atomic (#13942)
* 12336 make region API calls atomic

* 12336 switch to pg locks

* 12336 add locks to all views using mptt models

* 12336 fix ADVISORY_LOCK_KEYS reference

* 12336 review changes

* Tweak advisory lock numbering

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-10-17 10:35:01 -04:00
272d2c54d4 removes napalm references #13628 2023-08-31 09:54:35 -04:00
4ab0eb570c #11305: Add latitude & longitude to DeviceWithConfigContextSerializer 2023-08-29 14:31:42 -04:00
2a4e3dd09f Merge branch 'develop' into feature 2023-08-29 10:45:55 -04:00
03b341dbfd adds missing status choicefield for vdc #13556 2023-08-25 09:40:04 -04:00
1937c1fad6 #12175: Misc cleanup 2023-08-02 11:04:28 -04:00
bf20611668 #6391: Add device_role to DeviceWithConfigContextSerializer 2023-08-02 10:16:51 -04:00
0bb86f1e7d Replaces device_role with role on device model (#13342)
* replaces device_role with role on device model #6391

* fixes lint issue #6391

* revert the database user

* revert test_runner comment

* changes as per review

* Update references to device_role column in UserConfigs

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-08-02 09:55:52 -04:00
36f95f7842 Adds tenant on power feed (#13300)
* adds tenant on power feed

* cleanup

* adds power feed count on tenant object view

* Misc cleanup; add filterset tests

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-07-31 08:20:48 -04:00
0f9fe96192 Adds rf_role to interface template (#13199)
* adds rf_role to interface template #13170

* fixed migration file conflict

* Misc cleanup

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-07-26 09:13:24 -04:00
5b5444f414 Closes #13269: Cache component template counts on device types 2023-07-25 16:38:05 -04:00
daa8f71bb6 Closes #10197: Add a cached counter field for virtual chassis members 2023-07-25 15:50:12 -04:00
154b8236a2 Oob ip (devices) (#13013)
* initial oob_ip support for devices

* add primary ip and oob ip checkmark to ip address view

* add oob ip to device view and device edit view

* pep8

* make is_oob_ip and is_primary_ip generic for other models

* refactor oob_ip

* fix oob ip signal

* string capitalisation

* Misc cleanup

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-07-25 14:40:40 -04:00
149a496011 6347 Cache the number of each component type assigned to devices/VMs (#12632)
---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-07-25 09:39:05 -04:00
837be4d45f Merge branch 'develop' into feature 2023-07-11 10:09:26 -04:00
74fb707ad3 adds config_template to device serializer #13056 2023-07-06 16:04:21 -04:00
882f29192c Fixes #12975: Correct URL for VirtualDeviceContext API serializer 2023-06-23 15:23:40 -04:00
79c8219202 fixes device interface serializer #12533 2023-06-23 14:34:08 -04:00
e635f0defd Merge branch 'develop' into feature 2023-06-14 16:32:56 -07:00
4f76dcd2ea 11305 Add GPS coordinates to device (#12782)
* 11305 add lat/long to devices

* 11305 update docs

* 11305 update tests
2023-06-14 14:18:50 -04:00
d03bfe89c0 fix connected device api schema #12682 2023-06-14 15:45:07 +05:30
2e2ff09822 Merge branch 'develop' into feature 2023-06-02 15:43:06 -04:00
8b051ea2f3 7503 do device validate-create in serial (#12222)
* 7503 do device validate-create in serial

* 7503 fix single instance

* 7503 atomic transaction

* 7503 fix return data for bulk operations

* 7503 add test

* Move sequential creation logic to a mixin

---------

Co-authored-by: jeremystretch <jstretch@netboxlabs.com>
2023-05-31 09:06:09 -04:00
92c49669f9 12548 add prefetch_related for l2vpn and vdcs to interface api 2023-05-18 14:18:55 -04:00
4208b79514 Closes #12320: Remove obsolete fields napalm_driver and napalm_args from Platform 2023-05-16 09:35:27 -04:00
47f3023401 Fixes #12412: Device/VM interface MAC addresses can be nullified via REST API 2023-05-01 13:06:10 -04:00
6109bef700 Merge branch 'develop' into feature 2023-04-27 12:11:08 -04:00
5d4ef5e9e5 11607 make CableSerializer WritableNestedSerializer for to_internal value instantiation 2023-04-26 13:27:55 -07:00
f68a63255b #11029: Cleanup & changelog 2023-04-10 10:40:56 -04:00
2805633b16 Fixes #12144: Ensure consistent treatment of context data when rendering config templates via UI & API 2023-04-03 09:50:07 -04:00
ecd0c56554 Closes #9608: Move from drf-yasg to spectacular
Co-authored-by: arthanson <worldnomad@gmail.com>
Co-authored-by: jeremystretch <jstretch@netboxlabs.com>
2023-03-30 14:32:59 -04:00
00088cba6d #11559: Add device config API endpoint & cleanup 2023-03-21 17:00:06 -04:00
9ce29f9edc #9653: Cleanup 2023-03-20 16:00:08 -04:00
0455654f71 #8272: Cleanup & add filter for bridge_id 2023-03-20 11:40:45 -04:00
a74ae46f86 Add bridge to InterfaceTemplate 2023-03-07 18:00:24 -05:00
36771e821c 10520 remove Napalm code references (#11768)
* 10520 remove all Napalm code references

* 10520 remove lldp

* 10520 remove config, status - rebuild js

* 10520 re-add config parameters

* 10520 re-add serializer

* 10520 update docs
2023-02-24 15:38:50 -05:00
73a7a2d27a Closes #11559: Implement config template rendering (#11769)
* WIP

* Add config_template field to Device

* Pre-fetch referenced templates

* Correct up_to_date callable

* Add config_template FK to Device

* Update & merge migrations

* Add config_template FK to Platform

* Add tagging support for ConfigTemplate

* Catch exceptions when rendering device templates in UI

* Refactor ConfigTemplate.render()

* Add support for returning plain text content

* Add ConfigTemplate model documentation

* Add feature documentation for config rendering
2023-02-19 20:09:52 -05:00
81b8046d1d Fixes #9653 - Add default_platform to DeviceType 2023-02-19 20:09:51 -05:00
8e94eb67d2 Add the enabled filed to InterfaceTemplate 2023-02-19 20:09:51 -05:00
19da92b510 #11488: Additional cleanup 2023-01-17 10:26:34 -05:00
beb1f4e172 added missing description field on the api serializers 2023-01-17 10:20:34 -05:00