From 5a341704544cdb081366ba942a30ca3de9ca1daf Mon Sep 17 00:00:00 2001 From: aewing Date: Fri, 2 Jan 2026 02:07:33 +0000 Subject: [PATCH] Fix user display, add logout, footer, optimize performance - Move userDisplay inside tableContainer with proper positioning - Add logout button next to settings - Add footer with user email (left) and version (right) - Fix auth model loading on page refresh - Remove cache clearing on checkbox changes for better performance - Add 150ms debounce to search input - Expand search to include Notes fields - Suppress QUIC protocol console errors from realtime connection - Optimize checkbox change handler --- .env.example | 20 ------- appsettings.html | 2 + estimatortable.html | 127 +++++++++++++++++++++++++++++++------------- server.ts | 6 +-- 4 files changed, 96 insertions(+), 59 deletions(-) delete mode 100644 .env.example diff --git a/.env.example b/.env.example deleted file mode 100644 index 4815f42..0000000 --- a/.env.example +++ /dev/null @@ -1,20 +0,0 @@ -# Azure AD / Microsoft Authentication -CLIENT_ID=your-client-id -CLIENT_SECRET=your-client-secret -TENANT_ID=your-tenant-id -REDIRECT_URI=https://your-domain.com/auth/callback - -# PocketBase Configuration -PB_DB=https://pocketbase.ccllc.pro -PB_COLLECTION=Job_Info_TestEnv -PB_AUTH_COLLECTION=Users - -# Redis/Valkey Configuration (Caching & Search) -# Connect to the same Redis/Valkey instance as Job-Info-Prod -REDIS_URL=redis://localhost:6379 -# For production, use the same connection string as Job-Info-Prod -# Example: REDIS_URL=redis://redis-server:6379 -# Example with auth: REDIS_URL=redis://:password@redis-server:6379 - -# Optional -PORT=3025 diff --git a/appsettings.html b/appsettings.html index bce0808..d2265d9 100644 --- a/appsettings.html +++ b/appsettings.html @@ -250,6 +250,8 @@ console.log('Settings saved to PocketBase successfully'); if (!isAuto) { alert('Settings saved successfully!'); + // Redirect back to estimator table + window.location.href = '/estimatortable.html'; } } catch (error) { console.error('Error saving settings:', error); diff --git a/estimatortable.html b/estimatortable.html index cb7cc71..09f5635 100644 --- a/estimatortable.html +++ b/estimatortable.html @@ -26,6 +26,7 @@ /* Container layout - keep header stationary */ #tableContainer { + position: relative; display: flex; flex-direction: column; height: 100vh; @@ -168,17 +169,6 @@ - - -