Second updates

This commit is contained in:
Vivek P Prakash
2025-11-28 03:11:38 +05:30
parent aa40080012
commit d3cc7eb47e
18 changed files with 758 additions and 149 deletions

View File

@@ -1,6 +1,7 @@
from django.db import models
from master_data.models import EventType
class Event(models.Model):
created_date = models.DateField(auto_now_add=True)
name = models.CharField(max_length=200)
@@ -33,6 +34,7 @@ class Event(models.Model):
def __str__(self):
return f"{self.name} ({self.start_date})"
class EventImages(models.Model):
event = models.ForeignKey(Event, on_delete=models.CASCADE)
is_primary = models.BooleanField(default=False)