Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Verified Commit 6eb65bf7 authored by Vincent SIMONIN's avatar Vincent SIMONIN
Browse files

:twisted_rightwards_arrows: Merge branch 'main' into test

parents c62340dd 758e0d86
No related branches found
No related tags found
1 merge request!47First merge request for NETBOX Cisco tests
......@@ -10,7 +10,7 @@ class NetBoxCertConfig(PluginConfig):
name = "netbox_cert_plugin"
verbose_name = "Netbox Certificate"
description = "A Netbox plugin to manage certificates"
version = "0.0.3"
version = "0.0.4"
author = "Vincent Simonin"
author_email = "vincent.simonin@ext.ec.europa.eu"
base_url = "cert"
......
"""API Serializer definitions"""
from rest_framework import serializers
from netbox.api.serializers import NetBoxModelSerializer
from netbox.api.serializers import NetBoxModelSerializer, WritableNestedSerializer
from ..models import Certificate
class NestedCertificateSerializer(WritableNestedSerializer):
"""Nested Certificate Serializer class"""
url = serializers.HyperlinkedIdentityField(
view_name="plugins-api:netbox_cert_plugin-api:certificate-detail"
)
class Meta:
model = Certificate
fields = (
"id",
"url",
"cn",
"alt_name",
"ca",
"expiration_time",
"cert_created_at",
"cert_expired_at",
"custom_fields",
"created",
"last_updated",
"tags",
)
class CertificateSerializer(NetBoxModelSerializer):
"""Certificate Serializer class"""
......@@ -26,5 +51,5 @@ class CertificateSerializer(NetBoxModelSerializer):
"custom_fields",
"created",
"last_updated",
"tags"
"tags",
)
......@@ -2,7 +2,7 @@ from setuptools import find_packages, setup
setup(
name='netbox_cert_plugin',
version='0.0.3',
version='0.0.4',
description='A Netbox plugin to manage certificates',
install_requires=[],
packages=find_packages(),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment