mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-15 03:25:42 +00:00
Update company API
- option to include manufacturer_detail - improve company serializer
This commit is contained in:
@ -23,6 +23,7 @@ from markdownx.models import MarkdownxField
|
||||
from stdimage.models import StdImageField
|
||||
|
||||
from InvenTree.helpers import getMediaUrl, getBlankImage, getBlankThumbnail
|
||||
from InvenTree.helpers import normalize
|
||||
from InvenTree.fields import InvenTreeURLField, RoundingDecimalField
|
||||
from InvenTree.status_codes import OrderStatus
|
||||
from common.models import Currency
|
||||
@ -352,7 +353,7 @@ class SupplierPart(models.Model):
|
||||
|
||||
if pb_found:
|
||||
cost = pb_cost * quantity
|
||||
return cost + self.base_cost
|
||||
return normalize(cost + self.base_cost)
|
||||
else:
|
||||
return None
|
||||
|
||||
|
Reference in New Issue
Block a user