The updates for the customer dashboard cum accounts

This commit is contained in:
Vivek
2025-12-09 03:59:57 +05:30
parent 08a89a1212
commit 24355ecdf5
38 changed files with 1057 additions and 16 deletions

View File

@@ -4,9 +4,9 @@ from django.db import models
from accounts.manager import UserManager
ROLE_CHOICES = (
('Admin', 'Admin'),
('Manager', 'Manager'),
('Staff', 'Staff'),
('admin', 'Admin'),
('manager', 'Manager'),
('staff', 'Staff'),
)
@@ -18,6 +18,17 @@ class User(AbstractUser):
is_customer = models.BooleanField(default=False)
is_user = models.BooleanField(default=False)
# Location fields
pincode = models.CharField(max_length=10, blank=True, null=True)
district = models.CharField(max_length=100, blank=True, null=True)
state = models.CharField(max_length=100, blank=True, null=True)
country = models.CharField(max_length=100, blank=True, null=True)
place = models.CharField(max_length=200, blank=True, null=True)
# Location fields
latitude = models.DecimalField(max_digits=9, decimal_places=6, blank=True, null=True)
longitude = models.DecimalField(max_digits=9, decimal_places=6, blank=True, null=True)
objects = UserManager()
def __str__(self):