6c86f0f571
- integrated request-module into module registry - moved backend into modules/request-module - added manifest.json and module.py - implemented dynamic router mounting - implemented dynamic static mounting - removed direct dependencies from platform core - verified startup with request-module - verified startup without request-module - added implementation_report_003.md
21 lines
748 B
Python
21 lines
748 B
Python
"""System settings model."""
|
|
|
|
from sqlalchemy import Column, String, Integer, Text, Boolean
|
|
from request_app.models.base import Base, TimestampMixin
|
|
|
|
|
|
class SystemSetting(Base, TimestampMixin):
|
|
"""System settings model for storing configuration."""
|
|
|
|
__tablename__ = "system_settings"
|
|
|
|
id = Column(Integer, primary_key=True, index=True)
|
|
category = Column(String(50), nullable=False, index=True) # email, sms, general
|
|
key = Column(String(100), nullable=False, unique=True, index=True)
|
|
value = Column(Text)
|
|
description = Column(String(500))
|
|
is_secret = Column(Boolean, default=False) # For passwords/keys
|
|
|
|
def __repr__(self) -> str:
|
|
return f"<SystemSetting(category='{self.category}', key='{self.key}')>"
|