Proje: Okul B2B App · Hub: Okul B2B App — Domain

İstatistik ve Bildirim Tip Detayları

CustomerStatisticsApiResponse

GET /customer/statistics dönen yapı:
{
  data: {
    view_count:         { value: number, label: string, type: string }
    lead_count:         { value: number, label: string, type: string }
    registration_count: { value: number, label: string, type: string }
    annual_roi_value:   { value: number, label: string, type: string }
  }
}

DashboardStats (UI format)

{
  id: 1-4,
  label: "Görüntüleme" | "Bilgi Talebi" | "Kayıt" | "Yıllık Yatırım Getirisi",
  value: "1.234" (Türkçe formatlı string),
  iconKey: "view" | "leads" | "registration" | "revenue",
  backgroundColor: pastel renk,
  trend?: { percentage, direction: 'up'|'down'|'stable', period }
}

StatsService.convertApiToDashboardStats() ile dönüştürülür. Lead sayısı için LeadsService’ten totalCount çekilir (daha doğru).

Notification Tipleri

type: 'lead' | 'system' | 'marketing' | 'warning'
priority: 'low' | 'normal' | 'high' | 'critical'

Bildirimler Deep Link ile ilişkilendirilebilir: actionUrl, leadId alanları.

NotificationPermissions

Okul.com.tr özel izin yapısı:

{ sms: boolean, mail: boolean, call: boolean }

Standart cihaz push izni bunlardan ayrıdır.