<div class="modal-header">
    <h4>Add IOC Type</h4>
    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
            aria-hidden="true">&times;</span></button>
</div>
<div class="modal-body">

        <div class="container col-md-12">
        <form method="post" action="" id="form_new_ioc_type" enctype="multipart/form-data">
            <div class="col-md-12 col-lg-12 col-sm-12">
                {{ form.hidden_tag() }}
                <div class="form-group">
                    <label for="type_name" class="mr-4">Type name
                    </label>
                    {{ form.type_name(class='form-control',  autocomplete="off") }}
                </div>
                <div class="form-group mt-3">
                    <label for="type_description" class="placeholder">Type description</label>
                    {{ form.type_description(class='form-control',  autocomplete="off") }}
                </div>
                <div class="form-group mt-3">
                    <label for="type_taxonomy" class="placeholder">Type taxonomy</label>
                    {{ form.type_taxonomy(class='form-control',  autocomplete="off") }}
                </div>
                <div class="form-group mt-3">
                    <label for="type_description" class="placeholder">Type validation regex</label>
                    {{ form.type_validation_regex(class='form-control', autocomplete="off") }}
                </div>
                <div class="form-group mt-3">
                    <label for="type_description" class="placeholder">Type validation expect explanation</label>
                    {{ form.type_validation_expect(class='form-control', autocomplete="off") }}
                </div>

            {% if ioc_type.type_id %}
                <button type="button" class="btn btn-outline-danger mt-5"
                onclick="delete_ioc_type('{{ ioc_type.type_id }}');">Delete</button>
                <button type="button" class="btn btn-outline-success ml-4 mt-5 float-right"
                id="submit_new_ioc_type">Update</button>

            {% else %}

                <button type="button" class="btn btn-outline-success ml-4 mt-5 float-right"
                id="submit_new_ioc_type">Save</button>

            {% endif %}
        </form>
    </div>

</div>
