Skip to content

Commit f29411c

Browse files
committed
fix
1 parent c0e67d6 commit f29411c

File tree

1 file changed

+1
-16
lines changed

1 file changed

+1
-16
lines changed

backend/apps/events/models.py

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -195,19 +195,4 @@ def __str__(self):
195195

196196
class IgnoredPost(models.Model):
197197
shortcode = models.CharField(max_length=32, unique=True)
198-
added_at = models.DateTimeField(auto_now_add=True)
199-
200-
201-
class Promotion(models.Model):
202-
# One promo window per event; extend it by spending more credits
203-
event = models.OneToOneField(Events, on_delete=models.CASCADE, related_name="promotion")
204-
starts_at = models.DateTimeField()
205-
ends_at = models.DateTimeField()
206-
207-
@property
208-
def active(self) -> bool:
209-
now = timezone.now()
210-
return self.starts_at <= now <= self.ends_at
211-
212-
def __str__(self):
213-
return f"Promotion({self.event.id}) {self.starts_at}{self.ends_at}"
198+
added_at = models.DateTimeField(auto_now_add=True)

0 commit comments

Comments
 (0)