fix(idaa): synchronize Dexie schema with renamed post_comment table

- Renamed 'comment' table to 'post_comment' in db_posts.ts.
- Bumped Dexie database version to 2.
- Resolved InvalidTableError: Table post_comment does not exist.
- Standardized ID mapping for local storage consistency.
This commit is contained in:
Scott Idem
2026-02-05 19:57:22 -05:00
parent 2d4ddd335b
commit a3ec7f8c42

View File

@@ -116,15 +116,15 @@ export interface Post_Comment {
// Additional fields for convenience (database views)
}
// Updated 2024-09-25
// Updated 2026-02-05
export class MySubClassedDexie extends Dexie {
// We just tell the typing system this is the case
post!: Table<Post>;
comment!: Table<Post_Comment>;
post_comment!: Table<Post_Comment>;
constructor() {
super('ae_posts_db');
this.version(1).stores({
this.version(2).stores({
post: `
id, post_id,
account_id,
@@ -136,7 +136,7 @@ export class MySubClassedDexie extends Dexie {
tmp_sort_1, tmp_sort_2,
enable, hide, priority, sort, group, notes, created_on, updated_on, [updated_on+created_on], [created_on+updated_on]`,
comment: `
post_comment: `
id, post_comment_id,
post_id,
name,