Proje: Okul Platform · Hub: Okul Platform — Domain

Admin Lead Listesi

GET /api/admin/leads — auth:sanctum + admin

Parametreler

Sıralama

sort=-id (yeniden eskiye) veya sort=id

Filtreler

filter[id], filter[school_id], filter[trashed]=with|only

Include’lar (Önemli!)

school               → Okul bilgisi
user                 → Veli/öğrenci
approvedByUser       → Kim onayladı
agentUser            → Atanan ajan
reasonOfRejectStatus → Red nedeni
pipeline             → Pipedrive pipeline
stage                → Pipedrive stage
approvedStatus       → Onay durumu (Config)
schoolAnsweredLeadStatus → Okul yanıt durumu

Lead Include Yapısı

Spatie QueryBuilder allowedIncludes ile yönetilir. HasDynamicIncludes trait ile de model üzerinden yüklenebilir.

school_answered_deal_status

B2B portalda görünen okul yanıt durumu. Lead’in school_answered_deal_status alanı. Okul sahibi lead’i kabul/ret edebilir.

approved_status_id

Config tablosundan alınan onay durumu ID (varsayılan: 88). LeadPolicy: VIEW_LEAD izni gerekli.