fixed a bunch of things, hopefully didn't break things

This commit is contained in:
pacnpal
2024-11-05 21:51:02 +00:00
parent 2e8a725933
commit eb5d2acab5
30 changed files with 944 additions and 569 deletions

View File

@@ -82,7 +82,6 @@ class Ride(HistoricalModel):
updated_at = models.DateTimeField(auto_now=True)
photos = GenericRelation('media.Photo')
reviews = GenericRelation('reviews.Review')
history: HistoricalRecords = HistoricalRecords() # type: ignore
class Meta:
ordering = ['name']
@@ -120,7 +119,7 @@ class Ride(HistoricalModel):
raise cls.DoesNotExist("No ride found with this slug") from inner_e
raise cls.DoesNotExist("No ride found with this slug") from e
class RollerCoasterStats(models.Model):
class RollerCoasterStats(HistoricalModel):
LAUNCH_CHOICES = [
('CHAIN', 'Chain Lift'),
('CABLE', 'Cable Launch'),
@@ -212,7 +211,6 @@ class RollerCoasterStats(models.Model):
trains_count = models.PositiveIntegerField(null=True, blank=True)
cars_per_train = models.PositiveIntegerField(null=True, blank=True)
seats_per_car = models.PositiveIntegerField(null=True, blank=True)
history: HistoricalRecords = HistoricalRecords() # type: ignore
class Meta:
verbose_name = 'Roller Coaster Statistics'