nautobot 2.4.8__py3-none-any.whl → 2.4.10__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of nautobot might be problematic. Click here for more details.

Files changed (387) hide show
  1. nautobot/circuits/templates/circuits/circuittype.html +1 -1
  2. nautobot/circuits/templates/circuits/circuittype_retrieve.html +1 -39
  3. nautobot/circuits/views.py +18 -23
  4. nautobot/cloud/templates/cloud/cloudresourcetype_retrieve.html +4 -111
  5. nautobot/cloud/views.py +56 -25
  6. nautobot/core/api/parsers.py +56 -2
  7. nautobot/core/celery/schedulers.py +1 -0
  8. nautobot/core/filters.py +1 -1
  9. nautobot/core/graphql/schema.py +1 -0
  10. nautobot/core/jobs/__init__.py +14 -3
  11. nautobot/core/models/__init__.py +2 -0
  12. nautobot/core/tables.py +13 -6
  13. nautobot/core/testing/views.py +27 -2
  14. nautobot/core/tests/test_csv.py +92 -1
  15. nautobot/core/tests/test_jinja_filters.py +59 -0
  16. nautobot/core/tests/test_jobs.py +113 -0
  17. nautobot/core/tests/test_ui.py +53 -1
  18. nautobot/core/tests/test_utils.py +11 -0
  19. nautobot/core/tests/test_views.py +73 -0
  20. nautobot/core/ui/object_detail.py +19 -12
  21. nautobot/core/urls.py +2 -2
  22. nautobot/core/utils/filtering.py +3 -0
  23. nautobot/core/views/__init__.py +21 -0
  24. nautobot/core/views/renderers.py +1 -1
  25. nautobot/dcim/forms.py +10 -0
  26. nautobot/dcim/models/device_component_templates.py +4 -0
  27. nautobot/dcim/models/device_components.py +12 -0
  28. nautobot/dcim/models/devices.py +6 -0
  29. nautobot/dcim/templates/dcim/devicefamily_retrieve.html +1 -43
  30. nautobot/dcim/templates/dcim/deviceredundancygroup_retrieve.html +1 -59
  31. nautobot/dcim/templates/dcim/devicetype.html +2 -217
  32. nautobot/dcim/templates/dcim/devicetype_edit.html +2 -32
  33. nautobot/dcim/templates/dcim/devicetype_retrieve.html +217 -0
  34. nautobot/dcim/templates/dcim/devicetype_update.html +32 -0
  35. nautobot/dcim/templates/dcim/inc/rack_elevation.html +1 -1
  36. nautobot/dcim/templates/dcim/modulebay_retrieve.html +1 -84
  37. nautobot/dcim/templates/dcim/rack_elevation.html +14 -0
  38. nautobot/dcim/templates/dcim/rackreservation_retrieve.html +0 -68
  39. nautobot/dcim/tests/integration/test_fileinputpicker.py +1 -1
  40. nautobot/dcim/urls.py +1 -36
  41. nautobot/dcim/views.py +133 -81
  42. nautobot/extras/api/views.py +4 -6
  43. nautobot/extras/context_managers.py +2 -2
  44. nautobot/extras/migrations/0024_job_data_migration.py +1 -1
  45. nautobot/extras/models/customfields.py +2 -0
  46. nautobot/extras/models/datasources.py +8 -0
  47. nautobot/extras/models/groups.py +18 -0
  48. nautobot/extras/models/jobs.py +92 -62
  49. nautobot/extras/models/metadata.py +2 -0
  50. nautobot/extras/models/models.py +4 -0
  51. nautobot/extras/models/secrets.py +7 -0
  52. nautobot/extras/secrets/__init__.py +14 -0
  53. nautobot/extras/tables.py +11 -1
  54. nautobot/extras/templates/extras/computedfield_retrieve.html +1 -55
  55. nautobot/extras/templates/extras/inc/job_tiles.html +1 -1
  56. nautobot/extras/templates/extras/jobresult.html +1 -1
  57. nautobot/extras/templates/extras/metadatatype_retrieve.html +1 -66
  58. nautobot/extras/templates/extras/scheduledjob.html +25 -9
  59. nautobot/extras/tests/test_api.py +1 -1
  60. nautobot/extras/tests/test_context_managers.py +20 -0
  61. nautobot/extras/tests/test_models.py +26 -0
  62. nautobot/extras/tests/test_views.py +15 -2
  63. nautobot/extras/utils.py +18 -16
  64. nautobot/extras/views.py +65 -26
  65. nautobot/ipam/models.py +32 -0
  66. nautobot/ipam/tables.py +3 -4
  67. nautobot/project-static/docs/404.html +4 -4
  68. nautobot/project-static/docs/apps/index.html +4 -4
  69. nautobot/project-static/docs/apps/nautobot-apps.html +4 -4
  70. nautobot/project-static/docs/assets/javascripts/{bundle.c8b220af.min.js → bundle.13a4f30d.min.js} +4 -4
  71. nautobot/project-static/docs/assets/javascripts/{bundle.c8b220af.min.js.map → bundle.13a4f30d.min.js.map} +2 -2
  72. nautobot/project-static/docs/assets/javascripts/workers/{search.f8cc74c7.min.js → search.d50fe291.min.js} +2 -2
  73. nautobot/project-static/docs/assets/javascripts/workers/{search.f8cc74c7.min.js.map → search.d50fe291.min.js.map} +1 -1
  74. nautobot/project-static/docs/assets/stylesheets/{main.2afb09e1.min.css → main.342714a4.min.css} +1 -1
  75. nautobot/project-static/docs/assets/stylesheets/{main.2afb09e1.min.css.map → main.342714a4.min.css.map} +1 -1
  76. nautobot/project-static/docs/code-reference/nautobot/apps/__init__.html +4 -4
  77. nautobot/project-static/docs/code-reference/nautobot/apps/admin.html +4 -4
  78. nautobot/project-static/docs/code-reference/nautobot/apps/api.html +4 -4
  79. nautobot/project-static/docs/code-reference/nautobot/apps/change_logging.html +4 -4
  80. nautobot/project-static/docs/code-reference/nautobot/apps/choices.html +4 -4
  81. nautobot/project-static/docs/code-reference/nautobot/apps/config.html +4 -4
  82. nautobot/project-static/docs/code-reference/nautobot/apps/constants.html +4 -4
  83. nautobot/project-static/docs/code-reference/nautobot/apps/datasources.html +4 -4
  84. nautobot/project-static/docs/code-reference/nautobot/apps/events.html +4 -4
  85. nautobot/project-static/docs/code-reference/nautobot/apps/exceptions.html +4 -4
  86. nautobot/project-static/docs/code-reference/nautobot/apps/factory.html +4 -4
  87. nautobot/project-static/docs/code-reference/nautobot/apps/filters.html +4 -4
  88. nautobot/project-static/docs/code-reference/nautobot/apps/forms.html +4 -4
  89. nautobot/project-static/docs/code-reference/nautobot/apps/graphql.html +4 -4
  90. nautobot/project-static/docs/code-reference/nautobot/apps/jobs.html +4 -4
  91. nautobot/project-static/docs/code-reference/nautobot/apps/models.html +4 -4
  92. nautobot/project-static/docs/code-reference/nautobot/apps/querysets.html +4 -4
  93. nautobot/project-static/docs/code-reference/nautobot/apps/secrets.html +4 -4
  94. nautobot/project-static/docs/code-reference/nautobot/apps/tables.html +4 -4
  95. nautobot/project-static/docs/code-reference/nautobot/apps/testing.html +4 -4
  96. nautobot/project-static/docs/code-reference/nautobot/apps/ui.html +6 -8
  97. nautobot/project-static/docs/code-reference/nautobot/apps/urls.html +4 -4
  98. nautobot/project-static/docs/code-reference/nautobot/apps/utils.html +36 -6
  99. nautobot/project-static/docs/code-reference/nautobot/apps/views.html +4 -4
  100. nautobot/project-static/docs/development/apps/api/configuration-view.html +4 -4
  101. nautobot/project-static/docs/development/apps/api/database-backend-config.html +4 -4
  102. nautobot/project-static/docs/development/apps/api/models/django-admin.html +4 -4
  103. nautobot/project-static/docs/development/apps/api/models/global-search.html +4 -4
  104. nautobot/project-static/docs/development/apps/api/models/graphql.html +4 -4
  105. nautobot/project-static/docs/development/apps/api/models/index.html +4 -4
  106. nautobot/project-static/docs/development/apps/api/nautobot-app-config.html +4 -4
  107. nautobot/project-static/docs/development/apps/api/platform-features/custom-validators.html +4 -4
  108. nautobot/project-static/docs/development/apps/api/platform-features/filter-extensions.html +4 -4
  109. nautobot/project-static/docs/development/apps/api/platform-features/git-repository-content.html +4 -4
  110. nautobot/project-static/docs/development/apps/api/platform-features/index.html +4 -4
  111. nautobot/project-static/docs/development/apps/api/platform-features/jinja2-filters.html +4 -4
  112. nautobot/project-static/docs/development/apps/api/platform-features/jobs.html +4 -4
  113. nautobot/project-static/docs/development/apps/api/platform-features/populating-extensibility-features.html +4 -4
  114. nautobot/project-static/docs/development/apps/api/platform-features/secrets-providers.html +43 -42
  115. nautobot/project-static/docs/development/apps/api/platform-features/table-extensions.html +4 -4
  116. nautobot/project-static/docs/development/apps/api/platform-features/uniquely-identify-objects.html +4 -4
  117. nautobot/project-static/docs/development/apps/api/prometheus.html +4 -4
  118. nautobot/project-static/docs/development/apps/api/setup.html +4 -4
  119. nautobot/project-static/docs/development/apps/api/testing.html +4 -4
  120. nautobot/project-static/docs/development/apps/api/ui-extensions/banners.html +4 -4
  121. nautobot/project-static/docs/development/apps/api/ui-extensions/home-page.html +4 -4
  122. nautobot/project-static/docs/development/apps/api/ui-extensions/index.html +4 -4
  123. nautobot/project-static/docs/development/apps/api/ui-extensions/navigation.html +4 -4
  124. nautobot/project-static/docs/development/apps/api/ui-extensions/object-views.html +4 -4
  125. nautobot/project-static/docs/development/apps/api/views/base-template.html +4 -4
  126. nautobot/project-static/docs/development/apps/api/views/core-view-overrides.html +4 -4
  127. nautobot/project-static/docs/development/apps/api/views/django-generic-views.html +4 -4
  128. nautobot/project-static/docs/development/apps/api/views/help-documentation.html +4 -4
  129. nautobot/project-static/docs/development/apps/api/views/index.html +4 -4
  130. nautobot/project-static/docs/development/apps/api/views/nautobot-generic-views.html +4 -4
  131. nautobot/project-static/docs/development/apps/api/views/nautobotuiviewset.html +4 -4
  132. nautobot/project-static/docs/development/apps/api/views/nautobotuiviewsetrouter.html +4 -4
  133. nautobot/project-static/docs/development/apps/api/views/notes.html +4 -4
  134. nautobot/project-static/docs/development/apps/api/views/rest-api.html +4 -4
  135. nautobot/project-static/docs/development/apps/api/views/urls.html +4 -4
  136. nautobot/project-static/docs/development/apps/index.html +4 -4
  137. nautobot/project-static/docs/development/apps/migration/code-updates.html +4 -4
  138. nautobot/project-static/docs/development/apps/migration/dependency-updates.html +4 -4
  139. nautobot/project-static/docs/development/apps/migration/from-v1.html +4 -4
  140. nautobot/project-static/docs/development/apps/migration/model-updates/dcim.html +4 -4
  141. nautobot/project-static/docs/development/apps/migration/model-updates/extras.html +4 -4
  142. nautobot/project-static/docs/development/apps/migration/model-updates/global.html +4 -4
  143. nautobot/project-static/docs/development/apps/migration/model-updates/ipam.html +4 -4
  144. nautobot/project-static/docs/development/apps/migration/ui-component-framework/best-practices.html +4 -4
  145. nautobot/project-static/docs/development/apps/migration/ui-component-framework/custom-content.html +4 -4
  146. nautobot/project-static/docs/development/apps/migration/ui-component-framework/index.html +4 -4
  147. nautobot/project-static/docs/development/apps/migration/ui-component-framework/migration-steps.html +4 -4
  148. nautobot/project-static/docs/development/apps/porting-from-netbox.html +4 -4
  149. nautobot/project-static/docs/development/core/application-registry.html +4 -4
  150. nautobot/project-static/docs/development/core/best-practices.html +4 -4
  151. nautobot/project-static/docs/development/core/bootstrap-ui.html +4 -4
  152. nautobot/project-static/docs/development/core/caching.html +4 -4
  153. nautobot/project-static/docs/development/core/controllers.html +4 -4
  154. nautobot/project-static/docs/development/core/docker-compose-advanced-use-cases.html +41 -55
  155. nautobot/project-static/docs/development/core/generic-views.html +4 -4
  156. nautobot/project-static/docs/development/core/getting-started.html +4 -4
  157. nautobot/project-static/docs/development/core/homepage.html +4 -4
  158. nautobot/project-static/docs/development/core/index.html +4 -4
  159. nautobot/project-static/docs/development/core/minikube-dev-environment-for-k8s-jobs.html +4 -4
  160. nautobot/project-static/docs/development/core/model-checklist.html +4 -4
  161. nautobot/project-static/docs/development/core/model-features.html +4 -4
  162. nautobot/project-static/docs/development/core/natural-keys.html +4 -4
  163. nautobot/project-static/docs/development/core/navigation-menu.html +4 -4
  164. nautobot/project-static/docs/development/core/release-checklist.html +4 -4
  165. nautobot/project-static/docs/development/core/role-internals.html +4 -4
  166. nautobot/project-static/docs/development/core/settings.html +4 -4
  167. nautobot/project-static/docs/development/core/style-guide.html +4 -4
  168. nautobot/project-static/docs/development/core/templates.html +4 -4
  169. nautobot/project-static/docs/development/core/testing.html +4 -4
  170. nautobot/project-static/docs/development/core/ui-component-framework.html +4 -4
  171. nautobot/project-static/docs/development/core/user-preferences.html +4 -4
  172. nautobot/project-static/docs/development/index.html +4 -4
  173. nautobot/project-static/docs/development/jobs/getting-started.html +4 -4
  174. nautobot/project-static/docs/development/jobs/index.html +4 -4
  175. nautobot/project-static/docs/development/jobs/installation.html +4 -4
  176. nautobot/project-static/docs/development/jobs/job-extensions.html +4 -4
  177. nautobot/project-static/docs/development/jobs/job-logging.html +4 -4
  178. nautobot/project-static/docs/development/jobs/job-patterns.html +4 -4
  179. nautobot/project-static/docs/development/jobs/job-structure.html +4 -4
  180. nautobot/project-static/docs/development/jobs/migration/from-v1.html +4 -4
  181. nautobot/project-static/docs/development/jobs/testing.html +4 -4
  182. nautobot/project-static/docs/index.html +4 -4
  183. nautobot/project-static/docs/overview/application_stack.html +4 -4
  184. nautobot/project-static/docs/overview/design_philosophy.html +4 -4
  185. nautobot/project-static/docs/release-notes/index.html +4 -4
  186. nautobot/project-static/docs/release-notes/version-1.0.html +4 -4
  187. nautobot/project-static/docs/release-notes/version-1.1.html +4 -4
  188. nautobot/project-static/docs/release-notes/version-1.2.html +4 -4
  189. nautobot/project-static/docs/release-notes/version-1.3.html +4 -4
  190. nautobot/project-static/docs/release-notes/version-1.4.html +4 -4
  191. nautobot/project-static/docs/release-notes/version-1.5.html +4 -4
  192. nautobot/project-static/docs/release-notes/version-1.6.html +301 -4
  193. nautobot/project-static/docs/release-notes/version-2.0.html +4 -4
  194. nautobot/project-static/docs/release-notes/version-2.1.html +4 -4
  195. nautobot/project-static/docs/release-notes/version-2.2.html +4 -4
  196. nautobot/project-static/docs/release-notes/version-2.3.html +4 -4
  197. nautobot/project-static/docs/release-notes/version-2.4.html +291 -4
  198. nautobot/project-static/docs/requirements.txt +1 -1
  199. nautobot/project-static/docs/search/search_index.json +1 -1
  200. nautobot/project-static/docs/sitemap.xml +298 -298
  201. nautobot/project-static/docs/sitemap.xml.gz +0 -0
  202. nautobot/project-static/docs/user-guide/administration/configuration/authentication/ldap.html +4 -4
  203. nautobot/project-static/docs/user-guide/administration/configuration/authentication/remote.html +4 -4
  204. nautobot/project-static/docs/user-guide/administration/configuration/authentication/sso.html +4 -4
  205. nautobot/project-static/docs/user-guide/administration/configuration/index.html +4 -4
  206. nautobot/project-static/docs/user-guide/administration/configuration/redis.html +4 -4
  207. nautobot/project-static/docs/user-guide/administration/configuration/settings.html +4 -4
  208. nautobot/project-static/docs/user-guide/administration/configuration/time-zones.html +4 -4
  209. nautobot/project-static/docs/user-guide/administration/guides/celery-queues.html +4 -4
  210. nautobot/project-static/docs/user-guide/administration/guides/docker.html +4 -4
  211. nautobot/project-static/docs/user-guide/administration/guides/health-checks.html +4 -4
  212. nautobot/project-static/docs/user-guide/administration/guides/permissions.html +4 -4
  213. nautobot/project-static/docs/user-guide/administration/guides/prometheus-metrics.html +4 -4
  214. nautobot/project-static/docs/user-guide/administration/guides/replicating-nautobot.html +4 -4
  215. nautobot/project-static/docs/user-guide/administration/guides/request-profiling.html +4 -4
  216. nautobot/project-static/docs/user-guide/administration/guides/s3-django-storage.html +4 -4
  217. nautobot/project-static/docs/user-guide/administration/guides/selinux-troubleshooting.html +4 -4
  218. nautobot/project-static/docs/user-guide/administration/installation/app-install.html +4 -4
  219. nautobot/project-static/docs/user-guide/administration/installation/external-authentication.html +4 -4
  220. nautobot/project-static/docs/user-guide/administration/installation/http-server.html +4 -4
  221. nautobot/project-static/docs/user-guide/administration/installation/index.html +4 -4
  222. nautobot/project-static/docs/user-guide/administration/installation/install_system.html +4 -4
  223. nautobot/project-static/docs/user-guide/administration/installation/nautobot.html +4 -4
  224. nautobot/project-static/docs/user-guide/administration/installation/services.html +4 -4
  225. nautobot/project-static/docs/user-guide/administration/migration/migrating-from-netbox.html +4 -4
  226. nautobot/project-static/docs/user-guide/administration/migration/migrating-from-postgresql.html +4 -4
  227. nautobot/project-static/docs/user-guide/administration/security/index.html +4 -5
  228. nautobot/project-static/docs/user-guide/administration/security/notices.html +117 -5
  229. nautobot/project-static/docs/user-guide/administration/tools/nautobot-server.html +4 -4
  230. nautobot/project-static/docs/user-guide/administration/tools/nautobot-shell.html +4 -4
  231. nautobot/project-static/docs/user-guide/administration/upgrading/database-backup.html +4 -4
  232. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/after-you-upgrade.html +4 -4
  233. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/before-you-upgrade.html +4 -4
  234. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/for-developers.html +4 -4
  235. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/index.html +4 -4
  236. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/whats-changed.html +4 -4
  237. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/region-and-site-data-migration-guide.html +4 -4
  238. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/upgrading-from-nautobot-v1.html +4 -4
  239. nautobot/project-static/docs/user-guide/administration/upgrading/upgrading.html +4 -4
  240. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuit.html +4 -4
  241. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuittermination.html +4 -4
  242. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuittype.html +4 -4
  243. nautobot/project-static/docs/user-guide/core-data-model/circuits/provider.html +4 -4
  244. nautobot/project-static/docs/user-guide/core-data-model/circuits/providernetwork.html +4 -4
  245. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloud.html +4 -4
  246. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudaccount.html +4 -4
  247. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudnetwork.html +4 -4
  248. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudnetworkprefixassignment.html +4 -4
  249. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudresourcetype.html +4 -4
  250. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudservice.html +4 -4
  251. nautobot/project-static/docs/user-guide/core-data-model/cloud/cloudservicenetworkassignment.html +4 -4
  252. nautobot/project-static/docs/user-guide/core-data-model/dcim/cable.html +4 -4
  253. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleport.html +4 -4
  254. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleporttemplate.html +4 -4
  255. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleserverport.html +4 -4
  256. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleserverporttemplate.html +4 -4
  257. nautobot/project-static/docs/user-guide/core-data-model/dcim/controller.html +4 -4
  258. nautobot/project-static/docs/user-guide/core-data-model/dcim/controllermanageddevicegroup.html +4 -4
  259. nautobot/project-static/docs/user-guide/core-data-model/dcim/device.html +4 -4
  260. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicebay.html +4 -4
  261. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicebaytemplate.html +4 -4
  262. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicefamily.html +4 -4
  263. nautobot/project-static/docs/user-guide/core-data-model/dcim/deviceredundancygroup.html +4 -4
  264. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicetype.html +4 -4
  265. nautobot/project-static/docs/user-guide/core-data-model/dcim/frontport.html +4 -4
  266. nautobot/project-static/docs/user-guide/core-data-model/dcim/frontporttemplate.html +4 -4
  267. nautobot/project-static/docs/user-guide/core-data-model/dcim/interface.html +4 -4
  268. nautobot/project-static/docs/user-guide/core-data-model/dcim/interfaceredundancygroup.html +4 -4
  269. nautobot/project-static/docs/user-guide/core-data-model/dcim/interfacetemplate.html +4 -4
  270. nautobot/project-static/docs/user-guide/core-data-model/dcim/inventoryitem.html +4 -4
  271. nautobot/project-static/docs/user-guide/core-data-model/dcim/location.html +4 -4
  272. nautobot/project-static/docs/user-guide/core-data-model/dcim/locationtype.html +4 -4
  273. nautobot/project-static/docs/user-guide/core-data-model/dcim/manufacturer.html +4 -4
  274. nautobot/project-static/docs/user-guide/core-data-model/dcim/module.html +4 -4
  275. nautobot/project-static/docs/user-guide/core-data-model/dcim/modulebay.html +4 -4
  276. nautobot/project-static/docs/user-guide/core-data-model/dcim/modulebaytemplate.html +4 -4
  277. nautobot/project-static/docs/user-guide/core-data-model/dcim/moduletype.html +4 -4
  278. nautobot/project-static/docs/user-guide/core-data-model/dcim/platform.html +4 -4
  279. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerfeed.html +4 -4
  280. nautobot/project-static/docs/user-guide/core-data-model/dcim/poweroutlet.html +4 -4
  281. nautobot/project-static/docs/user-guide/core-data-model/dcim/poweroutlettemplate.html +4 -4
  282. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerpanel.html +4 -4
  283. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerport.html +4 -4
  284. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerporttemplate.html +4 -4
  285. nautobot/project-static/docs/user-guide/core-data-model/dcim/rack.html +4 -4
  286. nautobot/project-static/docs/user-guide/core-data-model/dcim/rackgroup.html +4 -4
  287. nautobot/project-static/docs/user-guide/core-data-model/dcim/rackreservation.html +4 -4
  288. nautobot/project-static/docs/user-guide/core-data-model/dcim/rearport.html +4 -4
  289. nautobot/project-static/docs/user-guide/core-data-model/dcim/rearporttemplate.html +4 -4
  290. nautobot/project-static/docs/user-guide/core-data-model/dcim/softwareimagefile.html +4 -4
  291. nautobot/project-static/docs/user-guide/core-data-model/dcim/softwareversion.html +4 -4
  292. nautobot/project-static/docs/user-guide/core-data-model/dcim/virtualchassis.html +4 -4
  293. nautobot/project-static/docs/user-guide/core-data-model/dcim/virtualdevicecontext.html +4 -4
  294. nautobot/project-static/docs/user-guide/core-data-model/extras/configcontext.html +4 -4
  295. nautobot/project-static/docs/user-guide/core-data-model/extras/configcontextschema.html +4 -4
  296. nautobot/project-static/docs/user-guide/core-data-model/extras/contact.html +4 -4
  297. nautobot/project-static/docs/user-guide/core-data-model/extras/team.html +4 -4
  298. nautobot/project-static/docs/user-guide/core-data-model/ipam/ipaddress.html +4 -4
  299. nautobot/project-static/docs/user-guide/core-data-model/ipam/namespace.html +4 -4
  300. nautobot/project-static/docs/user-guide/core-data-model/ipam/prefix.html +4 -4
  301. nautobot/project-static/docs/user-guide/core-data-model/ipam/rir.html +4 -4
  302. nautobot/project-static/docs/user-guide/core-data-model/ipam/routetarget.html +4 -4
  303. nautobot/project-static/docs/user-guide/core-data-model/ipam/service.html +4 -4
  304. nautobot/project-static/docs/user-guide/core-data-model/ipam/vlan.html +4 -4
  305. nautobot/project-static/docs/user-guide/core-data-model/ipam/vlangroup.html +4 -4
  306. nautobot/project-static/docs/user-guide/core-data-model/ipam/vrf.html +4 -4
  307. nautobot/project-static/docs/user-guide/core-data-model/overview/introduction.html +4 -4
  308. nautobot/project-static/docs/user-guide/core-data-model/tenancy/tenant.html +4 -4
  309. nautobot/project-static/docs/user-guide/core-data-model/tenancy/tenantgroup.html +4 -4
  310. nautobot/project-static/docs/user-guide/core-data-model/virtualization/cluster.html +4 -4
  311. nautobot/project-static/docs/user-guide/core-data-model/virtualization/clustergroup.html +4 -4
  312. nautobot/project-static/docs/user-guide/core-data-model/virtualization/clustertype.html +4 -4
  313. nautobot/project-static/docs/user-guide/core-data-model/virtualization/virtualmachine.html +4 -4
  314. nautobot/project-static/docs/user-guide/core-data-model/virtualization/vminterface.html +4 -4
  315. nautobot/project-static/docs/user-guide/core-data-model/wireless/index.html +4 -4
  316. nautobot/project-static/docs/user-guide/core-data-model/wireless/radioprofile.html +4 -4
  317. nautobot/project-static/docs/user-guide/core-data-model/wireless/supporteddatarate.html +4 -4
  318. nautobot/project-static/docs/user-guide/core-data-model/wireless/wirelessnetwork.html +4 -4
  319. nautobot/project-static/docs/user-guide/feature-guides/contacts-and-teams.html +4 -4
  320. nautobot/project-static/docs/user-guide/feature-guides/custom-fields.html +4 -4
  321. nautobot/project-static/docs/user-guide/feature-guides/getting-started/creating-devices.html +4 -4
  322. nautobot/project-static/docs/user-guide/feature-guides/getting-started/creating-location-types-and-locations.html +4 -4
  323. nautobot/project-static/docs/user-guide/feature-guides/getting-started/index.html +4 -4
  324. nautobot/project-static/docs/user-guide/feature-guides/getting-started/interfaces.html +4 -4
  325. nautobot/project-static/docs/user-guide/feature-guides/getting-started/ipam.html +4 -4
  326. nautobot/project-static/docs/user-guide/feature-guides/getting-started/platforms.html +4 -4
  327. nautobot/project-static/docs/user-guide/feature-guides/getting-started/search-bar.html +4 -4
  328. nautobot/project-static/docs/user-guide/feature-guides/getting-started/tenants.html +4 -4
  329. nautobot/project-static/docs/user-guide/feature-guides/getting-started/vlans-and-vlan-groups.html +4 -4
  330. nautobot/project-static/docs/user-guide/feature-guides/git-data-source.html +4 -4
  331. nautobot/project-static/docs/user-guide/feature-guides/graphql.html +4 -4
  332. nautobot/project-static/docs/user-guide/feature-guides/ip-address-merge-tool.html +4 -4
  333. nautobot/project-static/docs/user-guide/feature-guides/relationships.html +4 -4
  334. nautobot/project-static/docs/user-guide/feature-guides/software-image-files-and-versions.html +4 -4
  335. nautobot/project-static/docs/user-guide/feature-guides/wireless-networks-and-controllers.html +4 -4
  336. nautobot/project-static/docs/user-guide/index.html +4 -4
  337. nautobot/project-static/docs/user-guide/platform-functionality/change-logging.html +4 -4
  338. nautobot/project-static/docs/user-guide/platform-functionality/computedfield.html +4 -4
  339. nautobot/project-static/docs/user-guide/platform-functionality/customfield.html +4 -4
  340. nautobot/project-static/docs/user-guide/platform-functionality/customlink.html +4 -4
  341. nautobot/project-static/docs/user-guide/platform-functionality/dynamicgroup.html +4 -4
  342. nautobot/project-static/docs/user-guide/platform-functionality/events.html +4 -4
  343. nautobot/project-static/docs/user-guide/platform-functionality/exporttemplate.html +4 -4
  344. nautobot/project-static/docs/user-guide/platform-functionality/externalintegration.html +4 -4
  345. nautobot/project-static/docs/user-guide/platform-functionality/gitrepository.html +4 -4
  346. nautobot/project-static/docs/user-guide/platform-functionality/graphql.html +4 -4
  347. nautobot/project-static/docs/user-guide/platform-functionality/graphqlquery.html +4 -4
  348. nautobot/project-static/docs/user-guide/platform-functionality/imageattachment.html +4 -4
  349. nautobot/project-static/docs/user-guide/platform-functionality/jobs/index.html +4 -4
  350. nautobot/project-static/docs/user-guide/platform-functionality/jobs/job-scheduling-and-approvals.html +4 -4
  351. nautobot/project-static/docs/user-guide/platform-functionality/jobs/jobbutton.html +4 -4
  352. nautobot/project-static/docs/user-guide/platform-functionality/jobs/jobhook.html +4 -4
  353. nautobot/project-static/docs/user-guide/platform-functionality/jobs/jobqueue.html +4 -4
  354. nautobot/project-static/docs/user-guide/platform-functionality/jobs/kubernetes-job-support.html +4 -4
  355. nautobot/project-static/docs/user-guide/platform-functionality/jobs/managing-jobs.html +4 -4
  356. nautobot/project-static/docs/user-guide/platform-functionality/jobs/models.html +4 -4
  357. nautobot/project-static/docs/user-guide/platform-functionality/napalm.html +4 -4
  358. nautobot/project-static/docs/user-guide/platform-functionality/note.html +4 -4
  359. nautobot/project-static/docs/user-guide/platform-functionality/objectmetadata.html +4 -4
  360. nautobot/project-static/docs/user-guide/platform-functionality/relationship.html +4 -4
  361. nautobot/project-static/docs/user-guide/platform-functionality/rendering-jinja-templates.html +4 -4
  362. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/authentication.html +4 -4
  363. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/filtering.html +4 -4
  364. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/overview.html +4 -4
  365. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/ui-related-endpoints.html +4 -4
  366. nautobot/project-static/docs/user-guide/platform-functionality/role.html +4 -4
  367. nautobot/project-static/docs/user-guide/platform-functionality/savedview.html +4 -4
  368. nautobot/project-static/docs/user-guide/platform-functionality/secret.html +4 -4
  369. nautobot/project-static/docs/user-guide/platform-functionality/staticgroupassociation.html +4 -4
  370. nautobot/project-static/docs/user-guide/platform-functionality/status.html +4 -4
  371. nautobot/project-static/docs/user-guide/platform-functionality/tag.html +4 -4
  372. nautobot/project-static/docs/user-guide/platform-functionality/template-filters.html +4 -4
  373. nautobot/project-static/docs/user-guide/platform-functionality/users/objectpermission.html +4 -4
  374. nautobot/project-static/docs/user-guide/platform-functionality/users/token.html +4 -4
  375. nautobot/project-static/docs/user-guide/platform-functionality/webhook.html +4 -4
  376. nautobot/project-static/js/forms.js +0 -14
  377. nautobot/users/models.py +4 -0
  378. nautobot/virtualization/models.py +4 -0
  379. nautobot/wireless/tables.py +1 -0
  380. nautobot/wireless/templates/wireless/wirelessnetwork_retrieve.html +1 -55
  381. nautobot/wireless/views.py +33 -28
  382. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/METADATA +4 -4
  383. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/RECORD +387 -384
  384. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/LICENSE.txt +0 -0
  385. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/NOTICE +0 -0
  386. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/WHEEL +0 -0
  387. {nautobot-2.4.8.dist-info → nautobot-2.4.10.dist-info}/entry_points.txt +0 -0
