Skip to content

Commit

Permalink
add home function and create User database
Browse files Browse the repository at this point in the history
  • Loading branch information
Mikerniker committed Mar 7, 2024
1 parent 7bdc1f1 commit 13a7c6c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions Day89/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,14 @@ class Todo(db.Model):
end_field = db.Column(db.Time())
status = db.Column(db.String(250))


class User(UserMixin, db.Model):
__tablename__ = "user"
id = db.Column(db.Integer, primary_key=True)
email = db.Column(db.String(100), unique=True)
password = db.Column(db.String(100))
name = db.Column(db.String(1000))

# with app.app_context():
# db.create_all()

Expand Down Expand Up @@ -66,6 +74,11 @@ def logout():



@app.route("/", methods=["GET", "POST"])
def home():
return render_template("home.html")



@app.route("/register", methods=["GET", "POST"])
def register():
Expand Down

0 comments on commit 13a7c6c

Please sign in to comment.