2011-06-02 19:16:16 +01:00
|
|
|
from django.db import models
|
2011-07-11 00:13:06 +01:00
|
|
|
from core.models import Cave, Entrance
|
2011-06-02 19:16:16 +01:00
|
|
|
|
2011-07-11 00:13:06 +01:00
|
|
|
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
|