<?php
session_start();
// ============
include("../../asset/theme/css/myfunc.php");
include("../../php_crud/my_class.php");
$obj = new my_class();
// ============
?>
<style type="text/css">
    i{
        cursor:pointer;
    }
	.select_list{
	width: 200px;
}

.input_sub{
	width: 185px;
}
.select_list1{
	width: 100px;
	float: left;
	margin-left: 3px;
	margin-right: 3px;
}
</style>
<script src="module/fees/js/late_fine.js" type="text/javascript"></script>

<?php if($_SESSION['add']=='Y'){ ?>
<div class="row-fluid">
    <form class="form-vertical" >
        <input type="hidden" id="branchid" name="branchid" value="<?php echo $_SESSION['LOGIN_BRANCH']; ?>"/>

        <legend>Add Late Fine</legend>
        <div class="row-fluid">

            <!--PAGE CONTENT BEGINS-->


			<div class="span3">
                <div class="control-group" >
                        <label class="control-label" for="form-field-1">Shift Name<font color="#FF0000">*</font></label>
    
                        <div class="controls" id="shift_control">
                            <?php
                            $branch_id = $_SESSION['LOGIN_BRANCH'];
                            $table_name = "_int_institute_setup";
                            $column = "_id,_name";
                            $where_cond = "_pid='$branch_id' AND _type='SH' AND _status='A'";
                            $shift_list = $obj->View_all_data_row_column_By_Cond($table_name, $column, $where_cond);
                            ?>
                            <select id="shift_id" onchange="call_medium(this.value)">
                                <option value="">---SELECT---</option>
                                <?php
                                foreach ($shift_list AS $index1 => $data4_shift) {
                                    echo "<option value='" . $data4_shift['_id'] . "'>" . $data4_shift['_name'] . "</option>";
                                }
                                ?>
                            </select>
                        </div>
                    </div>
            </div>
            <div class="span3">
                <div class="control-group" >
                    <label class="control-label" for="form-field-1">Medium Name<font color="#FF0000">*</font></label>

                    <div class="controls" id="medium_control">
                        <select >
                        </select>
                    </div>

                </div>
             </div>
            <div class="span3">
                
                <div class="control-group" >
                    <label class="control-label" for="form-field-1">Class Name<font color="#FF0000">*</font></label>

                    <div class="controls" id="class_control">
                        <select >
                        </select>
                    </div>
                </div>
            </div>	
            <div class="span3">
                
                <div class="control-group" >
                    <label class="control-label" for="form-field-1">Department Name<font color="#FF0000">*</font></label>

                    <div class="controls" id="department_control">
                        <select >
                        </select>
                    </div>
                </div>

            </div>
                
			<div class="span3" style="margin-left:0">
                <div class="control-group" >
                    <label class="control-label" for="form-field-1">Late Fine Amount<font color="#FF0000">*</font></label>

                    <div class="controls">
                        <input type="text" class="small department_name" id="late_fine"   />
                    </div>
                </div>

            </div>
			<div class="span3">
			<div class="control-group" >
				<label class="control-label" for="form-field-1">Late Fine Date<font color="#FF0000">*</font></label>
				<div class="controls" id="branch_control">
					<input id="date" name="date" class="date-picker" type="text" data-date-format="dd-mm-yyyy" placeholder="dd-mm-yyyy"  />
				</div>
			</div>
			</div>


            									



            <div class="span12">

                <div class="control-group">
                    <label class="control-label" for="form-field-1">&nbsp;</label>

                    <div class="controls">
                        <button class="btn btn-small btn-success" type="button" id="btn_save">
                            <i class="icon-ok bigger-100"></i>
                            Save
                        </button>

                        &nbsp; &nbsp; &nbsp;
                        <button class="btn btn-small btn-danger" type="reset" id="btn_reset">
                            <i class="icon-undo bigger-100"></i>
                            Reset
                        </button>
                    </div>
                </div>
            </div>

        </div>	
    </form>
</div>
<?php } ?>

<div class="row-fluid" id="data_to_show">
</div>


<div id="modal-table" class="modal hide fade  " style="overflow-x:show" tabindex="-1">
    <div class="modal-header no-padding">
        <div class="table-header">
            <button type="button" class="close" data-dismiss="modal">&times;</button>
            Edit Late Fine
        </div>
    </div>
    <div class="modal-body " id="model_table_value">
    </div>
    <div class="modal-footer">
        <button class="btn btn-small btn-success pull-left" type="button" id="btn_update" data-dismiss="modal">
            <i class="icon-ok bigger-100"></i>
            Save
        </button>
        <button class="btn btn-small btn-danger pull-left" data-dismiss="modal">
            <i class="icon-remove"></i>
            Close
        </button>


    </div>

</div>
<script type="text/javascript">
	$('.date-picker').datepicker().next().on(ace.click_event, function(){
     $(this).prev().focus();
    });
</script>