Lots of work on the Journals
This commit is contained in:
@@ -2,6 +2,7 @@ import type { key_val } from '$lib/ae_stores';
|
||||
import { api } from '$lib/api';
|
||||
|
||||
import { db_journals } from "$lib/ae_journals/db_journals";
|
||||
import { marked } from 'marked';
|
||||
|
||||
let ae_promises: key_val = {};
|
||||
|
||||
@@ -357,6 +358,7 @@ export async function db_save_ae_obj_li__journal_entry(
|
||||
category_code: obj.category_code,
|
||||
type_code: obj.type_code,
|
||||
topic_code: obj.topic_code,
|
||||
tags: obj.tags,
|
||||
|
||||
public: obj.public,
|
||||
private: obj.private,
|
||||
@@ -369,6 +371,7 @@ export async function db_save_ae_obj_li__journal_entry(
|
||||
// description: obj.description,
|
||||
|
||||
content: obj.content,
|
||||
content_md_html: marked.parse(obj.content),
|
||||
content_html: obj.content_html,
|
||||
content_json: obj.content_json,
|
||||
|
||||
@@ -415,6 +418,12 @@ export async function db_save_ae_obj_li__journal_entry(
|
||||
created_on: obj.created_on,
|
||||
updated_on: obj.updated_on,
|
||||
|
||||
// Generated fields for sorting locally only
|
||||
tmp_sort_1: `${obj.group}_${obj.priority}_${obj.sort}_${obj.updated_on}_${obj.created_on}`,
|
||||
tmp_sort_2: `${obj.group}_${obj.priority}_${obj.sort}_${obj.updated_on ?? obj.created_on}`,
|
||||
// tmp_sort_1: `${obj.original_datetime}_${obj.group}_${obj.priority}_${obj.sort}`,
|
||||
// tmp_sort_2: `${obj.group}_${obj.original_datetime}_${obj.priority}_${obj.sort}`,
|
||||
|
||||
// Generated fields for sorting locally only
|
||||
// tmp_sort_1: `${obj.original_datetime}_${obj.group}_${obj.priority}_${obj.sort}`,
|
||||
// tmp_sort_2: `${obj.group}_${obj.original_datetime}_${obj.priority}_${obj.sort}`,
|
||||
|
||||
Reference in New Issue
Block a user