Hopefully this works... QR stop and start?
This commit is contained in:
@@ -29,7 +29,7 @@ let lq__event_badge_li = liveQuery(
|
||||
let ae_promises: key_val = {};
|
||||
let load_obj_li_results: Promise<any>|key_val;
|
||||
let search_submit_results: Promise<any>|key_val;
|
||||
let scan_submit_results: Promise<any>|key_val;
|
||||
// let scan_submit_results: Promise<any>|key_val;
|
||||
|
||||
|
||||
$ae_loc.hostname = data.url.hostname;
|
||||
|
||||
@@ -216,7 +216,6 @@ function handle_qr_camera(event) {
|
||||
$events_sess.leads.show_form__scan = true;
|
||||
$events_sess.leads.qr_scan_start = true;
|
||||
}}
|
||||
disabled={!$ae_loc.trusted_access && 2==4}
|
||||
title="Scan a QR code to add a person to the leads list."
|
||||
>
|
||||
<span class="fas fa-qrcode mx-1"></span>
|
||||
@@ -663,7 +662,13 @@ function handle_qr_camera(event) {
|
||||
|
||||
|
||||
<!-- <div class=""> -->
|
||||
<Element_qr_scanner start_qr_scanner={$events_sess.leads.qr_scan_start} show_qr_scan_result={true} show_qr_manual_badge_id_entry_option={true} on:qr_scan_result={handle_qr_scan_result} on:qr_camera={handle_qr_camera} />
|
||||
<Element_qr_scanner
|
||||
start_qr_scanner={$events_sess.leads.qr_scan_start}
|
||||
show_qr_scan_result={true}
|
||||
show_qr_manual_badge_id_entry_option={true}
|
||||
on:qr_scan_result={handle_qr_scan_result}
|
||||
on:qr_camera={handle_qr_camera}
|
||||
/>
|
||||
<!-- </div> -->
|
||||
|
||||
<div class="qr_quick_results variant-soft-secondary font-bold p-4">
|
||||
@@ -794,25 +799,26 @@ function handle_qr_camera(event) {
|
||||
</section> <!-- .popover__content -->
|
||||
|
||||
<footer class="popover__footer flex gap-1 justify-between items-center p-1 border-t">
|
||||
<div class="popover__content__actions">
|
||||
<!-- <div class="popover__content__actions">
|
||||
<button
|
||||
type="submit"
|
||||
form="form__scan_text"
|
||||
type="button"
|
||||
class="btn variant-soft-primary"
|
||||
disabled={scan_submit_results instanceof Promise && !scan_submit_results}
|
||||
on:click={() => {
|
||||
// trigger = 'save__ds__code';
|
||||
// $slct_trigger = 'save__ds__code';
|
||||
$events_sess.leads.qr_scan_start = !$events_sess.leads.qr_scan_start;
|
||||
}}
|
||||
>
|
||||
<span class="fas fa-search mx-1"></span>
|
||||
Scan
|
||||
{#if $events_sess.leads.qr_scan_start}
|
||||
Stop Scanning
|
||||
{:else}
|
||||
Scanning
|
||||
{/if}
|
||||
</button>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class="popover__status">
|
||||
<!-- Something text -->
|
||||
{#await scan_submit_results}
|
||||
<!-- {#await scan_submit_results}
|
||||
<div class="modal-loading">
|
||||
<span class="fas fa-spinner fa-spin"></span>
|
||||
<span class="loading-text">
|
||||
@@ -829,7 +835,7 @@ function handle_qr_camera(event) {
|
||||
</span>
|
||||
</div>
|
||||
{/if}
|
||||
{/await}
|
||||
{/await} -->
|
||||
|
||||
<div
|
||||
class="ae_debug"
|
||||
@@ -844,8 +850,8 @@ function handle_qr_camera(event) {
|
||||
type="button"
|
||||
class="btn variant-soft-primary"
|
||||
on:click={() => {
|
||||
|
||||
$events_sess.leads.show_form__scan = false;
|
||||
$events_sess.leads.qr_scan_start = false;
|
||||
}}
|
||||
>
|
||||
<span class="fas fa-times mx-1"></span>
|
||||
|
||||
Reference in New Issue
Block a user