mirror of
https://github.com/Nebucatnetzer/network_inventory.git
synced 2024-06-26 19:25:34 +02:00
29 lines
608 B
Python
29 lines
608 B
Python
from django.db import models
|
|
|
|
from core.models import Category
|
|
|
|
|
|
class SoftwareArchitecture(Category):
|
|
class Meta:
|
|
ordering = ["name"]
|
|
verbose_name_plural = "Software Architectures"
|
|
|
|
|
|
class SoftwareCategory(Category):
|
|
class Meta:
|
|
ordering = ["name"]
|
|
verbose_name_plural = "Software Categories"
|
|
|
|
|
|
class Software(models.Model):
|
|
name = models.CharField(max_length=50)
|
|
category = models.ForeignKey(
|
|
SoftwareCategory, models.SET_NULL, null=True, blank=True
|
|
)
|
|
|
|
class Meta:
|
|
ordering = ["name"]
|
|
|
|
def __str__(self):
|
|
return self.name
|