nautobot/dcim/views.py CHANGED
@@ -686,6 +686,45 @@ class RackReservationUIViewSet(NautobotUIViewSet):
686
686
  table_class = tables.RackReservationTable
687
687
  queryset = RackReservation.objects.all()
688
688
 
689
+ object_detail_content = object_detail.ObjectDetailContent(
690
+ panels=(
691
+ object_detail.KeyValueTablePanel(
692
+ section=SectionChoices.LEFT_HALF,
693
+ weight=100,
694
+ label="Rack",
695
+ context_data_key="rack_data",
696
+ ),
697
+ object_detail.ObjectFieldsPanel(
698
+ section=SectionChoices.LEFT_HALF,
699
+ weight=100,
700
+ label="Reservation Details",
701
+ fields=["unit_list", "tenant", "user", "description"],
702
+ ),
703
+ object_detail.Panel(
704
+ section=SectionChoices.RIGHT_HALF,
705
+ weight=100,
706
+ template_path="dcim/rack_elevation.html",
707
+ ),
708
+ ),
709
+ )
710
+
711
+ def get_extra_context(self, request, instance):
712
+ context = super().get_extra_context(request, instance)
713
+ if self.action == "retrieve":
714
+ context["rack_data"] = self.get_rack_context(instance)
715
+ return context
716
+
717
+ def get_rack_context(self, instance):
718
+ rack = getattr(instance, "rack", None)
719
+ if not rack:
720
+ return {}
721
+
722
+ return {
723
+ "location": rack.location,
724
+ "rack_group": rack.rack_group,
725
+ "rack": rack,
726
+ }
727
+
689
728
  def get_object(self):
