diff --git a/src/routes/core/addresses/+page.svelte b/src/routes/core/addresses/+page.svelte index 52867d5b..436983ec 100644 --- a/src/routes/core/addresses/+page.svelte +++ b/src/routes/core/addresses/+page.svelte @@ -2,13 +2,24 @@ import { onMount } from 'svelte'; import { ae_loc, ae_api, slct } from '$lib/stores/ae_stores'; import { goto } from '$app/navigation'; - import { MapPin, Plus, Search, ExternalLink, X, ListFilter, MapPinned } from 'lucide-svelte'; + import { MapPin, Plus, Search, ExternalLink, X, ListFilter, MapPinned, Globe, Building2 } from 'lucide-svelte'; import { load_ae_obj_li__address, create_ae_obj__address } from '$lib/ae_core/ae_core__address'; import Address_form from './ae_comp__address_form.svelte'; let address_li: any[] = $state([]); let loading = $state(true); let show_add_form = $state(false); + let qry_str = $state(''); + let filtered_li: any[] = $derived( + qry_str + ? address_li.filter(a => + a.city?.toLowerCase().includes(qry_str.toLowerCase()) || + a.state_province?.toLowerCase().includes(qry_str.toLowerCase()) || + a.organization_name?.toLowerCase().includes(qry_str.toLowerCase()) || + a.line_1?.toLowerCase().includes(qry_str.toLowerCase()) + ) + : address_li + ); async function load_addresses() { if (!$ae_loc.account_id) return; @@ -67,11 +78,35 @@ {/if} +
+
+ +
+
+ +
+ + +
+
+
+ {#if loading}
- {:else if address_li.length === 0} + {:else if filtered_li.length === 0}

No Addresses Found

@@ -79,43 +114,49 @@
{:else}
-

+

Linked Addresses - {address_li.length} entries + {filtered_li.length} entries

-
- - - - - - - - - - - - {#each address_li as addr} - - - - - - - - {/each} - -
CityState/ProvinceCountryStatusActions
{addr.city || '--'}{addr.state_province || '--'}{addr.country || '--'} - - {addr.enable ? 'Active' : 'Disabled'} - - - - Manage - -
+
+ {#each filtered_li as addr} +
+
+ + {addr.enable ? 'Active' : 'Disabled'} + +
+ +
+
+ +
+
+

{addr.city || '--'}

+

{addr.state_province || '--'}

+
+
+ +
+ {#if addr.organization_name} +
+ + {addr.organization_name} +
+ {/if} +
+ + {addr.country_name || addr.country || '--'} +
+
+ + + View Details + +
+ {/each}
{/if} diff --git a/src/routes/core/addresses/[address_id]/+page.svelte b/src/routes/core/addresses/[address_id]/+page.svelte index b3fa0e80..334d46bd 100644 --- a/src/routes/core/addresses/[address_id]/+page.svelte +++ b/src/routes/core/addresses/[address_id]/+page.svelte @@ -9,7 +9,7 @@ import { editable_fields__address } from '$lib/ae_core/ae_core__address.editable_fields'; import { ae_api, ae_loc } from '$lib/stores/ae_stores'; import { goto } from '$app/navigation'; - import { Save, Trash2, ArrowLeft, MapPin, Edit, Eye } from 'lucide-svelte'; + import { Save, Trash2, ArrowLeft, MapPin, Edit, Eye, Globe, Building2, MapPinned, Info, ShieldCheck, Activity, Clock, User } from 'lucide-svelte'; import Address_form from '../ae_comp__address_form.svelte'; let address_id = $page.params.address_id; @@ -48,123 +48,162 @@
-
+
- + -
- -

{address ? `${address.city}, ${address.state_province}` : 'Loading Address...'}

+
+
+ +
+
+

{address ? `${address.city}, ${address.state_province}` : 'Loading...'}

+

Address Detail

+
- -
{#if loading} -
+
+
+
{:else if address} {#if is_editing} - { - address = updated; - is_editing = false; - }} - onCancel={() => is_editing = false} - /> +
+ { + address = updated; + is_editing = false; + }} + onCancel={() => is_editing = false} + /> +
{:else} -
+
-
-

Address Details

-
-
-

Attention To

-

{address.attention_to || '--'}

+
+

+ + Location Information +

+
+
+

+ Attention To +

+

{address.attention_to || '--'}

-
-

Organization

-

{address.organization_name || '--'}

+
+

+ Organization +

+

{address.organization_name || '--'}

-
-

Address Lines

-

{address.line_1}

- {#if address.line_2}

{address.line_2}

{/if} - {#if address.line_3}

{address.line_3}

{/if} +
+

Street Address

+
+

{address.line_1}

+ {#if address.line_2}

{address.line_2}

{/if} + {#if address.line_3}

{address.line_3}

{/if} +
-
-

City, State/Province

-

{address.city}, {address.state_province || '--'}

+
+

+ City, State/Province +

+

{address.city}, {address.state_province || '--'}

-
-

Postal Code / Country

-

{address.postal_code || '--'} / {address.country_name || address.country || '--'}

+
+

+ Postal Code / Country +

+

{address.postal_code || '--'} / {address.country_name || address.country || '--'}

-
-

Technical Details

-
-
-

Timezone

-

{address.timezone || '--'}

+
+

+ + Technical Details +

+
+
+

+ Timezone +

+

{address.timezone || '--'}

-
-

Coordinates

-

{address.latitude || '--'}, {address.longitude || '--'}

+
+

+ Coordinates +

+

{address.latitude || '--'}, {address.longitude || '--'}

-
-

Internal Notes

-

{address.notes || '--'}

+
+

+ Internal Notes +

+
+ {address.notes || 'No internal notes provided for this address.'} +
-
-

Status

-
-
- Enabled - - {address.enable ? 'Yes' : 'No'} +
+

+ + Visibility & Status +

+
+
+ Enabled + + {address.enable ? 'ACTIVE' : 'DISABLED'}
-
- Hidden - - {address.hide ? 'Yes' : 'No'} +
+ Hidden + + {address.hide ? 'YES' : 'NO'}
-
- Priority - - {address.priority ? 'Yes' : 'No'} +
+ Priority + + {address.priority ? 'YES' : 'NO'}
-
-

ID: {address.address_id_random}

-

Created: {new Date(address.created_on).toLocaleString()}

- {#if address.updated_on} -

Updated: {new Date(address.updated_on).toLocaleString()}

- {/if} +
+

System Audit

+
+

ID: {address.address_id_random}

+

Created: {new Date(address.created_on).toLocaleString()}

+ {#if address.updated_on} +

Updated: {new Date(address.updated_on).toLocaleString()}

+ {/if} +
diff --git a/src/routes/core/contacts/+page.svelte b/src/routes/core/contacts/+page.svelte index c8d1baa1..5375aea3 100644 --- a/src/routes/core/contacts/+page.svelte +++ b/src/routes/core/contacts/+page.svelte @@ -2,11 +2,22 @@ import { onMount } from 'svelte'; import { ae_loc, ae_api, slct } from '$lib/stores/ae_stores'; import { goto } from '$app/navigation'; - import { Phone, Plus, Search, Mail, User, ExternalLink, X, ListFilter, Contact } from 'lucide-svelte'; + import { Phone, Plus, Search, Mail, User, ExternalLink, X, ListFilter, Contact, ShieldCheck, Activity } from 'lucide-svelte'; import { load_ae_obj_li__contact, create_ae_obj__contact } from '$lib/ae_core/ae_core__contact'; import Contact_form from './ae_comp__contact_form.svelte'; let contact_li: any[] = $state([]); + let qry_str = $state(''); + let filtered_li: any[] = $derived( + qry_str + ? contact_li.filter(c => + c.name?.toLowerCase().includes(qry_str.toLowerCase()) || + c.title?.toLowerCase().includes(qry_str.toLowerCase()) || + c.email?.toLowerCase().includes(qry_str.toLowerCase()) || + c.phone_office?.toLowerCase().includes(qry_str.toLowerCase()) + ) + : contact_li + ); let loading = $state(true); let show_add_form = $state(false); @@ -67,11 +78,35 @@
{/if} +
+
+ +
+
+ +
+ + +
+
+
+ {#if loading}
- {:else if contact_li.length === 0} + {:else if filtered_li.length === 0}

No Contacts Found

@@ -79,61 +114,47 @@
{:else}
-

+

Directory Results - {contact_li.length} entries + {filtered_li.length} entries

- -
- - - - - - - - - - - - {#each contact_li as con} - - - - - - - - {/each} - -
Name / TitleEmailPhoneStatusActions
-
-
- -
- {con.title || con.name || '--'} -
-
- {#if con.email} -
- - {con.email} -
- {:else} - No Email - {/if} -
- {con.phone_office || con.phone_mobile || '--'} - - - {con.enable ? 'Active' : 'Disabled'} - - - - Manage - -
+ +
+ {#each filtered_li as con} +
+
+ + {con.enable ? 'Active' : 'Disabled'} + +
+ +
+
+ +
+
+

{con.name || con.title || '--'}

+

{con.title || 'Support Contact'}

+
+
+ +
+
+ + {con.email || 'No Email'} +
+
+ + {con.phone_office || con.phone_mobile || '--'} +
+
+ + + Manage Contact + +
+ {/each}
{/if} diff --git a/src/routes/core/contacts/[contact_id]/+page.svelte b/src/routes/core/contacts/[contact_id]/+page.svelte index 553015f7..145bb115 100644 --- a/src/routes/core/contacts/[contact_id]/+page.svelte +++ b/src/routes/core/contacts/[contact_id]/+page.svelte @@ -9,7 +9,7 @@ import { editable_fields__contact } from '$lib/ae_core/ae_core__contact.editable_fields'; import { ae_api, ae_loc } from '$lib/stores/ae_stores'; import { goto } from '$app/navigation'; - import { Save, Trash2, ArrowLeft, UserRound, Edit, Eye } from 'lucide-svelte'; + import { Save, Trash2, ArrowLeft, UserRound, Edit, Eye, Mail, Phone, Globe, Linkedin, Info, ShieldCheck, Activity, Link2, Contact } from 'lucide-svelte'; import Contact_form from '../ae_comp__contact_form.svelte'; let contact_id = $page.params.contact_id; @@ -48,134 +48,166 @@
-
+
- + -
- -

{contact?.name || contact?.title || 'Loading Contact...'}

+
+
+ +
+
+

{contact?.name || contact?.title || 'Loading...'}

+

Contact Detail

+
- -
{#if loading} -
+
+
+
{:else if contact} {#if is_editing} - { - contact = updated; - is_editing = false; - }} - onCancel={() => is_editing = false} - /> +
+ { + contact = updated; + is_editing = false; + }} + onCancel={() => is_editing = false} + /> +
{:else} -
+
-
-

Contact Details

-
-
-

Title / Name

-

{contact.title || contact.name || '--'}

-
-
-

Tagline

-

{contact.tagline || '--'}

-
-
-

Email

-

{contact.email || '--'}

-
-
-

Website

-

- {#if contact.website_url} - {contact.website_url} - {:else} - -- - {/if} +

+

+ + Core Information +

+
+
+

+ Full Name / Title

+

{contact.name || contact.title || '--'}

+
+
+

+ Tagline / Role +

+

{contact.tagline || '--'}

+
+
+

+ Email Address +

+

{contact.email || '--'}

+
+
+

+ Website +

+ {#if contact.website_url} + + {contact.website_url} + + {:else} +

--

+ {/if}
-
-

Communication & Social

-
-
-

Mobile Phone

-

{contact.phone_mobile || contact.phone || '--'}

+
+

+ + Communication & Social +

+
+
+

+ Mobile Phone +

+

{contact.phone_mobile || contact.phone || '--'}

-
-

Office Phone

-

{contact.phone_office || '--'}

+
+

+ Office Phone +

+

{contact.phone_office || '--'}

-
-

LinkedIn

-

{contact.linkedin_url || '--'}

+
+

+ LinkedIn +

+

{contact.linkedin_url || '--'}

-
-

Socials

-
- {#if contact.facebook_url}FB{/if} - {#if contact.instagram_url}IG{/if} +
+

+ Internal Notes +

+
+ {contact.notes || 'No internal notes provided for this contact.'}
-
-

Internal Notes

-

{contact.notes || '--'}

-
-
-

Status

-
-
- Enabled - - {contact.enable ? 'Yes' : 'No'} +
+

+ + Status & Flags +

+
+
+ Enabled + + {contact.enable ? 'ACTIVE' : 'DISABLED'}
-
- Hidden - - {contact.hide ? 'Yes' : 'No'} +
+ Hidden + + {contact.hide ? 'YES' : 'NO'}
-
- Priority - - {contact.priority ? 'Yes' : 'No'} +
+ Priority + + {contact.priority ? 'YES' : 'NO'}
-
-

ID: {contact.contact_id_random}

-

Created: {new Date(contact.created_on).toLocaleString()}

- {#if contact.updated_on} -

Updated: {new Date(contact.updated_on).toLocaleString()}

- {/if} +
+

System Audit

+
+

ID: {contact.contact_id_random}

+

Created: {new Date(contact.created_on).toLocaleString()}

+ {#if contact.updated_on} +

Updated: {new Date(contact.updated_on).toLocaleString()}

+ {/if} +
diff --git a/src/routes/core/people/ae_comp__person_search.svelte b/src/routes/core/people/ae_comp__person_search.svelte index 36304ea1..1ba05e32 100644 --- a/src/routes/core/people/ae_comp__person_search.svelte +++ b/src/routes/core/people/ae_comp__person_search.svelte @@ -46,20 +46,22 @@
-
-
+
+
+ +
e.key === 'Enter' && handle_search()} /> -
diff --git a/src/routes/core/users/+page.svelte b/src/routes/core/users/+page.svelte index d1c7694e..286923b8 100644 --- a/src/routes/core/users/+page.svelte +++ b/src/routes/core/users/+page.svelte @@ -83,20 +83,22 @@
-
-
+
+
+ +
e.key === 'Enter' && load_users()} /> -