Fix multiuser
This commit is contained in:
@@ -23,10 +23,12 @@ class Note(db.Model):
|
||||
id = db.Column(db.Integer, primary_key=True)
|
||||
title = db.Column(db.String(100), unique=True)
|
||||
text = db.Column(db.Text())
|
||||
user_id = db.Column(db.Integer)
|
||||
|
||||
def __init__(self, title, text):
|
||||
def __init__(self, title, text, user_id):
|
||||
self.title = title
|
||||
self.text = text
|
||||
self.user_id = user_id
|
||||
|
||||
def __repr__(self):
|
||||
return '<Note {title}>'.format(title=self.title)
|
||||
|
Reference in New Issue
Block a user