690
729
  obj = super().get_object()
691
730
 
@@ -743,20 +782,18 @@ class ManufacturerUIViewSet(NautobotUIViewSet):
743
782
  #
744
783
  # Device types
745
784
  #
746
-
747
-
748
- class DeviceTypeListView(generic.ObjectListView):
749
- queryset = DeviceType.objects.all()
750
- filterset = filters.DeviceTypeFilterSet
751
- filterset_form = forms.DeviceTypeFilterForm
752
- table = tables.DeviceTypeTable
753
- template_name = "dcim/devicetype_list.html"
754
-
755
-
756
- class DeviceTypeView(generic.ObjectView):
785
+ class DeviceTypeUIViewSet(NautobotUIViewSet):
786
+ bulk_update_form_class = forms.DeviceTypeBulkEditForm
787
+ filterset_class = filters.DeviceTypeFilterSet
788
+ filterset_form_class = forms.DeviceTypeFilterForm
789
+ form_class = forms.DeviceTypeForm
790
+ serializer_class = serializers.DeviceTypeSerializer
791
+ table_class = tables.DeviceTypeTable
757
792
  queryset = DeviceType.objects.select_related("manufacturer").prefetch_related("software_image_files")
758
793
 
759
794
  def get_extra_context(self, request, instance):
