<div class="modal-header">
    <h4 class="modal-title">Tambah Model</h4>
    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
        <span aria-hidden="true">×</span>
    </button>
</div>
<div class="modal-body">
    <form method="POST" action="<?= base_url('model/create') ?>" enctype="multipart/form-data">
        <?= csrf_field() ?>
        <div class="form-group">
            <label class="form-label" for="exampleNamaModel">Nama Model</label>
            <input type="text" class="form-control" id="exampleNamaModel" name="nama_model" placeholder="Input Nama Model" required>
        </div>
        <div class="form-group">
            <label class="form-label" for="exampleInputOngkosPengerjaan">Ongkos Pengerjaan</label>
            <input type="number" class="form-control" id="exampleInputOngkosPengerjaan" name="ongkos_pengerjaan" placeholder="Input Ongkos Pengerjaan" required>
        </div>
        <div class="form-group">
            <label class="form-label" for="exampleInputFile">Input Foto Model</label>
            <div class="input-group">
                <div class="custom-file">
                    <input type="file" class="custom-file-input" name="foto_model" required id="exampleInputFile">
                    <label class="custom-file-label" for="exampleInputFile">Choose file</label>
                </div>
            </div>
        </div>

        <div class="modal-footer">
            <button type="submit" class="btn btn-primary">Simpan</button>
            <button type="button" class="btn btn-secondary" data-dismiss="modal">Batal</button>
        </div>
    </form>
</div>

<script>
    $(function() {
        // Summernote
        $('#summernote').summernote()

        // CodeMirror
        CodeMirror.fromTextArea(document.getElementById("codeMirrorDemo"), {
            mode: "htmlmixed",
            theme: "monokai"
        });
    })
</script>