Commit b132d8c7196d702f82a97a1cca6d23d791686b80
Exists in
master
Merge branch 'master' of git.ucsd.edu:110swag/flashy-backend
Showing 2 changed files Side-by-side Diff
flashy/flashcards/models.py
View file @
b132d8c
1 | 1 | from django.db import models |
2 | +""" | |
3 | + Represents the relationship between a user and a flashcard by: | |
4 | + 1. A user has a flashcard in their deck | |
5 | + 2. A user used to have a flashcard in their deck | |
6 | + 3. A user has a flashcard hidden from them | |
7 | +""" | |
8 | +Class UserFlashcard(models.Models): | |
9 | + user = models.ForeignKey(User) | |
10 | + mask = models.ForeignKey(FlashcardMask) | |
11 | + pulled = models.DateTimeField('date pulled') | |
12 | + flashcard = models.ForeignKey(Flashcard) | |
13 | + unpulled = model.DateTimeField('date unpulled') | |
14 | + | |
2 | 15 | |
3 | 16 | #comment |
4 | 17 | |
... | ... | @@ -19,7 +32,7 @@ |
19 | 32 | user_flashcard = models.ForeignKey(UserFlashCard) |
20 | 33 | when = models.DateTimeField() |
21 | 34 | blanked_word = models.CharField(max_length=8) |
22 | - response = models.CharField(max_length=256, blank=True, null=True) | |
35 | + response = models.CharField(max_length=255, blank=True, null=True) | |
23 | 36 | correct = models.NullBooleanField() |
24 | 37 | |
25 | 38 | class Class(models.Model): |