795
+ if self.action != "retrieve":
796
+ return {}
760
797
  instance_count = Device.objects.restrict(request.user).filter(device_type=instance).count()
761
798
 
762
799
  # Component tables
@@ -831,16 +868,6 @@ class DeviceTypeView(generic.ObjectView):
831
868
  }
832
869
 
833
870
 
834
- class DeviceTypeEditView(generic.ObjectEditView):
835
- queryset = DeviceType.objects.all()
836
- model_form = forms.DeviceTypeForm
837
- template_name = "dcim/devicetype_edit.html"
838
-
839
-
840
- class DeviceTypeDeleteView(generic.ObjectDeleteView):
841
- queryset = DeviceType.objects.all()
842
-
843
-
844
871
  class DeviceTypeImportView(generic.ObjectImportView):
845
872
  additional_permissions = [
846
873
  "dcim.add_devicetype",
@@ -871,19 +898,6 @@ class DeviceTypeImportView(generic.ObjectImportView):
871
898
  )
872
899
 
873
900
 
874
- class DeviceTypeBulkEditView(generic.BulkEditView):
875
- queryset = DeviceType.objects.all()
876
- filterset = filters.DeviceTypeFilterSet
877
- table = tables.DeviceTypeTable
878
- form = forms.DeviceTypeBulkEditForm
879
-
880
-
881
- class DeviceTypeBulkDeleteView(generic.BulkDeleteView):
882
- queryset = DeviceType.objects.all()
883
- filterset = filters.DeviceTypeFilterSet
884
- table = tables.DeviceTypeTable
885
-
886
-
887
901
  #
