Files
cannaiq/findagram/backend/app/models/user.py
Kelly a0f8d3911c feat: Add Findagram and FindADispo consumer frontends
- Add findagram.co React frontend with product search, brands, categories
- Add findadispo.com React frontend with dispensary locator
- Wire findagram to backend /api/az/* endpoints
- Update category/brand links to route to /products with filters
- Add k8s manifests for both frontends
- Add multi-domain user support migrations

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-05 16:10:15 -07:00

27 lines
1023 B
Python

from sqlalchemy import Column, Integer, String, Boolean, DateTime, Text
from sqlalchemy.sql import func
from app.database import Base
class User(Base):
__tablename__ = "users"
id = Column(Integer, primary_key=True, index=True)
email = Column(String(255), unique=True, index=True, nullable=False)
hashed_password = Column(String(255), nullable=False)
name = Column(String(255))
phone = Column(String(50))
location = Column(String(255))
avatar_url = Column(Text)
is_active = Column(Boolean, default=True)
is_verified = Column(Boolean, default=False)
# Notification preferences (stored as JSON or separate columns)
notify_price_alerts = Column(Boolean, default=True)
notify_new_products = Column(Boolean, default=True)
notify_deals = Column(Boolean, default=True)
notify_newsletter = Column(Boolean, default=False)
created_at = Column(DateTime(timezone=True), server_default=func.now())
updated_at = Column(DateTime(timezone=True), onupdate=func.now())