Re-work of site permissions and Novi permissions.

This commit is contained in:
Scott Idem
2024-11-21 14:19:08 -05:00
parent fcec4ed96f
commit cffde76c88
6 changed files with 197 additions and 127 deletions

View File

@@ -141,23 +141,50 @@ $: if ($ae_loc.iframe && $ae_loc.iframe_height && $ae_loc.iframe_height_modal_bo
</svelte:head>
{#if ($ae_loc.authenticated_access)}
<div
bind:clientHeight={$ae_loc.iframe_height}
>
<slot />
</div>
{:else}
<div class="container flex flex-col gap-1 w-full items-center justify-center font-bold p-8 m-8">
<h1>
<span class="text-red-500">
<span class="fas fa-exclamation-triangle"></span>
Access Denied
<span class="fas fa-exclamation-triangle"></span>
{#if ($ae_loc.trusted_access || ($ae_loc.authenticated_access && $idaa_loc.novi_uuid))}
<div
bind:clientHeight={$ae_loc.iframe_height}
>
<slot />
</div>
{#if $idaa_loc.novi_uuid}
<span class="text-sm text-gray-500">
Novi: <span class="fas fa-user m-1"></span>
{$idaa_loc.novi_uuid}
{$idaa_loc.novi_full_name ?? 'name not set'}
{$idaa_loc.novi_email ?? 'email not set'}
</span>
</h1>
<p>You do not have access to this page.</p>
</div>
{:else}
<p class="text-sm text-gray-500 text-center">IDAA Novi UUID not found!</p>
{/if}
{:else}
<div class="container flex flex-col gap-1 w-full items-center justify-center font-bold p-8 m-8">
<h1>
<span class="text-red-500">
<span class="fas fa-exclamation-triangle"></span>
Access Denied
<span class="fas fa-exclamation-triangle"></span>
</span>
</h1>
<p>You do not have access to these IDAA page.</p>
{#if $ae_loc.iframe}
In iframe mode
{/if}
{#if $idaa_loc.novi_uuid}
<span class="text-sm text-gray-500">
Novi: <span class="fas fa-user m-1"></span>
{$idaa_loc.novi_uuid}
{$idaa_loc.novi_full_name ?? 'name not set'}
{$idaa_loc.novi_email ?? 'email not set'}
</span>
{:else}
<p>IDAA Novi UUID not found!</p>
{/if}
</div>
{/if}