feat(itam): Add category property to device software model

ref: #345 #346
This commit is contained in:
2024-10-12 17:52:58 +09:30
parent 50e6a24a4d
commit b471718b6a

View File

@ -426,6 +426,18 @@ class DeviceSoftware(DeviceCommonFields, SaveHistory):
)
@property
def category(self):
category = None
if self.software:
category = self.software.category.id
return category
@property
def parent_object(self):
""" Fetch the parent object """