I quite for the night! The presentation list shows now...
This commit is contained in:
@@ -59,6 +59,7 @@ let lq__event_presentation_obj_li = liveQuery(
|
||||
.sortBy('name')
|
||||
);
|
||||
|
||||
// FIX! This id list needs to be updated. It is currently commented out in the menu_session_list.svelte file.
|
||||
let lq_get__event_presentation_obj_li = liveQuery(
|
||||
() => db_events.presentations
|
||||
.bulkGet($events_slct.id_li__event_presentation)
|
||||
@@ -134,12 +135,14 @@ let link_to_id: null|string = null;
|
||||
<div><strong>Presentations:</strong></div>
|
||||
|
||||
|
||||
{$lq_get__event_presentation_obj_li?.length}
|
||||
{$lq__event_presentation_obj_li?.length}
|
||||
|
||||
{#if $lq_get__event_presentation_obj_li}
|
||||
{$lq__event_session_obj?.event_presentation_li?.length ?? 'loading...?'}
|
||||
|
||||
{#if $lq__event_presentation_obj_li}
|
||||
Presentations:
|
||||
<ul class="event_presentation_list">
|
||||
{#each $lq_get__event_presentation_obj_li as event_presentation_obj}
|
||||
{#each $lq__event_presentation_obj_li as event_presentation_obj}
|
||||
<li>
|
||||
<div class="event_presentation_datetime_name">
|
||||
{#if event_presentation_obj?.start_datetime}
|
||||
@@ -149,6 +152,7 @@ let link_to_id: null|string = null;
|
||||
<span class="event_presentation_name">{event_presentation_obj?.name}</span>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- {#if 1==3 && event_presentation_obj?.event_presenter_list.length}
|
||||
<ul>
|
||||
{#each event_presentation_obj?.event_presenter_list as event_presenter_obj, index}
|
||||
|
||||
@@ -60,7 +60,9 @@ let ae_promises: key_val = {
|
||||
ae_promises.slct_event_session_id = await events_func.handle_load_ae_obj_id__event_session({
|
||||
api_cfg: $ae_api,
|
||||
event_session_id: event_session_obj?.id,
|
||||
try_cache: true
|
||||
inc_presenter_li: true,
|
||||
try_cache: true,
|
||||
log_lvl: 1
|
||||
})
|
||||
.then(async (load_results) => {
|
||||
console.log(`load_results = `, load_results);
|
||||
@@ -70,41 +72,42 @@ let ae_promises: key_val = {
|
||||
goto(new_url, {replaceState: false});
|
||||
});
|
||||
|
||||
ae_promises.slct_event_presentation_li = await events_func.handle_load_ae_obj_li__event_presentation({
|
||||
api_cfg: $ae_api,
|
||||
event_session_id: event_session_obj?.id,
|
||||
try_cache: true,
|
||||
log_lvl: 1
|
||||
})
|
||||
.then(async (load_results) => {
|
||||
console.log(`load_results = `, load_results);
|
||||
// ae_promises.slct_event_presentation_li = await events_func.handle_load_ae_obj_li__event_presentation({
|
||||
// api_cfg: $ae_api,
|
||||
// event_session_id: event_session_obj?.id,
|
||||
// try_cache: true,
|
||||
// log_lvl: 1
|
||||
// })
|
||||
// .then(async (load_results) => {
|
||||
// console.log(`load_results = `, load_results);
|
||||
|
||||
let event_presentation_id_li = [];
|
||||
// let event_presentation_id_li = [];
|
||||
|
||||
let tmp_li = []; // This is to prevent the array from constantly updating and triggering the liveQuery.
|
||||
// let tmp_li = []; // This is to prevent the array from constantly updating and triggering the liveQuery.
|
||||
|
||||
for (let i = 0; i < load_results.length; i++) {
|
||||
let event_presentation_obj = load_results[i];
|
||||
let event_presentation_id_random = event_presentation_obj.event_presentation_id_random;
|
||||
tmp_li.push(event_presentation_id_random);
|
||||
}
|
||||
event_presentation_id_li = tmp_li;
|
||||
console.log(`event_presentation_id_li:`, event_presentation_id_li);
|
||||
$events_slct.id_li__event_presentation = event_presentation_id_li;
|
||||
// for (let i = 0; i < load_results.length; i++) {
|
||||
// let event_presentation_obj = load_results[i];
|
||||
// let event_presentation_id_random = event_presentation_obj.event_presentation_id_random;
|
||||
// tmp_li.push(event_presentation_id_random);
|
||||
// }
|
||||
// event_presentation_id_li = tmp_li;
|
||||
// console.log(`event_presentation_id_li:`, event_presentation_id_li);
|
||||
// $events_slct.id_li__event_presentation = event_presentation_id_li;
|
||||
|
||||
data_url.searchParams.set('presentation_li', event_presentation_id_li);
|
||||
// data_url.searchParams.set('presentation_li', event_presentation_id_li);
|
||||
|
||||
// let new_url = data_url.toString();
|
||||
// console.log(new_url);
|
||||
// goto(new_url, {replaceState: false});
|
||||
// // let new_url = data_url.toString();
|
||||
// // console.log(new_url);
|
||||
// // goto(new_url, {replaceState: false});
|
||||
|
||||
// return load_results;
|
||||
// // return load_results;
|
||||
|
||||
// });
|
||||
|
||||
});
|
||||
// await tick();
|
||||
let new_url = data_url.toString();
|
||||
console.log(new_url);
|
||||
goto(new_url, {replaceState: false});
|
||||
// let new_url = data_url.toString();
|
||||
// console.log(new_url);
|
||||
// goto(new_url, {replaceState: false});
|
||||
}}
|
||||
>
|
||||
{event_session_obj?.name}
|
||||
|
||||
Reference in New Issue
Block a user