?
Current Path : /home1/savoy/public_html/savoyglobal.net/hr/application/views/Administration/ |
Linux gator3171.hostgator.com 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 |
Current File : /home1/savoy/public_html/savoyglobal.net/hr/application/views/Administration/add_item_reissue.php |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); $this->load->view('documentreadyfunctions'); ?> <script language="javascript" type="text/javascript"> jQuery(document).ready(function() { var currentTime = new Date() var month = currentTime.getMonth() + 1 var day = currentTime.getDate() var year = currentTime.getFullYear() var allotment_date = day+"-"+ month+"-"+year; suggestValues(allotment_date); <?php if(isset($employee_name)) { ?> show_item_box(); <?php } ?> }); function suggestValues() { $("#employee_name").autocomplete("<?= site_url() ?>/administration/all_employees", { width: 300, selectFirst: false }); } function show_item_box() { var employee_name = $('#employee_name').val(); var item_allotment_date = $('#item_allotment_date').val(); var alert_id = $('#alert_id').val(); if(item_allotment_date == "") { alert("Please select Allotment Date First"); } else if(employee_name == "") { alert("Please select Employee First"); } else { $("#item_box").empty().html('<CENTER><img src="<?=base_url()?>assets/images/loading.gif" class="loading"/></CENTER>'); employee_name = encodeURIComponent(employee_name); //alert("<?=site_url()?>/onboarding/load_items/item_box/"+employee_name); $("#item_box").load("<?=site_url()?>/administration/load_items/item_box/"+employee_name+"/"+alert_id); } } </script> <div class="select-bar"> <label> </label> <span class="heading">Allot tools and general items to employees</span> </div> <fieldset> <?php $attributes=array('id'=>'validateform','class'=>'customForm'); echo form_open('administration/addinadministration/insert_item_reissue/view_item_reissue/1',$attributes); if(isset($employee_name)) { $employee = urldecode($employee_name); echo "<input type='hidden' name='alert_id' id='alert_id' value='$alert_id'/>"; } else $employee = ""; ?> <ul> <li> <div id="multi"> <label for="data">Date of Allotment</label> <input type="text" name="item_allotment_date" id="item_allotment_date" value="<?=date("d-m-Y");?>" class="required" onchange="suggestValues()"> <img src="<?=base_url()?>assets/images/icons/calendar.png" alt="Click to popup the clendar!" /> </div> </li> <li> <label for="data">Select Employees</label> <input type="text" name="employee_name" id="employee_name" class="required" value="<?=$employee;?>" > <input type="button" value="Load Items" onclick="show_item_box()" style="margin-left: 5px; width: 80px;"/> <!--<img class="inliexample1" src="<?=base_url();?>assets/images/button-search.png" onclick="show_employees_popup()" title="Search" alt="Search" />--> </li> <div id='item_box'> </div> </ul> <?php echo form_close();?> </fieldset>