remove prints and error for otp
This commit is contained in:
@@ -79,16 +79,12 @@ class OrderItemSerailzier(serializers.ModelSerializer):
|
||||
|
||||
def get_special_discount_amount(self, obj):
|
||||
# For cart items
|
||||
print('in here asdfasfd')
|
||||
amount = getattr(obj, 'special_discount_amount', None)
|
||||
print(amount)
|
||||
if amount is None:
|
||||
print('in here')
|
||||
# If it's an order item, check item_special_discount_amount property
|
||||
amount = getattr(obj, 'item_special_discount_amount', 0)
|
||||
if amount is None:
|
||||
amount = 0
|
||||
print('in here ')
|
||||
return f'{int(amount):,.0f} تومان'
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user