Commit Graph

80 Commits

Author SHA1 Message Date
Satyam Rastogi 76df03f6fa feat(data): realistic pre-sale lead identities, values, dates, and storm attribution 2026-05-29 16:31:23 +05:30
Satyam Rastogi d5ea0935b4 fix(data): correct pendingInvoiceCount and align cost-invoice vendors to breakdown 2026-05-29 15:39:36 +05:30
Satyam Rastogi 2b741dd0b5 fix(data): trade-correct vendors, margins, and timeline details on converted projects 2026-05-29 15:20:01 +05:30
Satyam Rastogi 4b2bb37b3b feat(data): convert won kanban leads (kl_023-038) into unified project records 2026-05-29 14:10:54 +05:30
Satyam Rastogi 058f41c763 refactor(data): migrate project ids to PRJ-2026-### (with inbound FKs) 2026-05-29 13:50:13 +05:30
Satyam Rastogi f794ec28b4 chore(data): purge residual placeholder name in docs; normalize sub_001 trade + owner email 2026-05-29 05:00:22 +05:30
Satyam Rastogi 155bf6ce63 feat(data): add kanban lead values, fix Complete-stage data, set stormSource 2026-05-29 04:37:57 +05:30
Satyam Rastogi 2f43205854 fix(data): match subcontractor tasks to real projects; style On Hold status 2026-05-29 04:22:30 +05:30
Satyam Rastogi 2010ca080e fix(data): align sub_002-005 login company/trade/phone with subcontractor records 2026-05-29 04:16:26 +05:30
Satyam Rastogi 2399b40926 feat(data): add login records for sub_002-005 so each subcontractor inbox is reachable 2026-05-29 04:13:52 +05:30
Satyam Rastogi cb6695aa94 fix(data): seed leads list so the Leads page is populated on load 2026-05-29 04:09:11 +05:30
Satyam Rastogi 4ee480ec87 fix(data): reconcile project financials and add missing budget breakdowns 2026-05-29 04:01:27 +05:30
Satyam Rastogi ebd5b78f41 fix(data): remap subcontractor task/notification actor ids to canonical scheme 2026-05-29 03:48:24 +05:30
Satyam Rastogi 8c4e6695be fix(data): remap orgMembers userId to canonical id scheme 2026-05-29 03:44:23 +05:30
Satyam Rastogi 890072a051 feat(data): canonical roster — real Texan names + unified LUP employee ids 2026-05-29 03:41:18 +05:30
Satyam Rastogi 0c40f1c881 feat(data): add resolvePerson selector over a merged people index 2026-05-29 03:31:40 +05:30
Satyam Rastogi a03fb0cf00 chore(data): add DEMO_TODAY anchor and use it for kanban day-counter 2026-05-29 03:24:57 +05:30
Satyam Rastogi 73387366fe merge: integrate subcontractor, org-settings & commission features from project-refinement
# Conflicts:
#	src/App.jsx
#	src/components/Layout.jsx
#	src/data/mockStore.jsx
#	src/pages/LeadsListPage.jsx
#	src/pages/owner/OwnerProjectDetail.jsx
#	src/pages/owner/OwnerSnapshot.jsx
2026-05-29 01:11:03 +05:30
Satyam Rastogi 490d16b80a subcontrcator: post a status update section- removed photo required option 2026-05-21 20:49:10 +05:30
Satyam Rastogi e648547f1b change mock data of all projects to show positive net profit 2026-05-21 17:48:55 +05:30
Satyam Rastogi 371c52fe9d subcontractor: task thread section having teams and direct chat options now 2026-05-21 15:50:19 +05:30
Satyam Rastogi 3a038ffc6f subcontractor: add progress updates and task activity timeline 2026-05-21 15:30:19 +05:30
Satyam Rastogi 5dd781ca45 subcontractor payments table added in owners box 2026-05-20 18:45:00 +05:30
Satyam Rastogi 2589975074 adds sections as list tasks,log expenses. fees, notifications for sub contrcator 2026-05-19 18:17:36 +05:30
Satyam-Rastogi a6d3997d07 feat(storm-intel): configurable pin radius, fix blank map, 6mo default, remove mock polygons
- Map always renders (removed blank overlay when no nearby events)
- Pin radius is now user-configurable (default 5 mi, input shown in pin strip)
- Default date range changed to 6 months for faster initial load
- IEM fetch window narrowed to 6 months to match default
- MOCK_STORM_EVENTS cleared (IEM provides real NWS polygon data)
2026-05-19 00:47:43 +05:30
Satyam-Rastogi 7799a83a4a feat(storm-intel): replace hexagonal storm polygons with realistic NWS-style swath shapes
Updated all 7 MOCK_STORM_EVENTS polygons to use irregular, amoeba-like
swath outlines matching real hail storm paths from NWS reports. Also
renamed project to LynkedUpPro-CRM in package.json.
2026-05-18 23:35:31 +05:30
Satyam-Rastogi 12bd2fe0de feat(storm-intel): Phase 4+5 — Tomorrow.io forecast overlay and canvasser zone assignment
- Tomorrow.io 7-day forecast strip with weather icons, storm score bar, and per-day risk color coding
- High-risk alert banner in forecast strip when any day scores >=65
- api/storm-forecast.js: Vercel proxy that reads TOMORROW_API_KEY server-side; graceful empty response when key unset
- useStormForecast hook: USE_MOCK=false with realistic MOCK_FORECAST fallback
- ZoneDrawingLayer: click-to-place polygon vertices using react-leaflet useMapEvents; disables double-click zoom while active; shows live vertex dots + dashed preview polygon
- ZoneLayer: renders stormZones as colored semi-transparent polygons with agent initials at centroid
- ZoneAssignmentModal: name + canvasser picker + color selector + optional storm link; portaled modal
- StormIntelPage: Draw Zone button (Admin/Owner only); drawing state/cancel flow; stormZones displayed on map; zone summary strip in sidebar; StormDetailDrawer has working "Draw Canvasser Zone" action
- FieldStormZonePage: canvasser mobile view at /field/storm-zones showing assigned zones with map, linked storm details, conversion window badge, and peak window alert
- Layout: Storm Zones entry in FIELD_AGENT nav
- App: /field/storm-zones route (FIELD_AGENT + Admin + Owner)
2026-05-18 18:06:17 +05:30
Satyam-Rastogi df50f27ba6 feat(storm-intel): Phase 3 — Revenue Attribution dashboard
Adds an Attribution tab to Storm Intel showing full ROI breakdown of storm-sourced canvassing.

