2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-13 10:35:40 +00:00

Add serializer and API endpoint for BomItemSubstitute class

This commit is contained in:
Oliver
2021-10-13 13:58:41 +11:00
parent f3f41730be
commit 37bd5c0507
3 changed files with 76 additions and 9 deletions

View File

@ -2623,6 +2623,10 @@ class BomItemSubstitute(models.Model):
part: The part which can be used as a substitute
"""
@staticmethod
def get_api_url():
return reverse('api-bom-substitute-list')
bom_item = models.ForeignKey(
BomItem,
on_delete=models.CASCADE,