888
902
  # Module types
889
903
  #
@@ -3381,13 +3395,42 @@ class ModuleBayUIViewSet(ModuleBayCommonViewSetMixin, NautobotUIViewSet):
3381
3395
  table_class = tables.ModuleBayTable
3382
3396
  create_template_name = "dcim/device_component_add.html"
3383
3397
 
3398
+ object_detail_content = object_detail.ObjectDetailContent(
3399
+ panels=(
3400
+ object_detail.ObjectFieldsPanel(
3401
+ weight=100,
3402
+ section=SectionChoices.LEFT_HALF,
3403
+ fields="__all__",
3404
+ hide_if_unset=("parent_device", "parent_module"),
3405
+ ),
3406
+ object_detail.ObjectFieldsPanel(
3407
+ weight=100,
3408
+ section=SectionChoices.RIGHT_HALF,
3409
+ context_object_key="installed_module_data",
3410
+ label="Installed Module",
3411
+ ),
3412
+ )
3413
+ )
3414
+
3384
3415
  def get_extra_context(self, request, instance):
3416
+ context = super().get_extra_context(request, instance)
3417
+
3385
3418
  if instance:
3386
- return {
3387
- "device_breadcrumb_url": "dcim:device_modulebays",
3388
- "module_breadcrumb_url": "dcim:module_modulebays",
3389
- }
3390
- return {}
3419
+ # Set breadcrumbs always
3420
+ context.update(
3421
+ {
3422
+ "device_breadcrumb_url": "dcim:device_modulebays",
3423
+ "module_breadcrumb_url": "dcim:module_modulebays",
3424
+ }
3425
+ )
3426
+
3427
+ # Add installed module context
3428
+ context["installed_module_data"] = self._get_installed_module_context(instance)
3429
+
3430
+ return context
3431
+
3432
+ def _get_installed_module_context(self, instance):
3433
+ return getattr(instance, "installed_module", None)
3391
3434
 
