feat: модуль GPS-мониторинга (карта Яндекс.Карт, Traccar, геозоны, маршруты, группы)

This commit is contained in:
2026-08-24 19:30:11 +03:00
parent c0e2ddd9c8
commit 104b3ca422
33 changed files with 4108 additions and 4 deletions

View File

@@ -8,6 +8,7 @@ import { notificationService } from "./services/notification.service";
import { webPushService } from "./services/web-push.service";
import { startMedScheduleWorker } from "./medschedule/worker";
import { startAutomationScheduler } from "./workers/automation-scheduler";
import { startGpsWorker } from "./gps/worker";
import { storage } from "./storage";
import type { ReminderRecipient } from "@shared/schema";
import { db, withSuperAdmin } from "./db"; // lazy proxy — safe at module load; throws on first use if DATABASE_URL missing
@@ -1099,6 +1100,10 @@ async function runStartupDataPatches() {
startAutomationScheduler();
log('Automation scheduler started');
// Start GPS worker (offline detection for tracked assets)
startGpsWorker();
log('GPS worker started');
// Clean up duplicate subscriptions then backfill defaults for existing users
(async () => {
try {