文件
chen 301194963b
一些检查失败了
automerge / automerge (push) Has been cancelled
react-native-android-build-apk / AssembleRelease (push) Has been cancelled
Build macOS M1 / Main (push) Has been cancelled
Joplin Continuous Integration / Main (macos-15-intel) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-11-vs2026-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-2025) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04-arm) (push) Has been cancelled
Joplin UI tests / Main (ubuntu-22.04) (push) Has been cancelled
Joplin UI tests / Main (windows-2025) (push) Has been cancelled
Joplin UI tests / Mobile (push) Has been cancelled
Close stale issues / ProcessStaleIssues (push) Has been cancelled
feat: Initial clean release of CHM
2026-11-04 11:29:39 +08:00

26 行
736 B
TypeScript

import { SqlQuery } from '../types';
export default (): (SqlQuery|string)[] => {
return [
`CREATE TABLE chat_conversations (
id TEXT PRIMARY KEY NOT NULL,
title TEXT NOT NULL DEFAULT "",
created_time INT NOT NULL,
updated_time INT NOT NULL
)`,
`CREATE TABLE chat_messages (
id TEXT PRIMARY KEY NOT NULL,
conversation_id TEXT NOT NULL,
role TEXT NOT NULL,
text TEXT NOT NULL DEFAULT "",
raw TEXT NOT NULL DEFAULT "[]",
hide INT NOT NULL DEFAULT 0,
position INT NOT NULL,
created_time INT NOT NULL,
note_id TEXT NOT NULL DEFAULT "",
note_title TEXT NOT NULL DEFAULT ""
)`,
'CREATE UNIQUE INDEX chat_messages_conversation_position ON chat_messages (conversation_id, position)',
];
};