Add NAHV Sales & Lead Management Platform#1278
Open
pimholthof wants to merge 7 commits intoruvnet:mainfrom
Open
Add NAHV Sales & Lead Management Platform#1278pimholthof wants to merge 7 commits intoruvnet:mainfrom
pimholthof wants to merge 7 commits intoruvnet:mainfrom
Conversation
- Backend: Express + TypeScript + SQLite (better-sqlite3) - REST API: /api/leads, /api/pipeline, /api/analytics - CRUD voor leads en deals - Pipeline stages met seed data (6 fases, 5 leads, 5 deals) - Analytics endpoint met KPI's, pipeline stats en recente leads - Frontend: Next.js 14 + TypeScript + Tailwind CSS - Dashboard met KPI-kaarten en pipeline/leads overzicht - Leads pagina met zoeken, filteren, toevoegen en bewerken - Sales pipeline Kanban bord met drag-to-stage interface - Sidebar navigatie, LeadModal component https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
…atibiliteit Next.js 14.1.0 ondersteunt geen TypeScript config bestanden. Hernoemd naar next.config.mjs en lock files toegevoegd. https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
Sluit build-artefacten (.next/) en runtime-data (backend/data/) uit van versiebeheer. https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
…iliteit Frontend API calls gaan nu via relatief pad /api in plaats van direct naar localhost:3001, zodat de app ook werkt in cloud/sandbox omgevingen. https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
…liteit better-sqlite3 vereist native C++ compilatie die faalt op Node 24+. sql.js is pure JavaScript/WASM en werkt op elke Node versie en OS zonder build tools. Ook ts-node vervangen door tsx (sneller, beter compat). https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
- Voeg nieuwe frontend pagina's toe: bronanalyse, kpi, templates - Verbeter analytics routes met uitgebreidere rapportage - Refactor database.ts voor betere sql.js compatibiliteit - Update types.ts met uitgebreidere type definities - Verbeter leads, pipeline routes en API lib - Update Sidebar met navigatie naar nieuwe pagina's https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
- Bauhaus design system: zwart/wit, geen border-radius, geen shadows, Inter font - Zwarte sidebar met witte actieve nav-items en nieuwe Tarief pagina - Dashboard: executive summary, ARR blok, KPI grid, recente leads, maandgrafiek - Pipeline: interactief drag & drop kanban bord met stale-lead indicatoren - Leads: Bauhaus tabel met filters, volledig LeadModal met alle NAHV velden - Templates: volledig 14-stappen SOP met alle echte email templates (NL/EN) - KPI: doelen vs actueel met funnel visualisatie - Bronanalyse: tabel + bar charts per acquisitiekanaal - Nieuw: Tarief & Voorstel calculator met NL/EN template generator https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR introduces a complete sales and lead management platform for NAHV, consisting of a Next.js frontend and Express backend with SQLite database. The application provides comprehensive tools for tracking leads through the sales pipeline, analyzing acquisition channels, and monitoring key performance indicators.
Key Changes
Backend (Express + SQLite)
src/nahv/backend/src/db/database.ts): SQL.js-based SQLite wrapper with persistent file storage, schema initialization, and seed datasrc/nahv/backend/src/routes/leads.ts): CRUD endpoints for leads with fields tracking status, pricing, source, and customer conversionsrc/nahv/backend/src/routes/analytics.ts): Comprehensive metrics computation including conversion rates, ARR calculations, deal cycle analysis, and source attributionsrc/nahv/backend/src/routes/pipeline.ts): Open pipeline overview with stale lead detection and value aggregationsrc/nahv/backend/src/types.ts): TypeScript interfaces for Lead, AnalyticsSummary, and related data structuresFrontend (Next.js 14 + React)
src/nahv/frontend/app/page.tsx): Main overview with KPIs including total leads, conversion rates, ARR metrics, and performance trendssrc/nahv/frontend/app/leads/page.tsx): Searchable lead table with filtering by status and customer status, inline editing via modalsrc/nahv/frontend/app/pipeline/page.tsx): Open opportunities tracking with deal value, age, and stale lead warningssrc/nahv/frontend/app/kpi/page.tsx): Target-based performance monitoring with visual status indicatorssrc/nahv/frontend/app/bronanalyse/page.tsx): Channel attribution analysis showing leads, conversions, and ARR per acquisition sourcesrc/nahv/frontend/app/templates/page.tsx): Pre-built email templates (NL/EN) for kennismaking, proposals, and onboarding with copy-to-clipboard functionalitysrc/nahv/frontend/components/LeadModal.tsx): Reusable form component for creating/editing leadssrc/nahv/frontend/components/Sidebar.tsx): Main navigation with links to all dashboard sectionssrc/nahv/frontend/lib/api.ts): Typed fetch wrapper for backend communication with utility functions for formattingStyling & Configuration
Notable Implementation Details
https://claude.ai/code/session_01B4Hd1gFuAgP86vfZDk2e8p