- MOCK_STORM_ATTRIBUTION_LEADS: 35 realistic leads across 7 storms, with addresses, statuses
  (New / Contacted / Appointed / Closed) and contractValues for closed deals — $218,900 total revenue
- useStormAttribution hook: merges historical mock leads with any session-created storm leads,
  aggregates per-storm stats (leads, closed, conversion rate, revenue, pipeline estimate, avg deal size)
- Attribution tab in StormIntelPage:
  - 6 summary stat cards: Total Leads, Closed, Conversion Rate, Revenue, Pipeline, Avg Deal
  - Grouped bar chart (Recharts) — leads generated vs closed per storm, bars colored by severity
  - Per-storm revenue cards ranked by revenue: severity badge, stats row, animated revenue
    progress bar relative to top performer
  - "Top Performing Zone" insight card at bottom
- Tab switcher (Map / Attribution) added to header; filter bar only shows on Map tab
2026-05-18 17:16:34 +05:30
Satyam Rastogi c7a9849d1f add subcontractor task assign/list for admin and owner feature 2026-05-18 17:16:11 +05:30
Satyam-Rastogi 2e797c89f6 feat(storm-intel): Storm Intelligence Hub — Phase 1
Adds a new Storm Intel section to the sidebar and routes for ADMIN and OWNER roles.

- StormIntelPage: full-height layout with Leaflet map + storm polygon overlays,
  severity-coded color system, horizontal filter bar (date range / severity / sort),
  and a scrollable storm event list
- Storm detail drawer slides in from right with hail size, est. homes, days ago,
  conversion window indicator (Hot Zone / Warm / Cold / Too Fresh), intel text,
  and quick-action buttons (Create Lead, Open in Dispatch, Assign Canvassers stub)
- Clicking a storm card or map polygon zooms the map to that polygon and opens the drawer
- useStormEvents hook with USE_MOCK flag, date-range cutoff filter, type/severity filter,
  sort by date or severity, and conversionWindow() helper
- api/storm-events.js: NWS api.weather.gov proxy (free, no auth needed), parses
  GeoJSON polygons and hail size from alert descriptions
- MOCK_STORM_EVENTS: 7 realistic Plano TX storm events with accurate polygon coords
- Sidebar: CloudLightning "Storm Intel" entry added for OWNER and ADMIN nav
2026-05-18 16:49:37 +05:30
Satyam-Rastogi 9e2173fd43 feat(hail-recon): Hail Recon integration — storm intel panel, hail history, auto storm mode, address monitoring 2026-05-18 15:50:59 +05:30
Satyam Rastogi 949d96a7c7 add leaderboard for canvassar 2026-05-15 12:05:05 +05:30
Satyam-Rastogi b1fdda407d add leaderboard for canvassar 2026-05-15 12:05:05 +05:30
Satyam Rastogi cef4be74b8 adds on /off commission for team members in jobs,when comm is on then owner can edit comm 2026-05-14 19:08:31 +05:30
Satyam-Rastogi 00e9c2af00 adds on /off commission for team members in jobs,when comm is on then owner can edit comm 2026-05-14 19:08:31 +05:30
Satyam Rastogi 72be14369e access control by role plus by person in orgsettings 2026-05-14 18:13:42 +05:30
Satyam-Rastogi d01e699250 access control by role plus by person in orgsettings 2026-05-14 18:13:42 +05:30
Satyam Rastogi 6610054915 change org default commission from 10 to 0 2026-05-13 20:11:30 +05:30
Satyam-Rastogi 138ec168b2 change org default commission from 10 to 0 2026-05-13 20:11:30 +05:30
Satyam Rastogi 2299cda11d org team management section in org Settings module 2026-05-13 18:55:09 +05:30
Satyam-Rastogi b6a7792bf7 org team management section in org Settings module 2026-05-13 18:55:09 +05:30
Satyam Rastogi 8f4a0e81fb commission overrides in org Settings page 2026-05-13 12:51:36 +05:30
Satyam-Rastogi 9bc8a42354 commission overrides in org Settings page 2026-05-13 12:51:36 +05:30
Satyam Rastogi fea4ad2d22 Org settings module and user roles 2026-05-12 20:36:44 +05:30
Satyam-Rastogi e85ecd2571 Org settings module and user roles 2026-05-12 20:36:44 +05:30
Satyam Rastogi 3b1a77f500 team management feature in Owners Box 2026-05-12 19:29:52 +05:30
Satyam-Rastogi 17c3dc7307 team management feature in Owners Box 2026-05-12 19:29:52 +05:30
Satyam Rastogi ab701c5bd9 add name for each entry of budget & cost table 2026-05-12 17:37:11 +05:30
Satyam-Rastogi 91392bebcb add name for each entry of budget & cost table 2026-05-12 17:37:11 +05:30
Satyam Rastogi 87657fa8b3 remove Payments tab and adds sections into budges- costs 2026-05-12 16:58:33 +05:30