3392
3435
  def get_selected_objects_parents_name(self, selected_objects):
3393
3436
  selected_object = selected_objects.first()
@@ -4135,18 +4178,32 @@ class DeviceRedundancyGroupUIViewSet(NautobotUIViewSet):
4135
4178
  serializer_class = serializers.DeviceRedundancyGroupSerializer
4136
4179
  table_class = tables.DeviceRedundancyGroupTable
4137
4180
 
4138
- def get_extra_context(self, request, instance):
4139
- context = super().get_extra_context(request, instance)
4140
-
4141
- if self.action == "retrieve" and instance:
4142
- devices = instance.devices_sorted.restrict(request.user)
4143
- devices_table = tables.DeviceTable(devices)
4144
- devices_table.columns.show("device_redundancy_group_priority")
4145
- context["devices_table"] = devices_table
4146
- controllers = instance.controllers_sorted.restrict(request.user)
4147
- controllers_table = tables.ControllerTable(controllers)
4148
- context["controllers_table"] = controllers_table
4149
- return context
4181
+ object_detail_content = object_detail.ObjectDetailContent(
4182
+ panels=(
4183
+ object_detail.ObjectFieldsPanel(
4184
+ section=SectionChoices.LEFT_HALF,
4185
+ weight=100,
4186
+ fields="__all__",
4187
+ ),
4188
+ object_detail.ObjectsTablePanel(
4189
+ section=SectionChoices.FULL_WIDTH,
4190
+ weight=100,
4191
+ table_class=tables.ControllerTable,
4192
+ table_attribute="controllers_sorted",
4193
+ related_field_name="controller_device_redundancy_group",
4194
+ ),
4195
+ object_detail.ObjectsTablePanel(
4196
+ section=SectionChoices.FULL_WIDTH,
4197
+ weight=200,
4198
+ table_class=tables.DeviceTable,
4199
+ table_attribute="devices_sorted",
4200
+ related_field_name="device_redundancy_group",
4201
+ include_columns=[
4202
+ "device_redundancy_group_priority",
4203
+ ],
4204
+ ),
4205
+ )
4206
+ )
4150
4207
 
