Files
lindyson-ai/apps/api/migrations/024_admin_pagination.sql
Juno ChowandClaude Fable 5.1 f665082dad chore: 建立产品仓库,完成开源前的敏感信息清理
前端(Vite + React)、API/worker(Fastify + BullMQ)、api-contracts 契约包、
迁移脚本、测试与自托管 docker-compose 示例。

开源准备:运维脚本与机器信息已拆到私有仓库;公司名、备案号、隐私邮箱改读
publicCompliance.local.json(仓库只保留占位模板);站点地址与客服二维码改为
VITE_ 环境变量;fixtures 中的真实用户标识已匿名化;三个 package.json 标注
Apache-2.0。

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-16 02:10:46 +08:00

27 lines
881 B
SQL

CREATE INDEX IF NOT EXISTS idx_users_admin_registered
ON users(registered_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_orders_admin_created
ON orders(created_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_invoice_requests_admin_requested
ON invoice_requests(requested_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_tickets_admin_updated
ON tickets(updated_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_generation_tasks_admin_created
ON generation_tasks(created_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_credit_ledger_admin_created
ON credit_ledger(created_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_audit_logs_admin_created
ON audit_logs(created_at DESC, id DESC);
CREATE INDEX IF NOT EXISTS idx_tickets_user
ON tickets(user_id);
CREATE INDEX IF NOT EXISTS idx_provider_usage_records_task
ON provider_usage_records(task_id);