优化数据库结构

This commit is contained in:
2026-03-17 13:54:35 +08:00
parent 0a3d7daf2c
commit 2fb27aa714
3 changed files with 2 additions and 2 deletions

View File

@@ -12,7 +12,7 @@ class SigninLog(Base):
id = Column(Integer, primary_key=True, autoincrement=True)
account_id = Column(String(36), ForeignKey("accounts.id"), nullable=False)
topic_title = Column(String(100))
status = Column(String(20), nullable=False)
status = Column(String(50), nullable=False)
reward_info = Column(JSON, nullable=True)
error_message = Column(Text, nullable=True)
signed_at = Column(DateTime, server_default=func.now())

View File

@@ -51,7 +51,7 @@ CREATE TABLE IF NOT EXISTS signin_logs (
id BIGINT AUTO_INCREMENT PRIMARY KEY,
account_id CHAR(36) NOT NULL,
topic_title VARCHAR(100),
status VARCHAR(20) NOT NULL,
status VARCHAR(50) NOT NULL,
reward_info JSON,
error_message TEXT,
signed_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,