add pricing_type_name to price calculation items
This commit is contained in:
@@ -69,11 +69,11 @@ class QuotaSerializer(serializers.ModelSerializer):
|
|||||||
items = [
|
items = [
|
||||||
{
|
{
|
||||||
"pricing_type": it["pricing_type_id"],
|
"pricing_type": it["pricing_type_id"],
|
||||||
"pricing_type_name": it["pricing_type_name"],
|
"pricing_type_name": it["pricing_type__name"],
|
||||||
"name": it["name"],
|
"name": it["name"],
|
||||||
"value": it["value"],
|
"value": it["value"],
|
||||||
}
|
}
|
||||||
for it in instance.pricing_items.values("pricing_type_id", "pricing_type_name", "name", "value")
|
for it in instance.pricing_items.values("pricing_type_id", "pricing_type__name", "name", "value")
|
||||||
]
|
]
|
||||||
|
|
||||||
representation["price_calculation_items"] = items
|
representation["price_calculation_items"] = items
|
||||||
|
|||||||
Reference in New Issue
Block a user