moved everything to a new module called backend
This commit is contained in:
15
backend/models/example_model.py
Normal file
15
backend/models/example_model.py
Normal file
@@ -0,0 +1,15 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from backend import db
|
||||
import uuid
|
||||
|
||||
|
||||
class ExampleDataItem(db.Model):
|
||||
"""
|
||||
just an example class...
|
||||
"""
|
||||
id = db.Column(db.Integer, primary_key=True, autoincrement=True)
|
||||
mac = db.Column(db.String(32), nullable=False, unique=True, index=True)
|
||||
uuid = db.Column(db.String(36), nullable=False, unique=True, index=True, default=str(uuid.uuid4()))
|
||||
some_string_value = db.Column(db.String, nullable=True, index=True)
|
||||
name = db.Column(db.String(128), default="<not set>", nullable=False, index=True, unique=False)
|
||||
description = db.Column(db.String(4096), nullable=True, unique=False)
|
||||
Reference in New Issue
Block a user