feat(information_management): Ability to link Knowledge Base article to a Software
ref: #426 closes #331 closes #427 closes #432
This commit is contained in:
@ -333,6 +333,16 @@ class SoftwareVersion(SoftwareCommonFields, SaveHistory):
|
||||
},
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Knowledge Base",
|
||||
"slug": "kb_articles",
|
||||
"sections": [
|
||||
{
|
||||
"layout": "table",
|
||||
"field": "knowledge_base",
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Tickets",
|
||||
"slug": "tickets",
|
||||
|
@ -64,6 +64,14 @@ class SoftwareVersionModelSerializer(
|
||||
'model_id': item.pk
|
||||
}
|
||||
),
|
||||
'knowledge_base': reverse(
|
||||
"v2:_api_v2_model_kb-list",
|
||||
request=self._context['view'].request,
|
||||
kwargs={
|
||||
'model': self.Meta.model._meta.model_name,
|
||||
'model_pk': item.pk
|
||||
}
|
||||
),
|
||||
'tickets': 'ToDo'
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user