<!-- Wappler include head-page="index0" appConnect="local" is="dmx-app" bootstrap5="local" fontawesome_5="cdn" -->
<dmx-value id="insertID"></dmx-value>
<div class="container">
    <form is="dmx-serverconnect-form" id="serverconnectform1" method="post" action="/api/insert" dmx-generator="bootstrap5" dmx-form-type="horizontal" dmx-on:done="modal1.hide();DBSC1.load({})" dmx-on:submit="" dmx-on:success="insertID.setValue(serverconnectform1.data.insert.identity)">
        <div class="form-group mb-3 row">
            <label for="inp_db_fullName" class="col-sm-2 col-form-label">full name</label>
            <div class="col-sm-10">
                <input type="text" class="form-control" id="inp_db_fullName" name="db_fullName" aria-describedby="inp_db_fullName_help" placeholder="Enter Db full name">
            </div>
        </div>
        <div class="form-group mb-3 row">
            <label for="inp_db_licenseNumber" class="col-sm-2 col-form-label">license number</label>
            <div class="col-sm-10">
                <input type="text" class="form-control" id="inp_db_licenseNumber" name="db_licenseNumber" aria-describedby="inp_db_licenseNumber_help" placeholder="Enter Db license number">
            </div>
        </div>
        <div class="form-group mb-3 row">
            <label for="db_stateIssue" class="col-sm-2 col-form-label">state issue</label>
            <div class="col-sm-4">
                <select id="db_stateIssue" class="form-select" dmx-bind:options="stateJSON.data.states" optiontext="name" optionvalue="abbreviation" name="db_stateIssue" dmx-bind:value="selectedValue">
                </select>
            </div>
            <div class="col-6">
                <small id="bs5-form-group-help1" class="form-text text-muted">Your great help text.</small>
            </div>
        </div>
        <div class="form-group mb-3 row">
            <label for="inp_db_employeeID" class="col-sm-2 col-form-label">Trainer</label>
            <div class="col-sm-3">
                <input type="number" class="form-control" id="inp_db_employeeID" name="db_employeeID" aria-describedby="inp_db_employeeID_help" placeholder="Enter Db employee" dmx-bind:value="select1.selectedValue" readonly="true">
            </div>
            <div class="col-6 offset-1">
                <select id="select1" class="form-select" dmx-bind:options="trainerJSON.data.Trainer" name="db_trainerID" optiontext="Name" optionvalue="ID" dmx-bind:value="selectedValue">
                </select>
            </div>
        </div>
        <div class="form-group mb-3 row">
            <label for="inp_owner" class="col-sm-2 col-form-label">Date</label>
            <div class="col-sm-10">
                <input type="text" class="form-control" id="inp_owner" name="owner" aria-describedby="inp_owner_help" placeholder="Enter Owner" dmx-bind:value="DateTimeNow.datetime.formatDate('MM-dd-yyyy')" readonly="true">
            </div>
        </div>
        <div class="form-group mb-3 row">
            <div class="col-sm-2">&nbsp;</div>
            <div class="col-sm-10">
                <button type="submit" class="btn btn-success" dmx-bind:disabled="state.executing">Save <span class="spinner-border spinner-border-sm" role="status" dmx-show="state.executing"></span></button>
                <button id="xbtn4" class="btn btn-secondary" data-bs-dismiss="modal">Cancel</button>
            </div>
        </div>
    </form>
</div>