@extends('layouts.app')

@section('title', 'Edit Dosen')

@section('content')
<div class="card">
    <div class="card-header"><h3 class="card-title">Edit Data Dosen</h3></div>
    <div class="card-body">
        <form action="{{ route('dosen.update', $dosen->nip) }}" method="POST">
            @csrf @method('PUT')
            <div class="form-group row">
                <label class="col-sm-2 col-form-label">NIP</label>
                <div class="col-sm-10"><input type="text" name="nip" class="form-control" value="{{ $dosen->nip }}" disabled></div>
            </div>
            <div class="form-group row">
                <label class="col-sm-2 col-form-label">Nama</label>
                <div class="col-sm-10"><input type="text" name="nama" class="form-control" value="{{ $dosen->nama }}" required></div>
            </div>
            <button type="submit" class="btn btn-primary">Update</button>
            <a href="{{ route('dosen.index') }}" class="btn btn-secondary">Batal</a>
        </form>
    </div>
</div>
@endsection
