15 lines
372 B
Python
15 lines
372 B
Python
from sqlalchemy import Boolean, Column, Integer, String, Text
|
|
|
|
from app.db.base_class import Base
|
|
|
|
|
|
class Item(Base):
|
|
"""
|
|
Database model for items.
|
|
"""
|
|
|
|
id = Column(Integer, primary_key=True, index=True)
|
|
title = Column(String(255), index=True, nullable=False)
|
|
description = Column(Text, nullable=True)
|
|
is_active = Column(Boolean, default=True)
|