Proje: Okul.com.tr CRM · Hub: Okul.com.tr CRM — Domain

CRM Okul Entity Modeli

Temel Alanlar

interface School {
    id: number;
    school_id: number;       // ayrı bir okul ID'si (okulun kendi ID'si)
    name: string;            // okul adı
    school_name: string;     // alternatif okul adı alanı
    about: string;
    mission: string;
    vision: string;
    history: string;
    meta_title: string;
    description: string;
    psychological_advice: boolean;
    total_students: number;
    class_students: number;
    status: boolean;
    monthly_lead_limit: number;
    hidden_lead_form: boolean;
    hidden_lead_phone: boolean;
    school_type_id: number;
    sector_id: number;        // 1: Devlet, 2: Özel
    college_id: number;
    redirect_id?: number;
    customer_id?: number;
    campus_id?: number;
    is_customer: string;
    school_closed: any;
    deleted_at: string | null;
}

İlişkiler (Include ile Yüklenir)

İlişkiInclude AdıAçıklama
Okul tipitype veya school_typeSchoolType objesi
SektörsectorDevlet/Özel
KolejcollegeBağlı kolej
YönlendirmeredirectRedirect hedefi
MüştericustomerBağlı müşteri
KampüscampusKampüs bilgisi
Konumlocation, location.province, location.county, location.neighbourhoodHiyerarşik konum
İletişimcontacts, contacts.typeTelefon, email vb
Anaokulu detaykindergartenYaş aralığı
Lise tipihigh-school, high-school.typeLise bilgisi
TesislerfacilitiesSpor salonu, yüzme havuzu vb
HizmetlerservicesTaşıma, yemek vb
Öğrenme dillerilearning-languagesİngilizce, Fransızca vb
Aktiviteleractivities, activities.activity-typeKulüpler vb
VardiyalarshiftsÖğle, tam gün vb
ÜcretlerfeesSchoolFee bilgisi
S-C sorularıanswers, answers.questionÖzelleştirilmiş sorular
EtiketlertagsSerbest etiketler
Özelliklerfeatures, features.values, features.school-typesSchoolFeature

Okul Durumları (filter[status])

DeğerAnlam
1Aktif
2Pasif
3Silindi
4Yönlendirildi (redirect var)

Sektörler

sector_idAnlam
1Devlet
2Özel

URL Filtre → API Eşlemesi (Okullar)

city → filter[location-1]
district → filter[location-2]  
neighborhood → filter[location-3]
school_name → filter[school-name]
sector-id → filter[sector-id]
type-id → filter[type-id]
school-id → filter[school-id]
status → filter[status]

FormValues Farkı

SchoolFormValues bazı alanları School tipinden farklı alır:

  • status: boolean (formda) vs status: boolean (API’de) — aynı
  • sector_id: number zorunlu (formda 0 ile başlar, submit’te validate edilir)