Files
AIclinicalresearch/backend/create_mock_user.sql
HaHafeng 4ed67a8846 fix(admin): Fix Prompt management list not showing version info and add debug diagnostics
Summary:
- Fix Prompt list API response schema missing activeVersion and draftVersion fields
- Fastify was filtering out undefined schema fields, causing version columns to show empty
- Add detailed diagnostic logging for Prompt debug mode troubleshooting
- Verify debug mode works correctly (DRAFT version is used when debug enabled)

Changes:
- backend/src/common/prompt/prompt.routes.ts: Add activeVersion and draftVersion to response schema
- backend/src/common/prompt/prompt.service.ts: Add diagnostic logs for setDebugMode and get methods
- PKB module: Various authentication and document handling fixes from previous session

Tested: Debug mode verified working - v2 DRAFT version correctly loaded when debug enabled
2026-01-13 22:22:10 +08:00

25 lines
393 B
SQL

-- 在 public.users 中创建 mock 用户
-- 用于 RVW 模块的测试
INSERT INTO public.users (id, email, password, name, role, status, kb_quota, kb_used, is_trial, created_at, updated_at)
VALUES (
'user-mock-001',
'mock@test.com',
'$2b$10$mockhashedpassword123456789',
'测试用户',
'user',
'active',
3,
0,
false,
NOW(),
NOW()
)
ON CONFLICT (id) DO NOTHING;