@extends('layouts.app') @section('title', 'Contracts') @push('styles') @endpush @section('content')
Contract List
@if(request('search') || request()->filled('status_filter') || request()->filled('type_filter')) @endif
Add Contract
@forelse($contracts as $index => $contract) @empty @endforelse
# Contract No Employee Type Period Salary Status Actions
{{ $contracts->firstItem() + $index }} {{ $contract->contract_number }} {{ $contract->employee->name }} @if($contract->position)
{{ $contract->position->position_name }} @endif
@php $typeColors = [ 'permanent' => 'primary', 'fixed_term' => 'info', 'probation' => 'warning', 'internship' => 'secondary', ]; @endphp {{ $contract->contract_type_label }} {{ $contract->start_date->format('d M Y') }} @if($contract->end_date)
to {{ $contract->end_date->format('d M Y') }} @if($contract->isExpired())
Expired @elseif($contract->isExpiringSoon())
Expiring Soon @endif @else
No end date @endif
@if($contract->salary) Rp {{ number_format($contract->salary, 0, ',', '.') }} @else - @endif @if($contract->status) Active @else Inactive @endif
@csrf @method('DELETE')

No contracts found

@if($contracts->hasPages()) @endif
@endsection @push('scripts') @endpush