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

1698 Commits

Author SHA1 Message Date
3d20276f55 Closes #14134: Display additional object attributes in global search results (#14154)
* 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
2023-11-09 16:21:09 -05:00
ac91d4e5e5 Merge branch 'develop' into feature 2023-11-09 16:06:26 -05:00
6b89da2233 Closes #13936: Add primary_ip4 and primary_ip6 filters to VirtualMachine and VirtualDeviceContext filtersets (#14203)
* 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>
2023-11-09 09:56:43 -05:00
8dcbd66de6 Closes #13427: Public model registration (#14152)
* Initial work on #13427

* Clarify documentation

* Reference public models registry when populating models for ConfigTemplate context
2023-11-03 10:32:59 -04:00
c2d1988cb3 Closes #14035: Order global search results of equivalent weight by value (#14140) 2023-11-01 11:56:14 -04:00
7323668dd0 Closes #13334: Record error message on failed jobs (#14106) 2023-10-31 08:34:57 -04:00
edc4a35296 Initial work on #10244: Protection rules (#14097) 2023-10-30 14:36:56 -04:00
c4e765c4a8 Closes #14141: translation cleanup (#14143)
* Translations cleanup

* Tweak variable names; misc string cleanup

* Misc cleanup
2023-10-30 13:38:03 -04:00
450790ab4a Closes #13550: Refactor view action mappings (#14062)
* Merge actions and action_perms into a single mapping

* Update obsolete permission maps

* Update obsolete action lists

* Normalize empty permission mappings

* Cleanup

* Add deprecation warnings

