diff --git a/src/lib/ae_archives/ae_archives__archive_content.ts b/src/lib/ae_archives/ae_archives__archive_content.ts index ccb6ef3d..1c776664 100644 --- a/src/lib/ae_archives/ae_archives__archive_content.ts +++ b/src/lib/ae_archives/ae_archives__archive_content.ts @@ -33,11 +33,11 @@ export async function load_ae_obj_id__archive_content( params: params, log_lvl: log_lvl }) - .then(function (archive_content_obj_get_result) { + .then(async function (archive_content_obj_get_result) { if (archive_content_obj_get_result) { if (try_cache) { // This is expecting a list - db_save_ae_obj_li__archive_content({ + await db_save_ae_obj_li__archive_content({ obj_type: 'archive_content', obj_li: [archive_content_obj_get_result] @@ -104,10 +104,10 @@ export async function load_ae_obj_li__archive_content( params: params, log_lvl: log_lvl }) - .then(function (archive_content_obj_li_get_result) { + .then(async function (archive_content_obj_li_get_result) { if (archive_content_obj_li_get_result) { if (try_cache) { - db_save_ae_obj_li__archive_content({ + await db_save_ae_obj_li__archive_content({ obj_type: 'archive_content', obj_li: archive_content_obj_li_get_result }); } @@ -158,9 +158,9 @@ export async function create_ae_obj__archive_content( return_obj: true, log_lvl: log_lvl }) - .then(function (archive_content_obj_create_result) { + .then(async function (archive_content_obj_create_result) { if (archive_content_obj_create_result) { - db_save_ae_obj_li__archive_content( + await db_save_ae_obj_li__archive_content( { obj_type: 'archive_content', obj_li: [archive_content_obj_create_result] @@ -214,10 +214,10 @@ export async function update_ae_obj__archive_content( return_obj: true, log_lvl: log_lvl }) - .then(function (archive_content_obj_update_result) { + .then(async function (archive_content_obj_update_result) { if (archive_content_obj_update_result) { if (try_cache) { - db_save_ae_obj_li__archive_content({ + await db_save_ae_obj_li__archive_content({ obj_type: 'archive_content', obj_li: [archive_content_obj_update_result] }); } @@ -241,7 +241,7 @@ export async function update_ae_obj__archive_content( // This function will loop through the archive_content_obj_li and save each one to the DB. // Updated 2024-09-25 -export function db_save_ae_obj_li__archive_content( +export async function db_save_ae_obj_li__archive_content( { obj_type, obj_li, diff --git a/src/lib/ae_core/ae_comp__hosted_files_upload.svelte b/src/lib/ae_core/ae_comp__hosted_files_upload.svelte new file mode 100644 index 00000000..2d936458 --- /dev/null +++ b/src/lib/ae_core/ae_comp__hosted_files_upload.svelte @@ -0,0 +1,305 @@ + + + + +
diff --git a/src/lib/ae_core/ae_core_functions.ts b/src/lib/ae_core/ae_core_functions.ts index 558f4740..d86eaba7 100644 --- a/src/lib/ae_core/ae_core_functions.ts +++ b/src/lib/ae_core/ae_core_functions.ts @@ -38,6 +38,10 @@ import { load_ae_obj_li__country_subdivision } from "$lib/ae_core/core__country_subdivisions"; +import { + delete_ae_obj_id__hosted_file +} from "$lib/ae_core/core__hosted_files"; + let ae_promises: key_val = {}; // Promise