@extends('layouts.performance') @section('title', 'Personel Yönetimi') @section('perf-content')

Personel Yönetimi

Personel kayıtlarını ekleyin ve güncelleyin.

@if (request()->query('saved'))
Personel kaydedildi.
@elseif (request()->query('error'))
İşlem sırasında hata oluştu.
@endif @if ($errors->any())
{{ $errors->first() }}
@endif
{{ $editEmployee ? "Personel G\u{00FC}ncelle" : 'Yeni Personel' }}
@csrf
@if ($positions->isEmpty())
Pozisyon eklemek için Ayarlar menüsünü kullanın.
@endif
@if ($departments->isEmpty())
Departman eklemek için Ayarlar menüsünü kullanın.
@endif
@if ($titles->isEmpty())
Ünvan eklemek için Ayarlar menüsünü kullanın.
@endif
@if ($centers->isEmpty())
Sorumluluk merkezi eklemek için Ayarlar menüsünü kullanın.
@endif
active ?? 1) ? 'checked' : '' }}>
Personel Listesi
{{ $totalRows }} kayıt
@foreach ($deptOptions as $deptOption) @endforeach
@foreach ($titleOptions as $titleOption) @endforeach
@foreach ($companyOptions as $companyOption) @endforeach
@foreach ($centerOptions as $centerOption) @php $centerValue = $centerOption->center_no . ' - ' . $centerOption->name; $centerLabel = $centerValue; if ((int) $centerOption->active === 0) { $centerLabel .= ' (Pasif)'; } @endphp @endforeach
@if ($search !== '' || $deptFilter !== '' || $titleFilter !== '' || $companyFilter !== '' || $centerFilterValue !== '' || $statusFilter !== 'active') Temizle @endif
@foreach ($employees as $row) @php $centerLabel = '-'; if (!empty($row->center_no) || !empty($row->center_name)) { $centerLabel = trim(($row->center_no ?? '') . ' - ' . ($row->center_name ?? '')); if ((int) ($row->center_active ?? 1) === 0) { $centerLabel .= ' (Pasif)'; } } $exitRaw = $row->exit_date ?? ''; $hasExit = ($exitRaw !== '' && $exitRaw !== '1899-12-31'); $statusLabel = $hasExit ? 'Pasif' : ((int) ($row->active ?? 1) === 1 ? 'Aktif' : 'Pasif'); $manager1Code = trim((string) ($row->manager1 ?? '')); $manager2Code = trim((string) ($row->manager2 ?? '')); $manager1Label = '-'; $manager2Label = '-'; if ($manager1Code !== '') { $manager1Label = trim((string) ($row->manager1_name ?? '')); if ($manager1Label === '') { $manager1Label = trim((string) ($row->manager1_emp_name ?? '')); } if ($manager1Label === '') { $manager1Label = $manager1Code; } } if ($manager2Code !== '') { $manager2Label = trim((string) ($row->manager2_name ?? '')); if ($manager2Label === '') { $manager2Label = trim((string) ($row->manager2_emp_name ?? '')); } if ($manager2Label === '') { $manager2Label = $manager2Code; } } @endphp @endforeach
Kod Firma Ad 1. Amir 2. Amir Sorumluluk Merkezi Durum
{{ $row->employee_code ?? '-' }} {{ $row->company ?? '' }} {{ $row->name }} {{ $manager1Label }} {{ $manager2Label }} {{ $centerLabel }} {{ $statusLabel }}
@if ($totalPages > 1)
@endif
@endsection