From 5525ecf681b83f2393dfda458d39f562ee3eba09 Mon Sep 17 00:00:00 2001 From: Navan Chauhan Date: Thu, 3 Jun 2021 22:49:20 +0530 Subject: moved user db model to seperate file --- app/models.py | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 app/models.py (limited to 'app/models.py') diff --git a/app/models.py b/app/models.py new file mode 100644 index 0000000..2734921 --- /dev/null +++ b/app/models.py @@ -0,0 +1,7 @@ +class User(db.Model): + id = db.Column(db.Integer, primary_key=True) + username = db.Column(db.String(80), unique=True, nullable=False) + email = db.Column(db.String(120), unique=True, nullable=False) + + def __repr__(self): + return '' % self.username \ No newline at end of file -- cgit v1.2.3