

<?php $__env->startSection('title', 'Users'); ?>
<?php $__env->startSection('dynamic_css_excpt'); ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('dynamic_css'); ?>
    <!-- <link href="https://cdn.datatables.net/1.10.19/css/dataTables.bootstrap4.min.css" media="all" rel="stylesheet" type="text/css"/>-->
    <link href="<?php echo asset('css/dataTables.bootstrap4.min.css'); ?>" media="all" rel="stylesheet" type="text/css"/>
    <link href="https://cdn.datatables.net/buttons/1.5.6/css/buttons.bootstrap4.min.css" media="all" rel="stylesheet" type="text/css"/>
    <style>
        select.form-control:not([size]):not([multiple]) {
            height: calc(1.95rem + 0px);
        }
        .panel-title{
            font-size: 15px;
            display: table-cell;
            vertical-align: middle;
        }
        .custom-col-md-6{
            width:50%;
            display: table;
            height: 40px;
        }
        .table td {
            padding: .5rem 1rem .5rem 1rem;
            vertical-align: middle;
            border-top: 1px solid #dee2e6;
        }
        .table .btn{
            min-width: 89px;
        }

        select options {
            text-transform: capitalize;
        }

        .text-blue{
            color: #304192;
            font-weight: 600;
            font-size: 14px;
        }
        /************************ slider button ************************************/

        /* The switch - the box around the slider */
        .switch {
            position: relative;
            display: inline-block;
            width: 55px;
            height: 26px;
        }

        /* Hide default HTML checkbox */
        .switch input {
            opacity: 0;
            width: 0;
            height: 0;
        }

        /* The slider */
        .slider {
            position: absolute;
            cursor: pointer;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: #ccc;
            /* background-color: red;*/
            -webkit-transition: .4s;
            transition: .4s;
        }

        .slider:before {
            position: absolute;
            content: "";
            height: 24px;
            width: 24px;
            left: 3px;
            bottom: 1px;
            background-color: white;
            -webkit-transition: .4s;
            transition: .4s;

        }

        input:checked + .slider {
            background-color: #2196F3;
            /* background-color: green;*/
        }

        input:focus + .slider {
            box-shadow: 0 0 1px #2196F3;
            /* background-color: green;*/
        }

        input:checked + .slider:before {
            -webkit-transform: translateX(26px);
            -ms-transform: translateX(26px);
            transform: translateX(26px);
        }

        /* Rounded sliders */
        .slider.round {
            border-radius: 34px;
        }

        .slider.round:before {
            border-radius: 50%;
        }

        .vl{
            height: 26px;
            border-left: 1px solid #999;
        }

        .fBlack{
            color:#999;
        }

        /*****************************************************************************/
        @media (max-width: 768px)
        {
            li.page-item {

                display: none;
            }
            .custom-col-md-6{
                width:50%;
                display: table;
                height: 34px;
            }
            .page-item.previous,
            .page-item.next,
            .page-item:first-child,
            .page-item:last-child,
            .page-item.active {

                display: block;
            }

            .result-set{
                padding-left: 15px;
                padding-right: 15px;
            }

            .btn.btn-sm,.btn.btn-xsm {
                padding: .3rem .7rem;
                font-size: .54rem;
            }
            .table .btn {
                min-width: 50px;
            }

            .btn.btn-xsm{
                padding: .2rem .2rem;
            }

            #data-table{
                width: 100% !important;
            }

        }

        .dataTables_filter{
            display: inline-block;
            float: right;
        }

        .btn-secondary {
            background-color: #1c7095!important;
            color: #fff!important;
            padding: .40rem .60rem;
        }

        .verification{
            width: 100% !important;
        }

        .verification tbody tr td:nth-child(8){
            text-align: center;
            /*display: flex;*/
        }
        .verification th{
            text-align: center;
        }
        /*        .verification td{
                    text-align: center;
                }*/

        .table .btn {
            min-width: 40px;
        }

        label{
            color: #3971d6;
            font-weight: 800;
        }

        .posting_view th,td{
            /*height: 30px;*/
        }
    </style>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>
    <div class="container">
        <div class="row container_layout">
            <div class="col-md-12 pl0 pr0 mobile_view">
                <nav aria-label="breadcrumb">
                    <ol class="breadcrumb">
                        <li class="breadcrumb-item">
                            <a href="<?php echo e(route('adminhome')); ?>">
                                <i class="material-icons">home</i>
                            </a>
                        </li>
                        <li class="breadcrumb-item"><a href="<?php echo e(route('employees')); ?>">Employees</a></li>
                        <li class="breadcrumb-item active"><a href="<?php echo e(route('employeeVerificationView')); ?>">Employee Verification</a></li>
                    </ol>
                </nav>
            </div>


            <div class="col-md-12 p20 bg-white">
                <div class="panel panel-default">
                    <div class="panel-heading ">

                        <div class="row e1f5fe bdbdbd grey lighten-1 custom_row_o" data-toggle="collapse" href="#collapseExample" aria-expanded="false" aria-controls="collapseExample" style="cursor: pointer;">
                            <div class="col-md-6 custom-col-md-6" style="max-width: 50%;">

                                <div class="panel-title pl5">
                                    <i class="fa fa-filter"></i> <span class="label_text"> Custom Filter </span>
                                </div>

                            </div>
                            <div class="col-md-6 custom-col-md-6 text-right" style="max-width: 50%;">

                            </div>
                        </div>

                    </div>
                    <div class="panel-body">
                        <div class="row bg_body custom_row_o">
                            <div class="col-md-12 collapse show mt10" id="collapseExample">

                                <?php echo e(csrf_field()); ?>

                                <div class="row result-set">
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue"> District </label>
                                        <select class="form-control input-md" id="district" name="district">
                                            <?php if($data['districts']): ?>
                                                <option value="" selected disabled>==== Select District ====</option>
                                                <option value="1" <?php if($data['district']==1): ?> <?php echo e('selected'); ?> <?php endif; ?>> All </option>

                                                <?php $__currentLoopData = $data['districts']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $dist): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                    <?php if(($data['district']) && ($data['district']==$dist->district_code)): ?>
                                                        <option value="<?php echo e($dist->district_code); ?>" selected> <?php echo e($dist->district_name); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($dist->district_code); ?>"> <?php echo e($dist->district_name); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php else: ?>
                                                <option value="<?php echo e($data['district']); ?>" selected><?php echo e($data['district_name']); ?></option>
                                            <?php endif; ?>
                                        </select>
                                    </div>
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue">Block</label>
                                        <select class="form-control input-md" id="block" name="block">

                                            <?php if($data['block_list']): ?>
                                                <option value="" disabled selected>==== Select A Block ====</option>
                                                <?php $__currentLoopData = $data['block_list']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $blk): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                    <?php if(($data['block']) && ($data['block']==$blk->block_id)): ?>
                                                        <option value="<?php echo e($blk->block_id); ?>" selected> <?php echo e($blk->block_name); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($blk->block_id); ?>"> <?php echo e($blk->block_name); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php elseif($data['block']): ?>
                                                <option value="<?php echo e($data['block']); ?>" selected><?php echo e($data['block_name']); ?></option>
                                            <?php else: ?>
                                                <option value="" disabled selected>==== Select A Block ====</option>
                                            <?php endif; ?>

                                        </select>
                                    </div>
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue">Gram Panchayat</label>
                                        <select class="form-control input-md" id="panchyat" name="panchyat">
                                            <option value="">==== Select Gram Panchayat ====</option>
                                            <?php if($data['panchyat_list']): ?>
                                                <?php $__currentLoopData = $data['panchyat_list']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $pan): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                    <?php if(($data['panchyat']) && ($data['panchyat']==$pan->gram_panchyat_id)): ?>
                                                        <option value="<?php echo e($pan->gram_panchyat_id); ?>" selected> <?php echo e($pan->gram_panchyat_name); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($pan->gram_panchyat_id); ?>"> <?php echo e($pan->gram_panchyat_name); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php endif; ?>
                                        </select>



                                    </div>
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue">Program</label>
                                        <select class="form-control input-md" id="program" name="program">
                                            <option value=""  selected>==== Select Program ====</option>
                                            <?php if($data['programe']): ?>
                                                <?php $__currentLoopData = $data['programe']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $pr): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

                                                    <?php if(($data['program_s']) && ($data['program_s']==$pr->program_id)): ?>
                                                        <option value="<?php echo e($pr->program_id); ?>" selected> <?php echo e($pr->program_name); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($pr->program_id); ?>"> <?php echo e($pr->program_name); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php endif; ?>
                                        </select>
                                    </div>
                                </div>
                                <div class="row result-set">
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue">Level</label>
                                        <select class="form-control input-md" id="level" name="level">
                                            <option value=""  selected>==== Select Levels ====</option>
                                            <?php if($data['level']): ?>
                                                <?php $__currentLoopData = $data['level']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $lev): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                    <?php if(($data['level_s']) && ($data['level_s']==$lev->level_id)): ?>
                                                        <option value="<?php echo e($lev->level_id); ?>" selected> <?php echo e($lev->level); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($lev->level_id); ?>"> <?php echo e($lev->level); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php endif; ?>
                                        </select>
                                    </div>
                                    <div class="col-md-3 mb-3">
                                        <label class="control-label text-blue"> Designation </label>
                                        <select class="form-control input-md" id="designation" name="designation">
                                            <option value="">==== Select Designation ====</option>
                                            <?php if($data['designation_list']): ?>
                                                <?php $__currentLoopData = $data['designation_list']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $des): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                    <?php if(($data['designation_s']) && ($data['designation_s']==$des->designation_id)): ?>
                                                        <option value="<?php echo e($des->designation_id); ?>" selected> <?php echo e($des->designation_name); ?> </option>
                                                    <?php else: ?>
                                                        <option value="<?php echo e($des->designation_id); ?>"> <?php echo e($des->designation_name); ?> </option>
                                                    <?php endif; ?>
                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <?php endif; ?>
                                        </select>
                                    </div>
                                    <div class="col-md-3 mb-3">
                                    <!--<label class="control-label text-blue">Service Status</label>
                                            <select class="form-control input-md" id="service_status" name="service_status">
                                                <option value="" disabled selected>==== Select Service Status ====</option>
                                                <?php if($data['status']): ?>
                                        <?php $__currentLoopData = $data['status']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $st): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>


                                            <?php if(($data['service_status']) && ($data['service_status']==$st->status_id)): ?>
                                                <option value="<?php echo e($st->status_id); ?>" selected> <?php echo e($st->status_name); ?> </option>
                                                        <?php else: ?>
                                                <option value="<?php echo e($st->status_id); ?>"> <?php echo e($st->status_name); ?> </option>
                                                        <?php endif; ?>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                    <?php endif; ?>
                                            </select>-->
                                    </div>
                                    <div class="col-md-3 text-right margin-auto">
                                        <button type="submit" class="btn btn-primary btn-sm search"><i class="fa fa-search" aria-hidden="true"></i> Search</button>
                                        <a href="" class="btn btn-warning  btn-sm"> <i class="fa fa-refresh" aria-hidden="true"></i> Reset</a>
                                    </div>
                                </div>

                            </div>
                        </div>
                        <div class="result-set mt10" id="no-more-tables">
                            <div class="row">
                                <div class="col-md-12 pl0 pr0">
                                    <table class="table table-responsive verification" cellspacing="10">
                                        <thead>
                                        <tr class="note note-primary">
                                            <th scope="col" class="note-dange">#</th>
                                            <th scope="col" style="width: 110px;">Employee Code</th>
                                            <th scope="col" style="width: 101px;">Employee Name</th>
                                            <th scope="col" style="width: 139px;">Designation</th>
                                            <th scope="col" style="width: 95px;">District</th>
                                            <th scope="col" style="width: 50px;">Block</th>
                                            <th scope="col" style="width: 45px;">GP</th>
                                            <th scope="col" style="width: 185px;">Is it per actual posting</th>
                                            <th></th>
                                        </tr>
                                        </thead>

                                    </table>

                                </div>
                            </div>
                        </div>


                    </div>
                </div>
            </div>



        </div>

    </div>

    <div class="modal fade top" id="fluidModalTopWarningDemo" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" data-backdrop="true"  style="display: none;" aria-hidden="true">
        <div class="modal-dialog modal-lg modal-top modal-notify modal-primary" role="document">
            <!--Content-->
            <div class="modal-content">
                <!--Header-->
                <div class="modal-header text-center">
                    <p class="heading lead">Submit Employee Current Posting Details</p>

                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true" class="white-text">×</span>
                    </button>
                </div>

                <!--Body-->
                <div class="modal-body">
                    <div class="container">
                        <div class="row">
                            <div class="col-md-12">
                                <!-- <div class="col-md-12">-->
                                <table class="posting_view">
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;">Employee Code</span></th>
                                        <td>:  <span style="font-weight: bold" id="emp_code"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;">Employee Name </span></th>
                                        <td>:  <span style="font-weight: bold" id="name"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;"> Designation </span></th>
                                        <td>:  <span style="font-weight: bold" id="des"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;"> Mobile </span></th>
                                        <td>:  <span style="font-weight: bold" id="mobile"></span></td>
                                    </tr>
                                </table>
                                <!-- </div>-->
                                <!--                                <p >Employee Code: <span style="font-weight: bold" id="emp_code"></span></p>
                                                                <p>Employee Name: <span style="font-weight: bold" id="name"></span></p>
                                                                <p>Designation: <span style="font-weight: bold" id="des"></span></p>
                                                                <p>Mobile: <span style="font-weight: bold" id="mobile"></span></p>-->
                            </div>

                        </div>
                        <hr>
                        <form method="post" id="verification_post">
                            <div class="row">
                                <div class="col-md-12">
                                    <div id="error"></div>
                                </div>

                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>District<span style="color: red">*</span></label>
                                        <select class="form-control" id="district_name" name="district_name" required>
                                            <option value="">Select District</option>
                                        </select>
                                    </div>
                                </div>
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Block</label>
                                        <select class="form-control" id="block_name" name="block_name" >

                                        </select>
                                    </div>
                                </div>
                                <input type="hidden" name="emp_code" id="ver_emp_code">
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>GP</label>
                                        <select class="form-control" id="gp_name" name="gp_name" >

                                        </select>
                                    </div>
                                </div>
                                <?php echo e(csrf_field()); ?>

                            </div>
                            <div class="row">
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order No<span style="color: red">*</span></label>
                                        <input type="text" name="order_no" class="form-control" id="order_no" required>
                                    </div>
                                </div>
                                <div class="col-md-4">

                                    <div class="form-group">
                                        <label>Order Copy<span style="color: red">*</span>(<span style="color: red;
    font-weight: 500;">pdf,docx,doc,jpg,jpeg</span>)</label>
                                        <input type="file" class="form-control" name="order_file" required>
                                    </div>

                                </div>

                            </div>
                            <div class="row">
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order Date<span style="color: red">*</span></label>
                                        <input type="date" class="form-control" name="order_date" required>
                                    </div>
                                </div>
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order Issued By<span style="color: red">*</span></label>
                                        <select class="form-control" name="order_issue">
                                            <option value=""selected>Select</option>
                                            <option value="CPRD">CPRD</option>

                                            <option value="CEO">CEO</option>
                                            <option value="BDO">BDO</option>
                                            <option value="Project Director">Project Director</option>

                                        </select>
                                    </div>
                                </div>

                            </div>
                            <div class="row ">
                                <div class="col-md-12 text-right">
                                    <button type="submit" name="" class="btn btn-sm btn-success">Submit</button>
                                    <button type="submit" data-dismiss="modal" aria-label="Close" name="" class="btn btn-sm btn-danger">Cancel</button>
                                </div>
                            </div>

                        </form>
                    </div>
                </div>
            </div>
        </div>

        <!--Footer-->

    </div>
    <!--/.Content-->



    <div class="modal fade top" id="fluidModalTopWarningDemoView" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" data-backdrop="true"  style="display: none;" aria-hidden="true">
        <div class="modal-dialog modal-lg modal-top modal-notify modal-primary" role="document">
            <!--Content-->
            <div class="modal-content">
                <!--Header-->
                <div class="modal-header">
                    <p class="heading lead">Employee Current Posting Information</p>

                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true" class="white-text">×</span>
                    </button>
                </div>

                <!--Body-->
                <div class="modal-body">
                    <div class="container">
                        <div class="row">
                            <div class="col-md-12">
                                <table class="posting_view">
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;">Employee Code</span></th>
                                        <td>:  <span style="font-weight: bold" id="emp_code_view"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;">Employee Name </span></th>
                                        <td>:  <span style="font-weight: bold" id="name_view"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;"> Designation </span></th>
                                        <td>:  <span style="font-weight: bold" id="des_view"></span></td>
                                    </tr>
                                    <tr>
                                        <th><span style="color: #3971d6;font-weight: 800;"> Mobile </span></th>
                                        <td>:  <span style="font-weight: bold" id="mobile_view"></span></td>
                                    </tr>
                                </table>
                            </div>

                        </div>
                        <hr>
                        <div id="view_sec">
                            <div class="row">
                                <div id="error"></div>
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>District</label>
                                        <p><span id="district_name_view"></span></p>
                                    </div>
                                </div>
                                <div class="col-md-4" id="block_sec">
                                    <div class="form-group">
                                        <label>Block</label>
                                        <p><span id="block_name_view"></span></p>
                                    </div>
                                </div>
                                
                                <div class="col-md-4" id="gp_sec">
                                    <div class="form-group">
                                        <label>GP</label>
                                        <p><span id="gp_name_view"></span></p>
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order No</label>
                                        <p><span id="order_no_view"></span></p>
                                    </div>
                                </div>
                                <div class="col-md-4">
                                    <label>Order Copy</label>
                                    <p><a  id="order_copy_view_test" target="_blank"><i class="fa fa-eye fa-lg"></i></a></p>

                                </div>

                            </div>
                            <div class="row">
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order Date</label>
                                        <p><span id="order_date_view"></span></p>
                                    </div>
                                </div>
                                <div class="col-md-4">
                                    <div class="form-group">
                                        <label>Order Issued By</label>
                                        <p><span id="order_issue_view"></span></p>
                                    </div>
                                </div>

                            </div>
                            <hr>
                            <p><span>Verifier Details</span></p>
                            <div class="row">
                                <div class="col-md-3">
                                    <div class="form-group">
                                        <label>Verified BY</label>
                                        <p id="verify_emp_code"></p>
                                    </div>
                                </div>
                                <div class="col-md-3">
                                    <div class="form-group">
                                        <label>Verified Date</label>
                                        <p id="verify_date"></p>
                                    </div>
                                </div>


                            </div>
                            <div class="row">
                                <!-- <button type="submit" id="edit_form" class="btn btn-sm btn-success">Edit</button>-->
                                <button type="submit" data-dismiss="modal" aria-label="Close" name="" class="btn btn-sm btn-danger">Cancel</button>

                            </div>

                        </div>
                        <input type="hidden" id="edit_emp_code">
                        <div id="edit_sec">

                            <form method="post" id="edit_post">
                                <div class="row">
                                    <div id="error"></div>
                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>District<span style="color: red">*</span></label>
                                            <select class="form-control" id="district_name" name="district_name" required>
                                                <option value="">Select District</option>
                                            </select>
                                        </div>
                                    </div>
                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>Block<span style="color: red">*</span></label>
                                            <select class="form-control" id="block_name" name="block_name" required>

                                            </select>
                                        </div>
                                    </div>

                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>GP<span style="color: red">*</span></label>
                                            <select class="form-control" id="gp_name" name="gp_name" required>

                                            </select>
                                        </div>
                                    </div>
                                    <?php echo e(csrf_field()); ?>

                                </div>
                                <div class="row">
                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>Order No<span style="color: red">*</span></label>
                                            <input type="text" name="order_no_edit" class="form-control" id="order_no" required>
                                        </div>
                                    </div>
                                    <div class="col-md-4">
                                        <label>Order Copy<span style="color: red">*</span></label>
                                        <div class="input-group">

                                            <div class="input-group-prepend">
                                                <span class="input-group-text" id="inputGroupFileAddon01">Upload</span>
                                            </div>
                                            <div class="custom-file">
                                                <input type="file" class="custom-file-input" name="order_file" id="inputGroupFile01"
                                                       aria-describedby="inputGroupFileAddon01" required>
                                                <label class="custom-file-label" for="inputGroupFile01">Choose file</label>
                                            </div>
                                        </div>
                                    </div>

                                </div>
                                <div class="row">
                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>Order Date<span style="color: red">*</span></label>
                                            <input type="date" class="form-control" name="order_date_edit" required>
                                        </div>
                                    </div>
                                    <div class="col-md-4">
                                        <div class="form-group">
                                            <label>Order Issued By<span style="color: red">*</span></label>
                                            <select class="form-control" name="order_issue_edit" required>
                                                <option value="">Select</option>
                                                <option value="CEO">CEO</option>
                                                <option value="BDO">BDO</option>

                                            </select>
                                        </div>
                                    </div>

                                </div>
                                <div class="row">
                                    <button type="submit" name="" class="btn btn-success">Submit</button>
                                    <button type="submit" id="cancel_edit_form" class="btn btn-danger">Cancel</button>

                                </div>

                            </form>
                        </div>


                    </div>
                </div>
            </div>
        </div>
    </div>










<?php $__env->stopSection(); ?>

<?php $__env->startSection('dynamic_js'); ?>
    <script src="<?php echo e(asset('js/lib/jquery.dataTables.min.js')); ?>"></script>
    <script src="<?php echo e(asset('js/lib/dataTables.bootstrap4.min.js')); ?>"></script>


    <script src="https://cdn.datatables.net/buttons/1.5.6/js/dataTables.buttons.min.js"></script>
    <script src="https://cdn.datatables.net/buttons/1.5.6/js/buttons.bootstrap4.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/pdfmake.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/vfs_fonts.js"></script>
    <script src="https://cdn.datatables.net/buttons/1.5.6/js/buttons.html5.min.js"></script>
    <script src="https://cdn.datatables.net/buttons/1.5.6/js/buttons.print.min.js"></script>
    <script src="https://cdn.datatables.net/buttons/1.5.6/js/buttons.colVis.min.js"></script>
    <script src="<?php echo e(asset('vendor/datatables/buttons.server-side.js')); ?>"></script>
    <script src="<?php echo e(asset('plugins/bootstrap-material-datetimepicker/js/bootstrap-material-datetimepicker.js')); ?>"></script>

    <!--<script src="https://cdn.datatables.net/1.10.19/js/jquery.dataTables.min.js"></script>
    <script src="https://cdn.datatables.net/1.10.19/js/dataTables.bootstrap4.min.js"></script>-->
    <script>
        var imgUrl=$('#image_url').val();

        $('#district').on('change',function(e){
            e.preventDefault()
            var  selected_district=$(this).val();

            $('.page-loader-wrapper').fadeIn();
            $.ajax({
                type: "GET",
                url: "<?php echo e(route('get_block_list')); ?>",
                data: {
                    district_code: selected_district
                },
                dataType: "json",
                success: function (data) {
                    $('#block').empty();
                    $('#block').append('<option value=""  selected>==== Select A Block ====</option>');
                    if (data.msgType == true) {
                        $.each(data.data,function(key,value){
                            $('#block').append('<option value=" '+value.block_id+' ">'+value.block_name+'</option>');
                        });

                    }else{
                        toastr.error(data.msg);
                    }
                },
                error: function (jqXHR, textStatus, errorThrown) {

                    callAjaxErrorFunction(jqXHR, textStatus, errorThrown);
                },
                complete: function (data) {
                    $('.page-loader-wrapper').fadeOut();
                }
            });
        })


        $(document).on('change','#block',function(e){
            e.preventDefault()
            var  selected_gp=$(this).val();
            get_level_by_block();
            $('.page-loader-wrapper').fadeIn();
            $.ajax({
                type: "GET",
                url: "<?php echo e(route('get_gp_list')); ?>",
                data: {
                    gp_code: selected_gp
                },
                dataType: "json",
                success: function (data) {
                    $('#panchyat').empty();
                    $('#panchyat').append('<option value=""  selected>==== Select Gram Panchayat ====</option>');
                    if (data.msgType == true) {
                        $.each(data.data,function(key,value){
                            $('#panchyat').append('<option value=" '+value.gram_panchyat_id+' ">'+value.gram_panchyat_name+'</option>');
                        });



                        $('#panchyat').on('change',function(e){
                            e.preventDefault();
                            get_level_by_gp();
                        })



                    }else{
                        toastr.error(data.msg);
                    }
                },
                error: function (jqXHR, textStatus, errorThrown) {

                    callAjaxErrorFunction(jqXHR, textStatus, errorThrown);
                },
                complete: function (data) {
                    $('.page-loader-wrapper').fadeOut();
                }
            });
        })



        $('.btn-edit').on('click',function(e){
            e.preventDefault;
            var employee_code=$(this).data('id');
            $('#employee_code_of_employee').val(employee_code);
            $('#employeeDataDisplay').submit();
        })



        function get_level_by_block(){
            $('#level option:selected').removeAttr('selected');

            $("#level > option").each(function() {
                if(this.value=='3'){
                    $(this).attr("selected","selected");
                }
            });
            var  program=$('#program').val();
            var  level='3';
            get_designation_data(program,level)
        }

        function get_level_by_gp(){
            $('#level option:selected').removeAttr('selected');

            $("#level > option").each(function() {
                if(this.value=='4'){
                    $(this).attr("selected","selected");
                }
            });
            var  program=$('#program').val();
            var  level='4';
            get_designation_data(program,level)
        }







        $('#program').on('change',function(e){
            e.preventDefault()
            var  program=$(this).val();
            var  level=$('#level').val();
            /* get_designation_data(program,level)*/
        })

        $('#level').on('change',function(e){
            e.preventDefault()
            var  program=$('#program').val();
            var  level=$(this).val();
            get_designation_data(program,level)
        })

        function get_designation_data(program,level){
            $('.page-loader-wrapper').fadeIn();
            $.ajax({
                type: "GET",
                url: "<?php echo e(route('get_designation_by_program')); ?>",
                data: {
                    program: program,level:level
                },
                dataType: "json",
                success: function (data) {
                    $('#designation').empty();
                    $('#designation').append('<option value=""  selected>==== Select Designation ====</option>');
                    if (data.msgType == true) {
                        $.each(data.data,function(key,value){
                            $('#designation').append('<option value=" '+value.designation_id+' ">'+value.designation_name+'</option>');
                        });
                    }else{
                        /*toastr.error(data.msg);*/
                    }
                },
                error: function (jqXHR, textStatus, errorThrown) {

                    callAjaxErrorFunction(jqXHR, textStatus, errorThrown);
                },
                complete: function (data) {
                    $('.page-loader-wrapper').fadeOut();
                }
            });
        }



        $(document).on('input','.account_action',function(e){

            var id=$(this).parent('label').data('id');

            /*$('.page-loader-wrapper').fadeIn();*/
            $.ajax({
                type: "GET",
                url: "<?php echo e(route('accountaction')); ?>",
                data: {
                    id: id
                },
                dataType: "json",
                success: function (data) {
                    if (data.msgType == true) {
                        toastr.success(data.msg);
                    }else{
                        toastr.error(data.msg);
                    }

                    table.ajax.reload(null, false);
                },
                error: function (jqXHR, textStatus, errorThrown) {

                    callAjaxErrorFunction(jqXHR, textStatus, errorThrown);
                },
                complete: function (data) {
                    /* $('.page-loader-wrapper').fadeOut();*/
                }
            });
        })


        /*function get_user_list(){
         $('.page-loader-wrapper').fadeIn();
         var form = $('#search-form')[0];
         var data = new FormData(form);
         $.ajax({
         type: "POST",
         enctype: 'multipart/form-data',
         processData: false,
         contentType: false,
         cache: false,
         url: "<?php echo e(route('get_user_by_condition')); ?>",
         data: data,
         dataType: "json",
         success: function (data) {
         if(data.msgType == true) {
         $('#data-table-body').empty();
         var i=1;
         $.each(data.data,function(key,value){
         var action_btn='';
        <?php if (app(\Illuminate\Contracts\Auth\Access\Gate::class)->check('edit_users', 'delete_users')): ?>
        action_btn='<td class="text-center">Actions</td>'+
        <?php endif; ?>
        $('#data-table-body').append('<tr>'+
         '<td>'+i+'</td>'+
         '<td>'+value.username+'</td>'+
         '<td>'+value.email+'</td>'+
         '<td>'+value.roles+'</td>'+
         '<td>Created At</td>'+
         '<td>Status</td>'+
         +action_btn+
         '</tr>');
         i++;
         });




         }else {
         toastr.error(data.msg)
         }
         },
         error: function (jqXHR, textStatus, errorThrown) {
         callAjaxErrorFunction(jqXHR, textStatus, errorThrown);
         },
         complete: function (data) {
         $('.page-loader-wrapper').fadeOut();
         }
         });
         }

         get_user_list();*/
        $(document).ready(function () {


            $('.verification').DataTable({
                "processing": true,
                "serverSide": true,
                "ajax": {
                    "url": "<?php echo e(route('employeeVerificationViewData')); ?>",
                    "data": function (d) {
                        d.dis_id=$('#district').val();
                        d.block_id=$('#block').val();
                        d.panchayat_id=$('#panchyat').val();
                        d.program_id=$('#program').val();
                        d.level_id=$('#level').val();
                        d.des_id=$('#designation').val();
                        d.ser_status=$('#service_status').val();
                    }
                },
                "createdRow": function (row, data, rowIndex) {
                    // Per-cell function to do whatever needed with cells
                    $.each($('td', row), function (colIndex) {
                        // For example, adding data-* attributes to the cell
                        if(colIndex==0)
                            $(this).attr('data-title', "Sl No");
                        else if(colIndex==1)
                            $(this).attr('data-title', "Employee Code");
                        else if(colIndex==2)
                            $(this).attr('data-title', "Employee Name");
                        else if(colIndex==3)
                            $(this).attr('data-title', "Designation");
                        else if(colIndex==4)
                            $(this).attr('data-title', "District");
                        else if(colIndex==5)
                            $(this).attr('data-title', "Block");
                        else if(colIndex==6)
                            $(this).attr('data-title', "GP");
                        else
                            $(this).attr('data-title', "As per posting");
                    });
                },
                "columns": [
                    {data: 'DT_Row_Index', name: 'DT_Row_Index'},
                    {"data": "employee_code"},
                    {"data": "name"},
                    {"data": "designation_name"},
                    {"data": "district_name"},
                    {"data": "block_name"},
                    {"data": "gram_panchyat_name"},
                    {"data": "action"},

                ]


            });
            $(document).on('click', '.search', function (e) {
                e.preventDefault();
                $('.verification').DataTable().ajax.reload();

            });

            $(document).on('click','#yes',function (e) {
                e.preventDefault();
                var code=$(this).attr('href');
                var btn = $(this).data('value');
                if(btn==1){
                    swal({
                        title: 'Are you sure?',
                        text: "This Employee is posted as per HCMS system ?",
                        type: 'warning',
                        showCancelButton: true,
                        confirmButtonColor: '#3085d6',
                        cancelButtonColor: '#d33',
                        confirmButtonText: "CONFIRM",
                        cancelButtonText: "CANCEL"
                    }).then((result) => {
                        if (result.value
                )
                    {
                        $.ajax({
                            headers: {
                                'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                            },
                            type: "POST",
                            url: "<?php echo e(route('employeeVerificationYes')); ?>",
                            dataType: 'json',
                            data: {'code': code},
                            success: function (data) {
                                if (data.msg == 'success') {

                                    swal("Success!", "Thank you for verifying employee current posting", "success");
                                    $('.verification').DataTable().ajax.reload();


                                }
                                if (data.msg == 'failed') {

                                    Swal.fire({
                                        type: 'error',
                                        title: 'Oops...',
                                        text: 'Something went wrong!'
                                    })
                                }
                            },
                            error: function (jqXHR, textStatus, errorThrown) {

                                Swal.fire({
                                    type: 'error',
                                    title: 'Oops...',
                                    text: 'Something went wrong!',

                                })
                            }
                        })
                    }
                })


                }


            });

            $(document).on('click','#no',function (e) {
                e.preventDefault();
                var code_no=$(this).attr('href');
                var btn_no = $(this).data('value');
                $('#emp_code').empty();
                $('#name').empty();
                $('#mobile').empty();
                $('#des').empty();
                $('#district_name').empty();
                $('#block_name').empty();

                var option = "<option value=''>Select Block Name</option>";
                $('#block_name').append(option);
                $('#gp_name').empty();
                var option = "<option value=''>Select Gram Panchayat</option>";
                $('#gp_name').append(option);
                if(btn_no==2){
                    $.ajax({
                        headers: {
                            'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                        },
                        type: "POST",
                        url: "<?php echo e(route('employeeVerificationNo')); ?>",
                        dataType: 'json',
                        data: {'code_no': code_no},
                        success: function (data) {
                            if (data.msg == 'success') {
                                $('#emp_code').append(data.emp.employee_code);
                                $('#name').append(data.emp.name);
                                $('#mobile').append(data.emp.mobile);
                                $('#des').append(data.emp.designation_name);
                                $('#fluidModalTopWarningDemo').modal('show');
                                $('#verification_post')[0].reset();
                                $('#ver_emp_code').val(data.emp.employee_code);
                                var option = "<option value=''>Select District</option>";
                                $.each(data.district, function (index, value) {                                                                        option += '<option value="'+value.district_code+'">'+value.district_name+'</option>';
                                });
                                $('#district_name').append(option);

                                //swal("Success!", "Thank you for verifying employee current posting", "success");
//                                    var option = "<option value=''>Select District</option>";
//                                    for(var i = 0; i < data.district.length; i++){
//                                        option += "<option value='"+data.district[i].district_code+"'>"+data.district[i].district_name+"</option>";
//                                    }
//                                    $('#district_name').append(option);

                            }
                            if (data.msg == 'failed') {

                                Swal.fire({
                                    type: 'error',
                                    title: 'Oops...',
                                    text: 'Something went wrong!'
                                })
                            }
                        },
                        error: function (jqXHR, textStatus, errorThrown) {

                            Swal.fire({
                                type: 'error',
                                title: 'Oops...',
                                text: 'Something went wrong!',

                            })
                        }
                    })
                }
            })

            $(document).on('change','#district_name',function () {
                var dis_id=$('#district_name').val();
                $('#block_name').empty();
                var option = "<option value=''>Select Block Name</option>";
                $('#block_name').append(option);
                $('#gp_name').empty();
                var option = "<option value=''>Select Gram Panchayat</option>";
                $('#gp_name').append(option);
                $.ajax({
                    headers: {
                        'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                    },
                    type: "POST",
                    url: "<?php echo e(route('employeeVerificationGetBlock')); ?>",
                    dataType: 'json',
                    data: {'dis_id': dis_id},
                    success: function (data) {
                        if (data.msg == 'success') {
                            $('#block_name').empty();
                            var option = "<option value=''>Select Block Name</option>";
                            $.each(data.block,function (index,value) {
                                option += '<option value="'+value.block_id+'">'+value.block_name+'</option>'
                            });

                            $('#block_name').append(option);
                        }
                        if (data.msg == 'failed') {

                            Swal.fire({
                                type: 'error',
                                title: 'Oops...',
                                text: 'Something went wrong!'
                            })
                        }
                    },
                    error: function (jqXHR, textStatus, errorThrown) {

                        Swal.fire({
                            type: 'error',
                            title: 'Oops...',
                            text: 'Something went wrong!',

                        })
                    }
                })

            });

            $(document).on('change','#block_name',function () {
                var block_id=$('#block_name').val();
                $('#gp_name').empty();
                var option = "<option value=''>Select Gram Panchayat</option>";
                $('#gp_name').append(option);
                $.ajax({
                    headers: {
                        'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                    },
                    type: "POST",
                    url: "<?php echo e(route('employeeVerificationGetGp')); ?>",
                    dataType: 'json',
                    data: {'block_id': block_id},
                    success: function (data) {
                        if (data.msg == 'success') {
                            $('#gp_name').empty();
                            var option = "<option value=''>Select Gram Panchayat</option>";
                            $.each(data.gp,function (index,value) {
                                option += '<option value="'+value.gram_panchyat_id+'">'+value.gram_panchyat_name+'</option>'
                            });

                            $('#gp_name').append(option);
                        }
                        if (data.msg == 'failed') {

                            Swal.fire({
                                type: 'error',
                                title: 'Oops...',
                                text: 'Something went wrong!'
                            })
                        }
                    },
                    error: function (jqXHR, textStatus, errorThrown) {

                        Swal.fire({
                            type: 'error',
                            title: 'Oops...',
                            text: 'Something went wrong!',

                        })
                    }
                })

            });


            $(document).on('submit','#verification_post',function (e) {
                e.preventDefault();



                $('.page-loader-wrapper').fadeIn();


                $.ajax({
                    type: "POST",
                    url: "<?php echo e(route('employeeVerificationFormSubmit')); ?>",
                    dataType: 'json',
                    data: new FormData(this),
                    contentType: false,
                    cache: false,
                    processData: false,
                    success: function (data) {

                        $('.page-loader-wrapper').fadeOut();
                        if(data.msg=="validationFails"){
                            $.each(data.data, function (index, value) {
                                $('#error').append('<div class="alert alert-danger alert-dismissible" role="alert"><button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button><strong>Warning!</strong>'+value+'</div>');
                            });
                        }
                        if(data.msg=="success"){

                            $('#fluidModalTopWarningDemo').modal('hide');
                            $('.verification').DataTable().ajax.reload();

                            swal("Success!", "Thankyou for verifying employee current posting!", "success");

                        }

                    },
                    error: function (jqXHR, textStatus, errorThrown) {


                    }
                });


            })



            $('#edit_sec').hide();
            $(document).on('click','#view',function (e) {
                e.preventDefault();
                var code_no=$(this).attr('href');
                $('#emp_code_view').empty();
                $('#name_view').empty();
                $('#mobile_view').empty();
                $('#des_view').empty();
                $('#district_name_view').empty();
                $('#block_name_view').empty();
                $('#gp_name_view').empty();
                $('#order_no_view').empty();
                $('#order_date_view').empty();
                $('#order_issue_view').empty();
                $('#verify_emp_code').empty();
                $('#verify_emp_name').empty();
                $('#verify_emp_des').empty();
                $('#verify_date').empty();
                $('#order_copy_view_test').attr("href","");
                $('#view_sec').show();
                $('#edit_sec').hide();

                $.ajax({
                    headers: {
                        'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                    },
                    type: "POST",
                    url: "<?php echo e(route('employeeVerificationViewDoc')); ?>",
                    dataType: 'json',
                    data: {'code_no': code_no},
                    success: function (data) {
                        if (data.msg == 'success') {

                            $('#fluidModalTopWarningDemoView').modal('show');
                            $('#emp_code_view').append(data.data.employee_code);
                            $('#edit_emp_code').val(data.data.employee_code);

                            $('#name_view').append(data.data.name);
                            $('#mobile_view').append(data.data.mobile);
                            $('#des_view').append(data.data.designation_name);
                            $('#district_name_view').append(data.data.district_name);
                            $('#block_name_view').append(data.data.block_name);
                            $('#gp_name_view').append(data.data.gram_panchyat_name);
                            $('#order_no_view').append(data.data.order_no);
                            $('#order_copy_view_test').attr("href", "http://pnrdhcms.org/hcms/storage/app/"+data.data.order_file)
                            $('#order_date_view').append(data.data.order_date);
                            $('#order_issue_view').append(data.data.order_issued_by);
                            $('#verify_emp_code').append(data.data.approved_by);
                            $('#verify_date').append(data.data.verified_date);


                        }
                        if (data.msg == 'failed') {

                            Swal.fire({
                                type: 'error',
                                title: 'Oops...',
                                text: 'Something went wrong!'
                            })
                        }
                    },
                    error: function (jqXHR, textStatus, errorThrown) {

                        Swal.fire({
                            type: 'error',
                            title: 'Oops...',
                            text: 'Something went wrong!',

                        })
                    }
                })


            })


            $(document).on('click','#edit_form',function (e) {
                e.preventDefault();
                $('#view_sec').hide(500);
                $('#edit_sec').show(500);
                var code= $('#edit_emp_code').val();

                $.ajax({
                    headers: {
                        'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                    },
                    type: "POST",
                    url: "<?php echo e(route('employeeVerificationEditView')); ?>",
                    dataType: 'json',
                    data: {'code': code},
                    success: function (data) {
                        if (data.msg == 'success') {


                        }
                        if (data.msg == 'failed') {

                            Swal.fire({
                                type: 'error',
                                title: 'Oops...',
                                text: 'Something went wrong!'
                            })
                        }
                    },
                    error: function (jqXHR, textStatus, errorThrown) {

                        Swal.fire({
                            type: 'error',
                            title: 'Oops...',
                            text: 'Something went wrong!',

                        })
                    }
                })


            });

            $(document).on('click','#cancel_edit_form',function (e) {
                e.preventDefault();
                $('#view_sec').show(500);
                $('#edit_sec').hide(500);
            })












        });



    </script>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.app2', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>