2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-10-30 04:35:42 +00:00

Fix for 'price_breaks' field in PartSerializer (#10659)

* Fix for 'price_breaks' field in PartSerializer

- Revert change made in https://github.com/inventree/InvenTree/pull/10654

* Bump API version
This commit is contained in:
Oliver
2025-10-24 15:55:34 +11:00
committed by GitHub
parent 4e454f4c99
commit c4805504c0
2 changed files with 7 additions and 2 deletions

View File

@@ -1,11 +1,14 @@
"""InvenTree API version information.""" """InvenTree API version information."""
# InvenTree API version # InvenTree API version
INVENTREE_API_VERSION = 418 INVENTREE_API_VERSION = 419
"""Increment this API version number whenever there is a significant change to the API that any clients need to know about.""" """Increment this API version number whenever there is a significant change to the API that any clients need to know about."""
INVENTREE_API_TEXT = """ INVENTREE_API_TEXT = """
v419 -> 2025-10-24 : https://github.com/inventree/InvenTree/pull/10659
- Fixes regression introduced in v417 which reverted the changes from v416
v418 -> 2025-10-24 : https://github.com/inventree/InvenTree/pull/10657 v418 -> 2025-10-24 : https://github.com/inventree/InvenTree/pull/10657
- Add "project_code" field(s) to OrderLineItem API endpoint(s) - Add "project_code" field(s) to OrderLineItem API endpoint(s)
- Add "project_code" field(s) to ExtraOrderLineItem API endpoint(s) - Add "project_code" field(s) to ExtraOrderLineItem API endpoint(s)

View File

@@ -1042,7 +1042,9 @@ class PartSerializer(
) )
price_breaks = enable_filter( price_breaks = enable_filter(
PartSalePriceSerializer(source='salepricebreaks', many=True, read_only=True), PartSalePriceSerializer(
source='salepricebreaks', many=True, read_only=True, allow_null=True
),
False, False,
filter_name='price_breaks', filter_name='price_breaks',
) )