Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from django.db import models
- class Tag(models.Model):
- name = CharField(max_length=255)
- tag = CharField(max_length=255, unique=True)
- class GalleryItem(models.Model):
- full_size = ImageField(upload_to='uploads/images/')
- mid_size = ImageField(upload_to='uploads/images/')
- small_size = ImageField(upload_to='uploads/images/')
- tags = ManyToManyField(Tag)
- title = CharField(max_length=255)
- created = DateTimeField(auto_now_add=True)
Add Comment
Please, Sign In to add comment