* Introduce DEFAULT_ACTION_PERMISSIONS constant
2023-10-20 15:08:09 -04:00
3f40ee5501 Closes #14036: Move extras.plugins to netbox.plugins (#14086)
* 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
2023-10-20 11:24:08 -04:00
7983c2590e 14025 fix script name checking (#14030)
* 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
2023-10-17 10:57:50 -04:00
285187542d Adds selection custom field labels to UI 2023-10-05 15:02:22 -04:00
ef460a38ed 13944 fix report detail api 2023-10-03 14:39:46 -04:00
4dd229e73a Fixes #13864: Remove 'default' choice for dashboard widget color 2023-09-26 15:24:20 -04:00
b759d694ee Fixes #13859: Fix valid response when no matching choice values are found 2023-09-26 12:08:05 -04:00
f9ceaad284 #13666: Add is_valid property to Report class 2023-09-26 10:53:38 -04:00
e67624f042 Fixes #13666: Fix behavior for reports without test methods (#13667) 2023-09-26 10:41:09 -04:00
04796a6ac6 Fix creating config template using rest api (#13869)
* Fix creation of extras/config-templates objects using the REST API

* Update serializers.py
2023-09-25 13:33:01 -04:00
f5dd7d853a 13809 fix ConfigRevision edit if custom validators (#13825)
* 13809 fix ConfigRevision edit, check if custom validator JSON serializable

* 13809 check json rendering for all fields

* Refactor field initialization logic to more cleanly handle statically configured values

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-09-20 14:11:25 -04:00
6e4b4a553b 12685 use markdown for custom fields added to form (#13828)
* 12685 use markdown for custom fields added to form

* 13809 change markdown to use utilities

* Add help_text for CustomField description indicating Markdown support

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-09-20 14:06:04 -04:00
8e251ac33c 13757 Fix ConfigContext reference to DeviceType (#13804)
* 13757 do prefetch to work around Django issue with vars in init (DeviceType)

* 13757 use self.__dict to access vars in init

* 13757 change test
2023-09-20 09:56:52 -04:00
9aa7444bf9 Fixes #13782: Fix tag exclusion support for contact assignments 2023-09-18 11:08:49 -04:00
487827c776 13768 fix typo 2023-09-15 09:40:27 -04:00
6939bf8aed Fixes #12219: Ensure dashboard widget heading text has sufficient contrast (#13753)
* Fixes #12219: Ensure dashboard widget heading text has sufficient contrast in both light & dark modes

* Change foreground color for teal background
2023-09-13 10:56:03 -04:00
b7cfb2f7d9 Adds csv dialect detection to bulk import view (#13563)
* adds csv dialect detection to bulk import view #13239

* adds sane delimiters for dialect detection #13239

* adds csv delimiter tests #13239

* adds csv delimiter on the form

* pass delimiter to clean_csv method #13239

* fix tests for csv import #13239

* fix tests for csv import #13239

* fix tests for csv import #13239

* fix tests for csv import #13239

* Improve auto-detection of import data format

* Misc cleanup

* Include tab as a supported delimiting character for auto-detection

* Move delimiting chars to a separate constant for easy reference

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-09-12 16:48:40 -04:00
75b71890a4 Misc i18n cleanup 2023-09-11 15:59:50 -04:00
2d1457b94b Fixes: #13682 - Fix custom field exceptions and validation (#13685)
* Fixes: #13682 - Fix custom field exceptions and validation

* Add tests

* Remove default setting for multi-select/multi-object and return slice of choices and annotate.

* Remove redundant default choice valiadtion; introduce values property on CustomFieldChoiceSet

* Refactor test

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-09-06 10:47:18 -04:00
9d851924c8 13674 fix ReportSerializer (#13688)
* 13674 fix ReportSerializer

* Remove test_methods attr from Report class

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-09-06 08:44:25 -04:00
f962fb3b53 Closes #13638: Add optional staff_only attribute to MenuItem (#13639)
* Closes #13638: Add optional staff_only attribute to MenuItem

* Add missing file

* Add release note
2023-08-31 11:23:44 -04:00
2544e2bf18 Fixes #13622: Fix exception when viewing current config and no revisions have been created 2023-08-31 11:11:56 -04:00
eb9a804914 #12591: Add a dedicated view for the active config revision 2023-08-30 11:13:56 -04:00
2a4e3dd09f Merge branch 'develop' into feature 2023-08-29 10:45:55 -04:00
0a3be0b7ea adds related models count on custom field #12825 2023-08-28 08:34:33 -04:00
00ebdfe0df adds related models count on custom field #12825 2023-08-28 08:34:33 -04:00
88bf82be05 clear all cache when lazy is not used #13544 2023-08-24 10:12:48 -04:00
d73f7b1943 Fixes #13530: Ensure script log messages are cast as strings for proper serialization 2023-08-23 14:41:21 -04:00
7d7e8127f5 Fixes #13513: Prevent exception when rendering bookmarks widget for anonymous user 2023-08-23 10:53:56 -04:00
3c0a3ca703 Fixes #13516: Plugin utility functions should be importable from extras.plugins 2023-08-22 10:27:21 -04:00
c86cfe3cbf Correct filter name in redirect after bulk edit
* Added modified_by_request filter to ChangeLoggedFilterSet
2023-08-21 14:35:08 -04:00
4004966b16 fix content type filter on export template #13478 2023-08-17 15:29:21 -04:00
af06510921 Closes #13412: Enable pagination of custom field choice set choices 2023-08-16 11:08:36 -04:00
b96e437e2b #8248: Add bookmarks widget to default dashboard 2023-08-16 10:10:31 -04:00
914588f55d Merge branch 'develop' into feature 2023-08-09 15:31:21 -04:00
8b01c30c51 Exposes all models in device context data (#13389)
* exposes all models in device context data #12814

* added app namespaces to the context data

* revert object to device in context data

* moved context to render method of ConfigTemplate

* removed print

* Include only registered models; permit passed context data to overwrite apps

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-08-09 14:57:59 -04:00
dcdb4d27ec 12665 add semicolon to link sanitation safe string 2023-08-09 14:49:34 -04:00
16bcb1dbb0 #13426: Employ proper feature keys for image attachment & contact filter forms 2023-08-09 10:41:40 -04:00
5dce5563ab #11541: Fix object_types queryset on TagSerializer 2023-08-09 10:32:08 -04:00
f255fe507d Fixes #13410: Fix rendering of custom choice fields with large numner of choices 2023-08-08 09:32:56 -04:00
f5a1f83f9f Closes #13368: Report installed plugins during server error (#13387)
* Introduce get_installed_plugins() utility

* Extend 500 error template to list installed plugins

* Move get_plugin_config() to extras.plugins.utils
2023-08-07 15:29:20 -04:00
53615944c5 Adds standardized list API for scripts and reports (#13382)
* adds standardized list API for scripts and reports #13037

* adds standardized list API for scripts and reports #13037

* adds standardized list API for scripts and reports #13037

* adds module name to the display #13037
2023-08-04 15:23:15 -04:00