4151
4208
 
4152
4209
  class InterfaceRedundancyGroupUIViewSet(NautobotUIViewSet):
@@ -4211,36 +4268,31 @@ class DeviceFamilyUIViewSet(NautobotUIViewSet):
4211
4268
  serializer_class = serializers.DeviceFamilySerializer
4212
4269
  table_class = tables.DeviceFamilyTable
4213
4270
  lookup_field = "pk"
4214
-
4215
- def get_extra_context(self, request, instance):
4216
- # Related device types table
4217
- context = super().get_extra_context(request, instance)
4218
- if self.action == "retrieve":
4219
- device_types = (
4220
- DeviceType.objects.restrict(request.user, "view")
4221
- .filter(device_family=instance)
4222
- .select_related("manufacturer")
4223
- .annotate(device_count=count_related(Device, "device_type"))
4224
- )
4225
- device_type_table = tables.DeviceTypeTable(device_types, orderable=False)
4226
-
4227
- paginate = {
4228
- "paginator_class": EnhancedPaginator,
4229
- "per_page": get_paginate_count(request),
4230
- }
4231
- RequestConfig(request, paginate).configure(device_type_table)
4232
-
4233
- context["device_type_table"] = device_type_table
4234
-
4235
- total_devices = 0
4236
- device_type_count = 0
4237
- for device_type in device_types:
4238
- total_devices += device_type.device_count
4239
- device_type_count += 1
4240
- context["total_devices"] = total_devices
4241
- context["device_type_count"] = device_type_count
4242
-
4243
- return context
4271
+ object_detail_content = object_detail.ObjectDetailContent(
4272
+ panels=(
4273
+ object_detail.ObjectFieldsPanel(
4274
+ weight=100,
4275
+ section=SectionChoices.LEFT_HALF,
4276
+ fields="__all__",
4277
+ ),
4278
+ object_detail.ObjectsTablePanel(
4279
+ weight=100,
4280
+ section=SectionChoices.FULL_WIDTH,
4281
+ table_class=tables.DeviceTypeTable,
4282
+ table_filter="device_family",
4283
+ select_related_fields=["manufacturer"],
4284
+ exclude_columns=["device_family"],
4285
+ ),
4286
+ object_detail.ObjectsTablePanel(
4287
+ weight=200,
4288
+ section=SectionChoices.FULL_WIDTH,
4289
+ table_class=tables.DeviceTable,
4290
+ table_filter="device_type__device_family",
4291
+ related_field_name="device_family",
4292
+ exclude_columns=["device_family"],
4293
+ ),
4294
+ )
4295
+ )
4244
4296
 
4245
4297
 
4246
4298
  #
