Automated Action 355d2a84d5 Implement notes management platform with FastAPI and SQLite
- Set up project structure with FastAPI
- Create database models for notes
- Implement Alembic migrations
- Create API endpoints for note CRUD operations
- Implement note export functionality (markdown, txt, pdf)
- Add health endpoint
- Set up linting with Ruff
2025-06-04 08:13:43 +00:00

14 lines
466 B
Python

from sqlalchemy import Column, DateTime, Integer, String, Text, func
from app.db.session import Base
class Note(Base):
__tablename__ = "notes"
id = Column(Integer, primary_key=True, index=True)
title = Column(String(255), index=True)
content = Column(Text, nullable=False)
created_at = Column(DateTime(timezone=True), server_default=func.now())
updated_at = Column(DateTime(timezone=True), server_default=func.now(), onupdate=func.now())