@extends('admin.layouts.app')

@section('title', 'Tambah/Edit Program')

@section('content')
<form action="{{ isset($program) ? route('admin.program.update', $program->id) : route('admin.program.store') }}" method="POST">
    @csrf
    @if(isset($program))
        @method('PUT')
    @endif

    <div class="mb-3">
        <label>Judul Program</label>
        <input type="text" name="judul" class="form-control" value="{{ $program->judul ?? '' }}">
    </div>

    <div class="mb-3">
        <label>Deskripsi</label>
        <textarea name="deskripsi" class="form-control">{{ $program->deskripsi ?? '' }}</textarea>
    </div>

    <div class="mb-3">
        <label>Tanggal</label>
        <input type="date" name="tanggal" class="form-control" value="{{ $program->tanggal ?? '' }}">
    </div>

    <button type="submit" class="btn btn-success">Simpan</button>
</form>
@endsection
