summaryrefslogtreecommitdiffstats
path: root/flatpages/models.py
blob: 7631881aebd3de7e152fa967daf65ec0739cb1b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
from django.db import models
from troggle.core.models import Cave, Entrance

class Redirect(models.Model):
    originalURL = models.CharField(max_length=200, unique=True)
    newURL = models.CharField(max_length=200)

class EntranceRedirect(models.Model):
    originalURL = models.CharField(max_length=200)
    entrance = models.ForeignKey(Entrance)
    def __unicode__(self):
        return self.entrance.slug