netbox-contract 2.4.6__tar.gz → 2.4.7__tar.gz
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.
- {netbox_contract-2.4.6/netbox_contract.egg-info → netbox_contract-2.4.7}/PKG-INFO +2 -1
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/README.md +1 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/__init__.py +1 -1
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/views.py +24 -1
- {netbox_contract-2.4.6 → netbox_contract-2.4.7/netbox_contract.egg-info}/PKG-INFO +2 -1
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/pyproject.toml +1 -1
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/CONTRIBUTING.md +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/LICENSE +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/MANIFEST.in +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/accounting_dimensions.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/contract.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/contract_linked_objects.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/invoice.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/invoice_line.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/docs/img/invoice_linked_objects.png +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/api/__init__.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/api/serializers.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/api/urls.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/api/views.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/constants.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/filtersets.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/forms.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/en/LC_MESSAGES/django.mo +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/en/LC_MESSAGES/django.po +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/fr/LC_MESSAGES/django.mo +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/fr/LC_MESSAGES/django.po +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0001_initial.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0002_alter_contract_circuit_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0003_alter_contract_custom_field_data_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0004_contract_currency_invoice_currency.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0005_contract_accounting_dimensions_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0006_alter_contract_circuit.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0007_invoice_date.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0008_invoice_comments.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0009_contract_external_reference.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0010_invoice_contracts.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0011_auto_20230122_2112.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0012_remove_invoice_contract.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0013_contract_documents_invoice_documents.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0014_contract_end_date.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0015_contractassignement.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0016_contract_parent.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0017_alter_contract_accounting_dimensions.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0018_contract_external_partie_object_id_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0019_auto_20230924_1813.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0020_alter_contract_external_partie.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0021_alter_contract_external_partie.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0022_alter_contract_internal_partie_alter_contract_parent.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0023_rename_contractassignement_contractassignment_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0024_remove_contract_external_partie.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0025_remove_contract_circuit_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0026_auto_20240421_1550.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0027_invoiceline.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0028_invoiceline_accounting_dimensions.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0029_remove_invoiceline_accounting_dimensions_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0030_alter_invoiceline_accounting_dimensions.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0031_contract_invoice_template_invoice_template.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0032_alter_invoice_period_end_alter_invoice_period_start_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0033_remove_contract_invoice_template.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0034_contract_yrc_alter_contract_mrc.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0035_accountingdimension_status_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0036_alter_invoiceline_accounting_dimensions.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0037_contract_notice_period_alter_contract_currency_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0038_alter_accountingdimension_options_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0039_alter_accountingdimension_status_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0040_alter_contract_currency_alter_invoice_currency_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0041_contracttype_contract_contract_type.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0042_remove_contract_netbox_cont_externa_6343fb_idx_and_more.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0043_invoice_status.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/__init__.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/models.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/navigation.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/search.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/tables.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/template_content.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/contract_assignments_bottom.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/contract_list_bottom.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/accountingdimension.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/contract.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/contractassignment.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/contracttype.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/invoice.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/invoiceline.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/object_contracts.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/netbox_contract/serviceprovider.html +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/urls.py +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract.egg-info/SOURCES.txt +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract.egg-info/dependency_links.txt +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract.egg-info/requires.txt +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract.egg-info/top_level.txt +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/setup.cfg +0 -0
- {netbox_contract-2.4.6 → netbox_contract-2.4.7}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: netbox-contract
|
|
3
|
-
Version: 2.4.
|
|
3
|
+
Version: 2.4.7
|
|
4
4
|
Summary: Contract management plugin for Netbox
|
|
5
5
|
Author-email: Marc Lebreuil <marc@famillelebreuil.net>
|
|
6
6
|
Project-URL: Homepage, https://github.com/mlebreuil/netbox-contract
|
|
@@ -50,6 +50,7 @@ Accounting dimensions can be linked with invoice lines.
|
|
|
50
50
|
| 4.3 | 2.4 |
|
|
51
51
|
| 4.4 | 2.4 |
|
|
52
52
|
| 4.5 | 2.4 |
|
|
53
|
+
| 4.6 | 2.4 |
|
|
53
54
|
|
|
54
55
|
## Installing
|
|
55
56
|
|
|
@@ -5,7 +5,7 @@ class ContractsConfig(PluginConfig):
|
|
|
5
5
|
name = 'netbox_contract'
|
|
6
6
|
verbose_name = 'Netbox contract'
|
|
7
7
|
description = 'Contract management plugin for Netbox'
|
|
8
|
-
version = '2.4.
|
|
8
|
+
version = '2.4.7'
|
|
9
9
|
author = 'Marc Lebreuil'
|
|
10
10
|
author_email = 'marc@famillelebreuil.net'
|
|
11
11
|
base_url = 'contracts'
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import logging
|
|
1
2
|
from datetime import date, timedelta
|
|
2
3
|
|
|
3
4
|
from dateutil.relativedelta import relativedelta
|
|
@@ -30,6 +31,8 @@ from .models import (
|
|
|
30
31
|
|
|
31
32
|
plugin_settings = settings.PLUGINS_CONFIG['netbox_contract']
|
|
32
33
|
|
|
34
|
+
logger = logging.getLogger('netbox.plugins.netbox_contract')
|
|
35
|
+
|
|
33
36
|
|
|
34
37
|
# ContractType views
|
|
35
38
|
|
|
@@ -234,7 +237,27 @@ class BaseObjectContractAssignmentView(generic.ObjectChildrenView):
|
|
|
234
237
|
# Dynamically register the view for all supported models
|
|
235
238
|
for model_string in ASSIGNEMENT_TYPES:
|
|
236
239
|
app_label, model_name = model_string.split('.')
|
|
237
|
-
|
|
240
|
+
try:
|
|
241
|
+
model = apps.get_model(app_label, model_name)
|
|
242
|
+
except LookupError:
|
|
243
|
+
# A configured supported model may not (yet) be registered in the
|
|
244
|
+
# app registry. This happens in particular with models that are
|
|
245
|
+
# created dynamically by other plugins (e.g. netbox_custom_objects
|
|
246
|
+
# custom object types), whose registration timing relative to our
|
|
247
|
+
# own app loading is not guaranteed. Rather than letting this take
|
|
248
|
+
# down the entire NetBox instance (including unrelated management
|
|
249
|
+
# commands such as `migrate`), skip this entry and let the rest of
|
|
250
|
+
# the plugin continue to load normally.
|
|
251
|
+
logger.error(
|
|
252
|
+
"netbox_contract: 'supported_models' entry '%s' does not "
|
|
253
|
+
"resolve to a registered model; skipping the Contracts tab/"
|
|
254
|
+
"view for it. Verify the app label and model name are "
|
|
255
|
+
"correct, and that any plugin providing this model (e.g. "
|
|
256
|
+
"netbox_custom_objects) has finished initializing before "
|
|
257
|
+
"netbox_contract loads.",
|
|
258
|
+
model_string,
|
|
259
|
+
)
|
|
260
|
+
continue
|
|
238
261
|
|
|
239
262
|
class_name = f"{model_name.title()}ContractAssignmentView"
|
|
240
263
|
attrs = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: netbox-contract
|
|
3
|
-
Version: 2.4.
|
|
3
|
+
Version: 2.4.7
|
|
4
4
|
Summary: Contract management plugin for Netbox
|
|
5
5
|
Author-email: Marc Lebreuil <marc@famillelebreuil.net>
|
|
6
6
|
Project-URL: Homepage, https://github.com/mlebreuil/netbox-contract
|
|
@@ -50,6 +50,7 @@ Accounting dimensions can be linked with invoice lines.
|
|
|
50
50
|
| 4.3 | 2.4 |
|
|
51
51
|
| 4.4 | 2.4 |
|
|
52
52
|
| 4.5 | 2.4 |
|
|
53
|
+
| 4.6 | 2.4 |
|
|
53
54
|
|
|
54
55
|
## Installing
|
|
55
56
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/en/LC_MESSAGES/django.mo
RENAMED
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/en/LC_MESSAGES/django.po
RENAMED
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/fr/LC_MESSAGES/django.mo
RENAMED
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/locale/fr/LC_MESSAGES/django.po
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0007_invoice_date.py
RENAMED
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0008_invoice_comments.py
RENAMED
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0010_invoice_contracts.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0014_contract_end_date.py
RENAMED
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0016_contract_parent.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0027_invoiceline.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/migrations/0043_invoice_status.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract/templates/contract_list_bottom.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netbox_contract-2.4.6 → netbox_contract-2.4.7}/netbox_contract.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|