Last active
August 19, 2019 13:54
-
-
Save parvbhullar/ecd5a32f6eb8c84337d4899f3111844d to your computer and use it in GitHub Desktop.
ToDo app - Django models.py - Simple model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ToDo(models.Model): | |
task_title = models.CharField(max_length=200, default="") | |
task_description = models.TextField(default="", null=True, blank=True) | |
created_at = models.DateTimeField(auto_now_add=True) | |
updated_at = models.DateTimeField(auto_now=True) | |
completed = models.BooleanField(default=False) | |
def _str_(self): | |
return self.task_title | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment