Assorted fixes (#25)

* Updated imports for Netbox 3.6.1

Closes #21 and #23

* Changed Fieldtypes of Start and Expiration Date

Closes #22

* Bump to NetBox v3.6.1

* Add pyproject.toml and python workflow

---------

Co-authored-by: Manuel Hartung <manuel.hartung@atos.net>
This commit is contained in:
wkoot
2023-09-15 09:41:36 +02:00
co-authored by Manuel Hartung
parent 6c512e0e9b
commit aa41f8a402
26 changed files with 492 additions and 565 deletions
+6 -5
View File
@@ -3,7 +3,7 @@ from django import forms
from dcim.models import Manufacturer
from netbox.forms import NetBoxModelForm, NetBoxModelImportForm, NetBoxModelBulkEditForm, NetBoxModelFilterSetForm
from netbox_slm.models import SoftwareProduct
from utilities.forms import DynamicModelChoiceField, TagFilterField
from utilities.forms.fields import DynamicModelChoiceField, TagFilterField
class SoftwareProductForm(NetBoxModelForm):
@@ -21,9 +21,7 @@ class SoftwareProductForm(NetBoxModelForm):
class SoftwareProductFilterForm(NetBoxModelFilterSetForm):
model = SoftwareProduct
fieldsets = (
(None, ('q', 'tag')),
)
fieldsets = ((None, ("q", "tag")),)
tag = TagFilterField(model)
@@ -31,7 +29,10 @@ class SoftwareProductFilterForm(NetBoxModelFilterSetForm):
class SoftwareProductImportForm(NetBoxModelImportForm):
class Meta:
model = SoftwareProduct
fields = ("name", "manufacturer",)
fields = (
"name",
"manufacturer",
)
class SoftwareProductBulkEditForm(NetBoxModelBulkEditForm):