From 9914fd17002214e625dfbc53098a43e2beedb262 Mon Sep 17 00:00:00 2001 From: Scott Idem Date: Fri, 27 Jun 2025 12:44:23 -0400 Subject: [PATCH] General clean up of files. Less debug. Less extra stuff. --- src/lib/ae_archives/ae_archives__archive.ts | 4 +- .../core/{+layout.ts => not_used+layout.ts} | 0 .../10_edit_modal__event_presenter_obj.svelte | 12 ++--- .../10_list__event_presenter_obj.svelte | 4 +- .../events_speakers/[slug]/+page.svelte | 14 +++--- .../idaa/(idaa)/archives/+layout.svelte | 21 ++------ src/routes/idaa/(idaa)/archives/+layout.ts | 28 ++++++----- .../(idaa)/archives/[archive_id]/+layout.ts | 48 ------------------- .../(idaa)/archives/[archive_id]/+page.ts | 21 ++++---- .../archives/[archive_id]/not_used+layout.ts | 4 ++ src/routes/idaa/(idaa)/bb/+layout.svelte | 7 +-- src/routes/idaa/(idaa)/bb/+layout.ts | 22 +++++---- .../(idaa)/recovery_meetings/+layout.svelte | 7 +-- .../idaa/(idaa)/recovery_meetings/+layout.ts | 18 +++---- .../{+page.ts => not_used+page.ts} | 0 ...ut.server.js => not_used+layout.server.js} | 0 ...page.server.ts => not_used+page.server.ts} | 0 src/routes/{+page.ts => not_used+page.ts} | 0 18 files changed, 82 insertions(+), 128 deletions(-) rename src/routes/core/{+layout.ts => not_used+layout.ts} (100%) delete mode 100644 src/routes/idaa/(idaa)/archives/[archive_id]/+layout.ts create mode 100644 src/routes/idaa/(idaa)/archives/[archive_id]/not_used+layout.ts rename src/routes/idaa/(idaa)/recovery_meetings/{+page.ts => not_used+page.ts} (100%) rename src/routes/{+layout.server.js => not_used+layout.server.js} (100%) rename src/routes/{+page.server.ts => not_used+page.server.ts} (100%) rename src/routes/{+page.ts => not_used+page.ts} (100%) diff --git a/src/lib/ae_archives/ae_archives__archive.ts b/src/lib/ae_archives/ae_archives__archive.ts index 7e2fe281..9f5a87b8 100644 --- a/src/lib/ae_archives/ae_archives__archive.ts +++ b/src/lib/ae_archives/ae_archives__archive.ts @@ -95,7 +95,9 @@ export async function load_ae_obj_id__archive( api_cfg: api_cfg, for_obj_type: 'archive', for_obj_id: archive_id, - params: {qry__enabled: 'all', qry__limit: 99}, + enabled: 'all', + limit: 99, + params: params, try_cache: try_cache, log_lvl: log_lvl }) diff --git a/src/routes/core/+layout.ts b/src/routes/core/not_used+layout.ts similarity index 100% rename from src/routes/core/+layout.ts rename to src/routes/core/not_used+layout.ts diff --git a/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte b/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte index 5ba1d7d3..b7e1ba73 100644 --- a/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte +++ b/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte @@ -294,13 +294,13 @@ async function handle_submit_form(event) { if ($slct.event_presenter_id) { if ($store_current_tab == 'start' && $slct.event_presenter_id) { - $store_current_tab = 'biograhpy'; + $store_current_tab = 'biography'; if (!$slct.event_presenter_obj.updated_on) { send_init_confirm_email(); } // Move on to files - } else if ($store_current_tab == 'biograhpy' && $slct.event_presenter_id) { + } else if ($store_current_tab == 'biography' && $slct.event_presenter_id) { $store_current_tab = 'files'; // Move on to summary @@ -712,8 +712,8 @@ async function handle_delete_event_presenter_obj({event_presenter_id, hosted_fil --> {@render children?.()} - - \ No newline at end of file diff --git a/src/routes/idaa/(idaa)/archives/+layout.ts b/src/routes/idaa/(idaa)/archives/+layout.ts index 85baa64a..30622f87 100644 --- a/src/routes/idaa/(idaa)/archives/+layout.ts +++ b/src/routes/idaa/(idaa)/archives/+layout.ts @@ -1,7 +1,7 @@ /** @type {import('./$types').LayoutLoad} */ console.log(`IDAA BB - [account_id] +layout.ts start`); -import { error } from '@sveltejs/kit'; +// import { error } from '@sveltejs/kit'; import { browser } from '$app/environment'; import { archives_func } from '$lib/ae_archives/ae_archives_functions'; @@ -15,31 +15,33 @@ export async function load({ fetch, params, parent }) { // route let ae_acct = data[account_id]; // console.log(`ae_acct = `, ae_acct); - if (!account_id) { - console.log(`ae IDAA Archives - [account_id] +page.ts: The account_id was not found!!!`); - error(404, { - message: 'Account ID not found' - }); - } + // if (!account_id) { + // console.log(`ae IDAA Archives - [account_id] +page.ts: The account_id was not found!!!`); + // error(404, { + // message: 'Account ID not found' + // }); + // } - ae_acct.slct.account_id = account_id; + // ae_acct.slct.account_id = account_id; if (browser) { - let load_event_obj_li = archives_func.load_ae_obj_li__archive({ + let load_archive_obj_li = archives_func.load_ae_obj_li__archive({ api_cfg: ae_acct.api, for_obj_type: 'account', for_obj_id: account_id, inc_content_li: true, enabled: 'enabled', hidden: 'not_hidden', - limit: 20, + limit: 29, order_by_li: {'priority': 'DESC', 'sort': 'DESC', 'updated_on': 'DESC', 'created_on': 'DESC', 'name': 'ASC'}, params: params, try_cache: true, - log_lvl: 2 + log_lvl: log_lvl }); - console.log(`load_event_obj_li = `, load_event_obj_li); - ae_acct.slct.event_obj_li = load_event_obj_li; + if (log_lvl) { + console.log(`load_archive_obj_li = `, load_archive_obj_li); + } + ae_acct.slct.archive_obj_li = load_archive_obj_li; } // WARNING: Precaution against shared data between sites and sessions. diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/+layout.ts b/src/routes/idaa/(idaa)/archives/[archive_id]/+layout.ts deleted file mode 100644 index 03be851a..00000000 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/+layout.ts +++ /dev/null @@ -1,48 +0,0 @@ -/** @type {import('./$types').LayoutLoad} */ -// console.log(`IDAA Archives - [archive_id] +layout.ts start`); - -// import { error } from '@sveltejs/kit'; -// import { browser } from '$app/environment'; -// import { archives_func } from '$lib/ae_archives/ae_archives_functions'; - -export async function load({ params, parent }) { // route - // let log_lvl: number = 0; - - // let data = await parent(); - // data.log_lvl = log_lvl; - - // let account_id = data.account_id; - // let ae_acct = data[account_id]; - // console.log(`ae_acct = `, ae_acct); - - // let archive_id = params.archive_id; - // if (!archive_id) { - // console.log(`ae IDAA Archives - [archive_id] +layout.ts: The archive_id was not found!!!`); - // error(404, { - // message: 'IDAA Archives - Archive ID not found' - // }); - // } - - // ae_acct.slct.archive_id = archive_id; - - // if (browser) { - // if (log_lvl) { - // console.log(`ae_idaa_archives archives [archive_id] +layout.ts: archive_id = `, archive_id); - // } - // // Load event archive object - // let load_archive_obj = archives_func.load_ae_obj_id__archive({ - // api_cfg: ae_acct.api, - // archive_id: archive_id, - // inc_content_li: true, - // try_cache: true - // }); - - // console.log(`load_archive_obj = `, load_archive_obj); - // ae_acct.slct.archive_obj = load_archive_obj; - // } - - // WARNING: Precaution against shared data between sites and sessions. - // data[account_id] = ae_acct; - - // return data; -} diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts index c73417a6..553b4c69 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts @@ -1,5 +1,5 @@ /** @type {import('./$types').PageLoad} */ -import { error } from '@sveltejs/kit'; +// import { error } from '@sveltejs/kit'; console.log(`ae_p_idaa_archives [archive_id] +page.ts start`); import { browser } from '$app/environment'; @@ -15,12 +15,12 @@ export async function load({ params, parent }) { // route let ae_acct = data[account_id]; let archive_id = params.archive_id; - if (!archive_id) { - console.log(`ae_idaa_archives archives [archive_id] +page.ts: The archive_id was not found in the params!!!`); - error(404, { - message: 'IDAA Archives - Archive ID not found' - }); - } + // if (!archive_id) { + // console.log(`ae_idaa_archives archives [archive_id] +page.ts: The archive_id was not found in the params!!!`); + // error(404, { + // message: 'IDAA Archives - Archive ID not found' + // }); + // } ae_acct.slct.archive_id = archive_id; if (browser) { @@ -32,9 +32,12 @@ export async function load({ params, parent }) { // route api_cfg: ae_acct.api, archive_id: archive_id, inc_content_li: true, - try_cache: true + try_cache: true, + log_lvl: log_lvl }); - + if (log_lvl) { + console.log(`load_archive_obj = `, load_archive_obj); + } ae_acct.slct.archive_obj = load_archive_obj; // Load archive contents for the archive diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/not_used+layout.ts b/src/routes/idaa/(idaa)/archives/[archive_id]/not_used+layout.ts new file mode 100644 index 00000000..2989cee7 --- /dev/null +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/not_used+layout.ts @@ -0,0 +1,4 @@ +/** @type {import('./$types').LayoutLoad} */ + +export async function load({ params, parent }) { // route +} diff --git a/src/routes/idaa/(idaa)/bb/+layout.svelte b/src/routes/idaa/(idaa)/bb/+layout.svelte index 471f8533..b207dc33 100644 --- a/src/routes/idaa/(idaa)/bb/+layout.svelte +++ b/src/routes/idaa/(idaa)/bb/+layout.svelte @@ -1,8 +1,5 @@