2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-15 03:25:42 +00:00

Display part pricing in Part view

- Calculate min_price and max_price based on provided supplier information
This commit is contained in:
Oliver Walters
2019-05-18 20:09:41 +10:00
parent 0cfb243eb3
commit a3d1591929
3 changed files with 77 additions and 1 deletions

View File

@ -7,6 +7,8 @@ from __future__ import unicode_literals
import os
import math
from django.core.validators import MinValueValidator
from django.apps import apps
@ -260,7 +262,7 @@ class SupplierPart(models.Model):
# Order multiples
if multiples:
quantity = int(math.ceil(quantity / self.multipe) * self.multiple)
quantity = int(math.ceil(quantity / self.multiple) * self.multiple)
pb_found = False
pb_quantity = -1