import sqlalchemy as sa
from flask_sqlalchemy import SQLAlchemy

db = SQLAlchemy()


class User(db.Model):
    id = sa.Column(sa.Integer, primary_key=True)
    name = sa.Column(sa.String)
    email = sa.Column(sa.String)


class TimeStamp(db.Model):
    id = sa.Column(sa.Integer, primary_key=True)
    user_id = sa.ForeignKey(User.id)
    create = sa.Column(sa.TIMESTAMP) # create time
    timestamp = sa.Column(sa.TIMESTAMP) # insertet by user
