mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-14 09:51:22 -06:00
* Fixes: #18568 Update mkdocstrings and adapt config * Fixed some output formatting errors When trying to compare the output from "mkdocstrings[python-legacy]==0.27.0" and "mkdocstrings[python]==0.28.2" I encountered some HTML errors: - <div> inside a <p> - unescaped non-tags <pk>
This commit is contained in:
parent
8823b07745
commit
1a60cb9884
@ -54,6 +54,7 @@ Icons](https://github.com/google/material-design-icons) icon's name; or be
|
|||||||
`None` for no icon.
|
`None` for no icon.
|
||||||
|
|
||||||
For instance, the OIDC backend may be customized with
|
For instance, the OIDC backend may be customized with
|
||||||
|
|
||||||
```python
|
```python
|
||||||
SOCIAL_AUTH_BACKEND_ATTRS = {
|
SOCIAL_AUTH_BACKEND_ATTRS = {
|
||||||
'oidc': ("My awesome SSO", "login"),
|
'oidc': ("My awesome SSO", "login"),
|
||||||
|
@ -25,6 +25,7 @@ Height: {{ rack.u_height }}U
|
|||||||
To access custom fields of an object within a template, use the `cf` attribute. For example, `{{ obj.cf.color }}` will return the value (if any) for a custom field named `color` on `obj`.
|
To access custom fields of an object within a template, use the `cf` attribute. For example, `{{ obj.cf.color }}` will return the value (if any) for a custom field named `color` on `obj`.
|
||||||
|
|
||||||
If you need to use the config context data in an export template, you'll should use the function `get_config_context` to get all the config context data. For example:
|
If you need to use the config context data in an export template, you'll should use the function `get_config_context` to get all the config context data. For example:
|
||||||
|
|
||||||
```
|
```
|
||||||
{% for server in queryset %}
|
{% for server in queryset %}
|
||||||
{% set data = server.get_config_context() %}
|
{% set data = server.get_config_context() %}
|
||||||
|
@ -60,6 +60,7 @@ query {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
In addition, filtering can be done on list of related objects as shown in the following query:
|
In addition, filtering can be done on list of related objects as shown in the following query:
|
||||||
|
|
||||||
```
|
```
|
||||||
@ -98,8 +99,8 @@ Certain queries can return multiple types of objects, for example cable terminat
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
The field "class_type" is an easy way to distinguish what type of object it is when viewing the returned data, or when filtering. It contains the class name, for example "CircuitTermination" or "ConsoleServerPort".
|
The field "class_type" is an easy way to distinguish what type of object it is when viewing the returned data, or when filtering. It contains the class name, for example "CircuitTermination" or "ConsoleServerPort".
|
||||||
|
|
||||||
## Authentication
|
## Authentication
|
||||||
|
@ -204,6 +204,7 @@ To ease development, it is recommended to go ahead and install the plugin at thi
|
|||||||
```no-highlight
|
```no-highlight
|
||||||
$ pip install -e .
|
$ pip install -e .
|
||||||
```
|
```
|
||||||
|
|
||||||
More information on editable builds can be found at [Editable installs for pyproject.toml ](https://peps.python.org/pep-0660/).
|
More information on editable builds can be found at [Editable installs for pyproject.toml ](https://peps.python.org/pep-0660/).
|
||||||
|
|
||||||
## Configure NetBox
|
## Configure NetBox
|
||||||
|
@ -150,5 +150,5 @@ The [NAPALM automation](https://github.com/napalm-automation/napalm) library pro
|
|||||||
* Modified the interface serializer to include three discrete fields relating to connections: `is_connected` (boolean), `interface_connection`, and `circuit_termination`
|
* Modified the interface serializer to include three discrete fields relating to connections: `is_connected` (boolean), `interface_connection`, and `circuit_termination`
|
||||||
* Added two new fields to the inventory item serializer: `asset_tag` and `description`
|
* Added two new fields to the inventory item serializer: `asset_tag` and `description`
|
||||||
* Added "wireless" to interface type filter (in addition to physical, virtual, and LAG)
|
* Added "wireless" to interface type filter (in addition to physical, virtual, and LAG)
|
||||||
* Added a new endpoint at /api/ipam/prefixes/<pk>/available-ips/ to retrieve or create available IPs within a prefix
|
* Added a new endpoint at /api/ipam/prefixes/<pk\>/available-ips/ to retrieve or create available IPs within a prefix
|
||||||
* Extended `parent_device` on DeviceSerializer to include the `url` and `display_name` of the parent Device, and the `url` of the DeviceBay
|
* Extended `parent_device` on DeviceSerializer to include the `url` and `display_name` of the parent Device, and the `url` of the DeviceBay
|
||||||
|
@ -28,12 +28,7 @@ plugins:
|
|||||||
- mkdocstrings:
|
- mkdocstrings:
|
||||||
handlers:
|
handlers:
|
||||||
python:
|
python:
|
||||||
setup_commands:
|
paths: ["netbox"]
|
||||||
- import os
|
|
||||||
- import django
|
|
||||||
- os.chdir('netbox/')
|
|
||||||
- os.environ.setdefault("DJANGO_SETTINGS_MODULE", "netbox.settings")
|
|
||||||
- django.setup()
|
|
||||||
options:
|
options:
|
||||||
heading_level: 3
|
heading_level: 3
|
||||||
members_order: source
|
members_order: source
|
||||||
|
@ -21,7 +21,7 @@ gunicorn==23.0.0
|
|||||||
Jinja2==3.1.6
|
Jinja2==3.1.6
|
||||||
Markdown==3.7
|
Markdown==3.7
|
||||||
mkdocs-material==9.6.7
|
mkdocs-material==9.6.7
|
||||||
mkdocstrings[python-legacy]==0.27.0
|
mkdocstrings[python]==0.28.2
|
||||||
netaddr==1.3.0
|
netaddr==1.3.0
|
||||||
nh3==0.2.21
|
nh3==0.2.21
|
||||||
Pillow==11.1.0
|
Pillow==11.1.0
|
||||||
|
Loading…
Reference in New Issue
Block a user