python学习
This commit is contained in:
12
common/models/Image.py
Normal file
12
common/models/Image.py
Normal file
@@ -0,0 +1,12 @@
|
||||
# coding: utf-8
|
||||
from sqlalchemy import Column, DateTime, Integer, String
|
||||
from sqlalchemy.schema import FetchedValue
|
||||
|
||||
from application import db
|
||||
|
||||
class Image(db.Model):
|
||||
__tablename__ = 'images'
|
||||
|
||||
id = db.Column(db.Integer, primary_key=True)
|
||||
file_key = db.Column(db.String(60), nullable=False, server_default=db.FetchedValue())
|
||||
created_time = db.Column(db.DateTime, nullable=False, server_default=db.FetchedValue())
|
||||
Reference in New Issue
Block a user