feat: add advanced analytics and territory management system

- Add comprehensive analytics components with export functionality
- Implement territory management with manager performance tracking
- Add seatmap components for venue layout management
- Create customer management features with modal interface
- Add advanced hooks for dashboard flags and territory data
- Implement seat selection and venue management utilities
- Add type definitions for ticketing and seatmap systems

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-08-26 09:25:10 -06:00
parent d5c3953888
commit aa81eb5adb
438 changed files with 90509 additions and 2787 deletions

View File

@@ -16,6 +16,25 @@ test.describe('Smoke Tests', () => {
});
});
test('events page loads successfully after authentication', async ({ page }) => {
// Login first
await page.goto('/login');
await page.click('[data-testid="demo-user-sarah-admin"]');
await page.click('button[type="submit"]');
await page.waitForURL(/\/(dashboard|$)/, { timeout: 10000 });
// Now visit events page
await page.goto('/events');
// Should show events page content
await expect(page.locator('text=Events')).toBeVisible();
await page.screenshot({
path: 'screenshots/smoke_events_page_loads.png',
fullPage: true
});
});
test('login page elements are present', async ({ page }) => {
await page.goto('/login');
@@ -25,9 +44,9 @@ test.describe('Smoke Tests', () => {
await expect(page.locator('input[name="password"]')).toBeVisible();
await expect(page.locator('button[type="submit"]')).toBeVisible();
// Check for demo accounts
await expect(page.locator('text=Demo Accounts')).toBeVisible();
await expect(page.locator('text=Sarah Admin')).toBeVisible();
// Check for demo accounts section
await expect(page.locator('h3:has-text("Demo Accounts")')).toBeVisible();
await expect(page.locator('[data-testid="demo-user-sarah-admin"]')).toBeVisible();
await page.screenshot({
path: 'screenshots/smoke_login_elements.png',
@@ -38,8 +57,14 @@ test.describe('Smoke Tests', () => {
test('theme toggle works', async ({ page }) => {
await page.goto('/login');
// Look for theme toggle button (sun or moon icon)
const themeButton = page.locator('button[aria-label*="theme"], button[aria-label*="Theme"]').first();
// Theme toggle is only available on authenticated pages
// Login first to test theme toggle
await page.click('[data-testid="demo-user-sarah-admin"]');
await page.click('button[type="submit"]');
await page.waitForURL(/\/(dashboard|$)/, { timeout: 10000 });
// Look for theme toggle button with correct aria-label
const themeButton = page.locator('button[aria-label*="Switch to"]').first();
if (await themeButton.isVisible()) {
await themeButton.click();
@@ -57,8 +82,8 @@ test.describe('Smoke Tests', () => {
test('basic authentication flow works', async ({ page }) => {
await page.goto('/login');
// Use demo account
await page.click('text=Sarah Admin');
// Use demo account - click the Sarah Admin demo button
await page.click('[data-testid="demo-user-sarah-admin"]');
// Verify form is filled
await expect(page.locator('input[name="email"]')).toHaveValue('admin@example.com');
@@ -70,8 +95,9 @@ test.describe('Smoke Tests', () => {
// Wait for navigation
await page.waitForURL(/\/(dashboard|$)/, { timeout: 10000 });
// Should show user info
await expect(page.locator('text=Sarah Admin')).toBeVisible();
// Should show user info in header user menu button
await expect(page.locator('[data-testid="user-menu-button"]')).toBeVisible();
await expect(page.locator('[data-testid="user-menu-button"]:has-text("Sarah Admin")')).toBeVisible();
await page.screenshot({
path: 'screenshots/smoke_auth_success.png',