fix(events): ensure presenters and presentation-level files show correctly

- Harden 'ae_events__event_presenter.ts' to ensure both ID and ID_random fields are synced during refreshes.
- Update presenter list wrapper to use '_id_random' for reliable Dexie queries.
- Enable 'inc_all_file_li' and 'inc_file_li' in session loaders to pre-cache nested files.
- Introduce 'Launcher_presentation_view.svelte' to explicitly display files linked to presentations.
- Refactor presenter views to focus exclusively on speaker-specific files, avoiding UI duplication.
This commit is contained in:
Scott Idem
2026-02-03 19:19:11 -05:00
parent 0809ad3eac
commit 6abe4c897e
8 changed files with 103 additions and 15 deletions

View File

@@ -136,15 +136,35 @@ async function _refresh_presenter_li_background({ api_cfg, for_obj_type, for_obj
const processed = await process_ae_obj__event_presenter_props({ obj_li: result_li, log_lvl });
// String-Only ID Vision: Ensure linking ID is set for indexing
processed.forEach(p => {
if (for_obj_type === 'event_presentation') p.event_presentation_id = for_obj_id;
if (for_obj_type === 'event_session') p.event_session_id = for_obj_id;
if (for_obj_type === 'event') p.event_id = for_obj_id;
processed.forEach((p) => {
if (for_obj_type === 'event_presentation') {
p.event_presentation_id = for_obj_id;
p.event_presentation_id_random = for_obj_id;
}
if (for_obj_type === 'event_session') {
p.event_session_id = for_obj_id;
p.event_session_id_random = for_obj_id;
}
if (for_obj_type === 'event') {
p.event_id = for_obj_id;
p.event_id_random = for_obj_id;
}
});
if (try_cache) {
await db_save_ae_obj_li__ae_obj({ db_instance: db_events, table_name: 'presenter', obj_li: processed, properties_to_save, log_lvl });
}
// Background nested loads for refreshed items (FIRE AND FORGET)
if (inc_file_li) {
processed.forEach(p => {
load_ae_obj_li__event_file({
api_cfg, for_obj_type: 'event_presenter', for_obj_id: p.id,
enabled: 'all', limit: 25, try_cache: false, log_lvl: 0
});
});
}
return processed;
}
} catch (e) {}
@@ -297,4 +317,4 @@ export async function process_ae_obj__event_presenter_props({ obj_li, log_lvl =
if (obj.event_id_random) obj.event_id = obj.event_id_random;
return obj;
}});
}
}