11 lines
413 B
Python
11 lines
413 B
Python
from rest_framework.exceptions import APIException
|
|
from rest_framework import status
|
|
|
|
|
|
class QuotaWeightException(APIException):
|
|
""" if quota distributions weight is more """
|
|
|
|
status_code = status.HTTP_400_BAD_REQUEST
|
|
default_detail = "مقدار وارد شده باعث میشود مجموع سهمیهها از مقدار کل سهمیه بیشتر شود." # noqa
|
|
default_code = 'error'
|