@@ -703,10 +703,8 @@ class JobViewSetBase(
703
703
  # of errors under messages
704
704
  return Response({"errors": e.message_dict if hasattr(e, "error_dict") else e.messages}, status=400)
705
705
 
706
- queue = get_job_queue(task_queue)
707
- if queue is None:
708
- queue = job_model.default_job_queue
709
- if queue.queue_type == JobQueueTypeChoices.TYPE_CELERY and not get_worker_count(queue=task_queue):
706
+ job_queue = get_job_queue(task_queue) or job_model.default_job_queue
707
+ if job_queue.queue_type == JobQueueTypeChoices.TYPE_CELERY and not get_worker_count(queue=task_queue):
710
708
  raise CeleryWorkerNotRunningException(queue=task_queue)
711
709
 
712
710
  # Default to a null JobResult.
@@ -737,7 +735,7 @@ class JobViewSetBase(
737
735
  interval=schedule_data.get("interval"),
738
736
  crontab=schedule_data.get("crontab", ""),
739
737
  approval_required=approval_required,
740
- task_queue=task_queue,
738
+ job_queue=job_queue,
741
739
  **job_class.serialize_data(cleaned_data),
742
740
  )
743
741
  else:
@@ -748,7 +746,7 @@ class JobViewSetBase(
748
746
  job_result = JobResult.enqueue_job(
749
747
  job_model,
750
748
  request.user,
751
- task_queue=task_queue,
749
+ job_queue=job_queue,
752
750
  **job_class.serialize_data(cleaned_data),
753
751
  )
754
752
 
@@ -254,8 +254,8 @@ def web_request_context(
254
254
  # TODO: get_snapshots() currently requires a DB query per object change processed.
255
255
  # We need to develop a more efficient approach: https://github.com/nautobot/nautobot/issues/6303
256
256
  snapshots = oc.get_snapshots(
257
- pre_object_data.get(str(oc.changed_object_id), None),
258
- pre_object_data_v2.get(str(oc.changed_object_id), None),
257
+ pre_object_data.get(str(oc.changed_object_id), None) if pre_object_data else None,
258
+ pre_object_data_v2.get(str(oc.changed_object_id), None) if pre_object_data_v2 else None,
259
259
  )
260
260
  webhook_queryset = enqueue_webhooks(oc, snapshots=snapshots, webhook_queryset=webhook_queryset)
261
261
 
@@ -52,7 +52,7 @@ def migrate_job_data(apps, schema_editor):
52
52
 
53
53
  # Shouldn't be needed but I've seen cases where it happens - not sure exactly why
54
54
  for job_jobresult in JobResult.objects.filter(obj_type__model="jobmodel"):
55
- print("Fixing up content type on {job_jobresult}")
55
+ print(f"Fixing up content type on {job_jobresult}")
56
56
  job_jobresult.obj_type = job_ct
57
57
  job_jobresult.save()
58
58
 
@@ -269,6 +269,8 @@ class CustomFieldModel(models.Model):
269
269
  elif cf.required:
270
270
  raise ValidationError(f"Missing required custom field '{cf.key}'.")
271
271
 
272
+ clean.alters_data = True
273
+
272
274
  # Computed Field Methods
273
275
  def has_computed_fields(self, advanced_ui=None):
274
276
  """
@@ -180,6 +180,8 @@ class GitRepository(PrimaryModel):
180
180
  return enqueue_git_repository_diff_origin_and_local(self, user)
181
181
  return enqueue_pull_git_repository_and_refresh_data(self, user)
182
182
 
183
+ sync.alters_data = True
184
+
183
185
  @contextmanager
184
186
  def clone_to_directory_context(self, path=None, branch=None, head=None, depth=0):
185
187
  """
@@ -207,6 +209,8 @@ class GitRepository(PrimaryModel):
207
209
  if path_name:
208
210
  self.cleanup_cloned_directory(path_name)
209
211
 
212
+ clone_to_directory_context.alters_data = True
213
+
210
214
  def clone_to_directory(self, path=None, branch=None, head=None, depth=0):
211
215
  """
212
216
  Perform a (shallow or full) clone of the Git repository in a temporary directory.
@@ -246,6 +250,8 @@ class GitRepository(PrimaryModel):
246
250
  logger.info(f"Cloned repository {self.name} to {path_name}")
247
251
  return path_name
248
252
 
253
+ clone_to_directory.alters_data = True
254
+
249
255
  def cleanup_cloned_directory(self, path):
250
256
  """
251
257
  Cleanup the cloned directory.
@@ -259,3 +265,5 @@ class GitRepository(PrimaryModel):
259
265
  except OSError as os_error:
260
266
  # log error if the cleanup fails
261
267
  logger.error(f"Failed to cleanup temporary directory at {path}: {os_error}")
268
+
269
+ cleanup_cloned_directory.alters_data = True
@@ -338,6 +338,8 @@ class DynamicGroup(PrimaryModel):
338
338
 
339
339
  return self.members
340
340
 
341
+ _set_members.alters_data = True
342
+
341
343
  def add_members(self, objects_to_add):
342
344
  """Add the given list or QuerySet of objects to this staticly defined group."""
343
345
  if self.group_type != DynamicGroupTypeChoices.TYPE_STATIC:
@@ -354,6 +356,8 @@ class DynamicGroup(PrimaryModel):
354
356
  objects_to_add = [obj for obj in objects_to_add if obj not in existing_members]
355
357
  return self._add_members(objects_to_add)
356
358
 
359
+ add_members.alters_data = True
360
+
357
361
  def _add_members(self, objects_to_add):
358
362
  """
359
363
  Internal API for adding the given list or QuerySet of objects to the cached/static members of this group.
@@ -377,6 +381,8 @@ class DynamicGroup(PrimaryModel):
377
381
  ]
378
382
  StaticGroupAssociation.all_objects.bulk_create(sgas, batch_size=1000)
379
383
 
384
+ _add_members.alters_data = True
385
+
380
386
  def remove_members(self, objects_to_remove):
381
387
  """Remove the given list or QuerySet of objects from this staticly defined group."""
382
388
  if self.group_type != DynamicGroupTypeChoices.TYPE_STATIC:
@@ -390,6 +396,8 @@ class DynamicGroup(PrimaryModel):
390
396
  raise TypeError(f"{obj} is not a {self.model._meta.label_lower}")
391
397
  return self._remove_members(objects_to_remove)
392
398
 
399
+ remove_members.alters_data = True
400
+
393
401
  def _remove_members(self, objects_to_remove):
394
402
  """Internal API for removing the given list or QuerySet from the cached/static members of this Group."""
395
403
  from nautobot.extras.signals import _handle_deleted_object # avoid circular import
@@ -418,6 +426,8 @@ class DynamicGroup(PrimaryModel):
418
426
  logger.debug("Re-connecting the _handle_deleted_object signal")
419
427
  pre_delete.connect(_handle_deleted_object)
420
428
 
429
+ _remove_members.alters_data = True
430
+
421
431
  @property
422
432
  @method_deprecated("Members are now cached in the database via StaticGroupAssociations rather than in Redis.")
423
433
  def members_cache_key(self):
@@ -451,6 +461,8 @@ class DynamicGroup(PrimaryModel):
451
461
 
452
462
  return members
453
463
 
464
+ update_cached_members.alters_data = True
465
+
454
466
  def has_member(self, obj, use_cache=False):
455
467
  """
456
468
  Return True if the given object is a member of this group.
@@ -560,6 +572,8 @@ class DynamicGroup(PrimaryModel):
560
572
 
561
573
  self.filter = new_filter
562
574
 
575
+ set_filter.alters_data = True
576
+
563
577
  def get_initial(self):
564
578
  """
565
579
  Return a form-friendly version of `self.filter` for initial form data.
@@ -815,6 +829,8 @@ class DynamicGroup(PrimaryModel):
815
829
  instance = self.children.through(parent_group=self, group=child, operator=operator, weight=weight)
816
830
  return instance.validated_save()
817
831
 
832
+ add_child.alters_data = True
833
+
818
834
  # TODO: unused in core
819
835
  def remove_child(self, child):
820
836
  """
@@ -829,6 +845,8 @@ class DynamicGroup(PrimaryModel):
829
845
  instance = self.children.through.objects.get(parent_group=self, group=child)
830
846
  return instance.delete()
831
847
 
848
+ remove_child.alters_data = True
849
+
832
850
  def get_descendants(self, group=None):
833
851
  """
834
852
  Recursively return a list of the children of all child groups.