From 02b6a64674220579004973ae795c6c3037b5d15a Mon Sep 17 00:00:00 2001 From: i701 Date: Mon, 24 Mar 2025 15:14:49 +0500 Subject: [PATCH] make user mobile number unique --- api/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/models.py b/api/models.py index 5da0fdc..d934133 100644 --- a/api/models.py +++ b/api/models.py @@ -11,7 +11,7 @@ from django.utils import timezone class User(AbstractUser): email = models.EmailField(unique=True, blank=True, null=True) address = models.CharField(max_length=255, blank=True) - mobile = models.CharField(max_length=255, blank=True) + mobile = models.CharField(max_length=255, blank=True, unique=True, null=True) designation = models.CharField(max_length=255, blank=True) acc_no = models.CharField(max_length=255, blank=True) id_card = models.CharField(max_length=255, blank=True)