Skip to content

Instantly share code, notes, and snippets.

Created October 18, 2018 14:58
What would you like to do?
Example Bird Class for Transactional AI App
class Bird(models.Model):
species_choices = [
("Spix's Macaw", "Spix's Macaw"),
("Cockatiel", "Cockatiel"),
("Caique", "Caique"),
("Guam Kingfisher", "Guam Kingfisher")
species = models.CharField(max_length=50, choices=species_choices)
image = models.ImageField(upload_to = 'images/', default = 'image/default.jpg')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment