<?= $this->extend('layouts/main') ?>

<?= $this->section('content') ?>
<div class="container">
    <h4>Edit Unit</h4>

    <form action="<?= base_url('admin/unit/update/' . $unit['id']) ?>" method="post">
        <?= csrf_field() ?>

        <div class="mb-3">
            <label for="nama" class="form-label">Nama Unit</label>
            <input type="text" name="nama" class="form-control" value="<?= esc($unit['nama']) ?>" required>
        </div>

        <button type="submit" class="btn btn-primary">Update</button>
        <a href="<?= base_url('admin/unit') ?>" class="btn btn-secondary">Kembali</a>
    </form>
</div>
<?= $this->endSection() ?>
