fix - if rancher duplicated in check with national code in pos
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
from rest_framework.exceptions import APIException
|
||||
from rest_framework import status
|
||||
from rest_framework.exceptions import APIException
|
||||
|
||||
|
||||
class UniqueRancherApiException(APIException):
|
||||
@@ -7,6 +7,11 @@ class UniqueRancherApiException(APIException):
|
||||
default_detail = "دامدار با این کد ملی از قبل در سیستم وجود دارد" # noqa
|
||||
|
||||
|
||||
class DuplicateRancherException(APIException):
|
||||
status_code = status.HTTP_403_FORBIDDEN
|
||||
default_detail = "دامدار با این شماره تماس از قبل در سیستم وجود دارد" # noqa
|
||||
|
||||
|
||||
class HerdCapacityException(APIException):
|
||||
status_code = status.HTTP_403_FORBIDDEN
|
||||
default_detail = "مقدار حجم سبک و سنگین وارد شده از ظرفیت گله بیشتر میباشد" # noqa
|
||||
|
||||
Reference in New Issue
Block a user