File manager - Edit - /home/autoph/public_html/connect/home/portal_bodya.php
Back
<div style='background:#180b1c;text-align:left;vertical-align:top;height:50px;margin:0px;width:100%;border-bottom:1px solid black;padding:15px;font-family:Verdana;font-weight:normal;font-size:18px;color:#ffffff'> 📍 CLEARANCE FOR APPROVAL </div> <script type="text/javascript"> $(function () { $('.showMenu').click(function () { $('.DivToHide').show(); }); $('.showMenu').click(function () { $('.DivToHide').hide(); }); }); function showApprovalWindow(){ var diva=document.getElementById("approvalWindow"); if (diva.style.display == 'none') { diva.style.display = ''; } else { diva.style.display = 'none'; } } </script> <script language="javascript" type="text/javascript"> function showClearanceInfo(row) { var x=row.cells; document.getElementById("ViewEmpID").value = x[1].innerHTML; document.getElementById("ViewEmpName").value = x[4].innerHTML; document.getElementById("ViewCompanyAssignment").value = x[3].innerHTML; document.getElementById("ViewPositionTitle").value = x[5].innerHTML; document.getElementById("ViewPositionStatus").value = x[6].innerHTML; document.getElementById("ViewUnitAssignment").value = x[7].innerHTML; document.getElementById("ViewReason").value = x[8].innerHTML; document.getElementById("ViewNotes").value = x[12].innerHTML; document.getElementById("ViewFrom").value = x[9].innerHTML; document.getElementById("ViewTo").value = x[10].innerHTML; document.getElementById("viewInclusive").value = x[11].innerHTML; } function hideAssignMsg(){ $("#saveMessage").fadeOut(10000); }; function showAssignMsg(){ $("#saveMessage").fadeIn(); }; </script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <div id="wait" style="display:none;width:400px;height:100px;border:0px solid red;position:absolute;top:50%;left:45%;padding:2px;z-index:999999999999999999"> <img src='images/demo_wait.gif' width="64" height="64" /><br>Scanning. Please wait....</div> <!-- add jquery --> <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.js"></script> <script type="text/javascript"> $(document).ready(function(){ $(document).ajaxStart(function(){ $("#wait").css("display", "block"); }); $(document).ajaxComplete(function(){ $("#wait").css("display", "none"); }); $("#ApprovalClearance").click(function(){ var ViewEmpID = $("#ViewEmpID").val(); var approvalComment = $("#approvalComment").val(); var uempID = $("#uempID").val(); showAssignMsg(); alert(uempID); hideAssignMsg(); return false; if (empIDNO == "") { $('#empIDNO').focus(); $('#empIDNO').css({'border':'1px solid red'}); $('#empIDNO').css({'color':'red'}); $('#empIDNO').attr("placeholder","Required filed*"); return false; } $.ajax({ url: "#.php", type: "POST", async: false, data: { "positionType":positionType, "myUser":myUser, "empInclusive":empInclusive, "done": 1 }, success: function(d){ showAssignMsg(); $("#saveMessage").html(d); } }) }); }); </script> <div style="width:100%;overflow:auto;height:400px;border:0px solid red"> <?php $getNewC = mysql_query("SELECT * FROM emp_clearance WHERE closed = 0 AND posted = 1 ORDER BY e_id DESC"); echo "<table style='width:150%'>"; echo "<thead>"; echo "<th style='width:20px'>NO</th>"; echo "<th style='width:50px'>EMP. ID</th>"; echo "<th style='width:100px'>DATE RECEIVED</th>"; echo "<th style='width:100px'>COMPANY</th>"; echo "<th style='width:150px'>NAME</th>"; echo "<th style='width:100px'>POSITION</th>"; echo "<th style='width:100px'>POSITION STEATUS</th>"; echo "<th style='width:100px'>DEPARTMENT</th>"; echo "<th style='width:150px'>REASON</th>"; echo "<th style='width:100px'>FROM</th>"; echo "<th style='width:100px'>TO</th>"; echo "<th style='width:100px'>EFFECTIVITY</th>"; echo "<th style='width:150px'>NOTE</th>"; echo "<th style='width:140px;border-left:0px solid red'>COMPLETION</th>"; echo "</thead>"; while($row=mysql_fetch_array($getNewC)){ $chkIfExist = mysql_result(mysql_query("SELECT COUNT('id') FROM `emp_clearance_data` WHERE `approving_officer_A`='$myEmpID' || `approving_officer_B`='$myEmpID' "),0); //echo $myEmpID; if($chkIfExist > 0){ $empID = $row['emp_id']; $checkClearingDept = mysql_result(mysql_query("SELECT COUNT(id) FROM emp_clearance_data WHERE `emp_id`='$empID'"),0); $checkApproved = mysql_result(mysql_query("SELECT COUNT(id) FROM emp_clearance_data WHERE `emp_id`='$empID' AND `approved_by`!=0 AND `date_approved`!=''"),0); $comRate =($checkApproved / $checkClearingDept) * 100; $comRate=number_format($comRate,1,'.','').'%' ; $dateC = $row['date_created']; $dc = explode(".",$dateC); $dateCreated = $dc[0]; $isPosted = $row['posted']; if ($isPosted == 1){ $tColor='black'; $posted = "POSTED"; }else{ $posted = "UNPOSTED"; $tColor='red'; } $count=$count + 1; ?><tr onclick="javascript:showClearanceInfo(this);" ondblclick="showApprovalWindow()"><?php echo "<td style='text-align:center;padding:10px'>".$count."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['emp_id']."</td>"; echo "<td style='text-align:center;padding:5px;font-family:Arial;color:$tColor'>".$row['posted_date']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['comp_id']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['emp_name']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['position_title']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['emp_status']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['department']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['reason_of_clearance']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['from_origin']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['to_origin']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['effectivity_date']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['reason_notes']."</td>"; echo "<td style='text-align:left;padding:1px;'><div style='width:100%;background:white;border:1px solid orange;padding:1px'> <div style='height:15px;text-align:center;padding:2px; border:1px solid orange;background:#f8e482;width:$comRate;font-family:Arial;font-size:10px;color:blue'>".$comRate."</div> </div></td>"; echo "</tr>"; } } echo "</table>"; ?> </div> <div style="width:100%;overflow:auto;height:240px;border:0px solid red"> <div style='background:#fff;text-align:left;vertical-align:top;height:50px;margin:0px;width:100%;border-bottom:1px solid black;padding:15px;font-family:Verdana;font-weight:normal;font-size:18px;color:#000'> 📍 MY CLEARANCE </div> <?php $getNewC = mysql_query("SELECT * FROM emp_clearance WHERE closed = 0 AND posted = 1 ORDER BY e_id DESC"); echo "<table style='width:100%'>"; echo "<thead>"; echo "<th style='width:20px'>NO</th>"; echo "<th style='width:50px'>EMP. ID</th>"; echo "<th style='width:100px'>DATE CREATED</th>"; echo "<th style='width:100px'>COMPANY</th>"; echo "<th style='width:150px'>NAME</th>"; echo "<th style='width:100px'>POSITION</th>"; echo "<th style='width:140px;border-left:0px solid red'>COMPLETION</th>"; echo "</thead>"; while($row=mysql_fetch_array($getNewC)){ $chkIfExist = mysql_result(mysql_query("SELECT COUNT('id') FROM `emp_clearance_data` WHERE `approving_officer_A`='$myEmpID' || `approving_officer_B`='$myEmpID' "),0); //echo $myEmpID; if($chkIfExist > 0){ $empID = $row['emp_id']; $checkClearingDept = mysql_result(mysql_query("SELECT COUNT(id) FROM emp_clearance_data WHERE `emp_id`='$empID'"),0); $checkApproved = mysql_result(mysql_query("SELECT COUNT(id) FROM emp_clearance_data WHERE `emp_id`='$empID' AND `approved_by`!=0 AND `date_approved`!=''"),0); $comRate =($checkApproved / $checkClearingDept) * 100; $comRate=number_format($comRate,1,'.','').'%' ; $dateC = $row['date_created']; $dc = explode(".",$dateC); $dateCreated = $dc[0]; $isPosted = $row['posted']; if ($isPosted == 1){ $tColor='black'; $posted = "POSTED"; }else{ $posted = "UNPOSTED"; $tColor='red'; } $count=$count + 1; ?><tr onclick="javascript:showClearanceInfo(this);" ondblclick="showApprovalWindow()"><?php echo "<td style='text-align:center;padding:10px'>".$count."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['emp_id']."</td>"; echo "<td style='text-align:center;padding:5px;font-family:Arial;color:$tColor'>".$row['posted_date']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['comp_id']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['emp_name']."</td>"; echo "<td style='text-align:left;padding:5px'>".$row['position_title']."</td>"; echo "<td style='text-align:left;padding:1px;'><div style='width:100%;background:white;border:1px solid orange;padding:1px'> <div style='height:15px;text-align:center;padding:2px; border:1px solid orange;background:#f8e482;width:$comRate;font-family:Arial;font-size:10px;color:blue'>".$comRate."</div> </div></td>"; echo "</tr>"; } } echo "</table>"; ?> </div> <div id="approvalWindow" style="display:none;border:1px solid black;top:100px;left:10px;width:1000px;height:600px;background:white;position:absolute;"> <div class='bgColor' style='vertical-align:top;height:30px;margin:0px;width:100%;border-bottom:1px solid gray;padding:5px;font-family:Verdana;font-weight:bold;color:#043062;text-align:left'>🆕CLEARANCE INFORMATION: <div style='float:right;font-family:Verdana;font-size:15px;'> <a href='#' onclick="showApprovalWindow()" style='font-weight:bold'> ✕ </a> </div> </div> <div style="text-align:left;width:100%;font-size:18px;font-family:Arial;font-weight:bold;color:black;margin:10px;float:left;margin-left:20px;">CLEARANCE PROCESSING</div> <div style="background: #f0edec ;padding:10px;height:300px;text-align:left;width:46%;border:1px solid gray;font-size:12px;font-family:Arial;font-weight:normal;color:black;margin:10px;float:left;margin-left:20px;"> <input type="hidden" id="uempID" value="<?php echo $myEmpID;?>"> <div style="width:100%;margin:0px;float:left"> Employee ID No. <input type="text" readonly id="ViewEmpID" style="width:80%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Employee Name: <input type="text" readonly id="ViewEmpName" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Company Assignment: <input type="text" readonly id="ViewCompanyAssignment" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Position Title: <input type="text" readonly id="ViewPositionTitle" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Position Status: <input type="text" readonly id="ViewPositionStatus" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Unit Assignment: <input type="text" readonly id="ViewUnitAssignment" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> </div> <div style="background: #f0edec ;padding:10px;height:300px;text-align:left;width:46%;border:1px solid gray;font-size:12px;font-family:Arial;font-weight:normal;color:black;margin:10px;float:left;margin-left:20px;"> <div style="width:100%;margin:0px;float:left"> Reason for processing Clearance <input type="text" readonly id="ViewReason" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Comments/Notes: <input type="text" readonly id="ViewNotes" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> <div style="width:100%;margin:0px;float:left"> Movement From:<br> <input type="text" readonly id="ViewFrom" style="width:45%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px;margin-right:10px"> TO <input type="text" readonly id="ViewTo" style="width:45%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px;margin-left:10px"> </div> <div style="width:100%;margin:0px;float:left"> Inclusive Period / Effectivity Date: <input type="text" readonly id="viewInclusive" style="width:100%;padding:5px;margin-bottom:5px;border:1px solid gray;margin-top:0px"> </div> </div> <div style="text-align:left;height:150px;ext-align:left;width:95%;border:0px solid red;font-size:12px;font-family:Arial;font-weight:normal;color:black;margin:10px;float:left;margin-left:20px;"> <p style="background: #d2fdfd;width:100%;padding:5px;margin:0px;font-family:Arial;font-weight:bold">CLEARING OFFICER COMMENT / NOTE:</p> <textarea id="approvalComment" rows="4" style="background:#ffffff;width:100%;padding:10xp;border:1px solid black;"></textarea> <input type="submit" id="ApprovalClearance" value="Approve" style="padding:10px;width:150px;margin:10px;float:right"> <input type="submit" id="DisApprovalClearance" value="DisApprove" style="padding:10px;width:150px;margin:10px;float:right"> <div id="saveMessage" style="display:none;background:yellow;padding:10px;width:60%;margin:10px;float:right;text-align:center;font-family:Arial;font-size:16px;font-weight:bold"> Record has been updated successfuly... </div> </div> </div>
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings