forked from ScoDoc/ScoDoc
ajout colonne date_envoi
This commit is contained in:
parent
3b28056278
commit
5024658a87
@ -58,3 +58,4 @@ class EntrepriseEnvoiOffre(db.Model):
|
|||||||
id = db.Column(db.Integer, primary_key=True)
|
id = db.Column(db.Integer, primary_key=True)
|
||||||
user_id = db.Column(db.Integer, db.ForeignKey("user.id"))
|
user_id = db.Column(db.Integer, db.ForeignKey("user.id"))
|
||||||
offre_id = db.Column(db.Integer, db.ForeignKey("entreprise_offre.id"))
|
offre_id = db.Column(db.Integer, db.ForeignKey("entreprise_offre.id"))
|
||||||
|
date_envoi = db.Column(db.DateTime(timezone=True), server_default=db.func.now())
|
@ -57,6 +57,7 @@ def upgrade():
|
|||||||
sa.Column('id', sa.Integer(), nullable=False),
|
sa.Column('id', sa.Integer(), nullable=False),
|
||||||
sa.Column('user_id', sa.Integer(), nullable=True),
|
sa.Column('user_id', sa.Integer(), nullable=True),
|
||||||
sa.Column('offre_id', sa.Integer(), nullable=True),
|
sa.Column('offre_id', sa.Integer(), nullable=True),
|
||||||
|
sa.Column('date_envoi', sa.DateTime(timezone=True), server_default=sa.text('now()'), nullable=True),
|
||||||
sa.ForeignKeyConstraint(['offre_id'], ['entreprise_offre.id'], ),
|
sa.ForeignKeyConstraint(['offre_id'], ['entreprise_offre.id'], ),
|
||||||
sa.ForeignKeyConstraint(['user_id'], ['user.id'], ),
|
sa.ForeignKeyConstraint(['user_id'], ['user.id'], ),
|
||||||
sa.PrimaryKeyConstraint('id')
|
sa.PrimaryKeyConstraint('id')
|
||||||
|
Loading…
Reference in New Issue
Block a user