File manager - Edit - /home/autoph/public_html/connect/home/PRF/PRF_SETUP_PO_Approver.php
Back
<?php include 'core/init.php'; protected_page(); $uniqueRefID = $user_data['u_id']; //echo $uniqueRefID; $prfDate = date_create() ->format("Y-m-d"); $prtTime =Explode(":", date('H:i:s')); $txDate = explode("-",$prfDate); $refYear = $txDate[0]; $refMonth = $txDate[1]; $refMinute = $prtTime[1]; $refSecond = $prtTime[2]; $NewRefCode = $refMonth.''.$refMinute.''.$refSecond; ?> <!DOCTYPE html> <html lang="en"> <head> <link rel="stylesheet" type="text/css" href="css/bootstrap.css"/> <link rel="stylesheet" type="text/css" href="css/jquery-ui.css"/> <meta charset="UTF-8" name="viewport" content="width=device-width, initial-scale=1"/> </head> <body> <div class='NewPRFHeader'> <p class='PRFBodyTitle'>📝 SETUP P.O APPROVING OFFICERS</p> </div> <input type='hidden' id='SelExecomID'> <!--########################## MAIN TABLE WINDOW ############################################--> <!--########################################################################################################--> <div class='NewPRFBody'> <div id='mainTable' class='PRFTableBody'> <div style='width:60%;height:33px;background:white'> <table> <thead> <th style='width:10%'>REC. ID</th> <th style='width:50%'>NAME</th> <th style='width:30%'>AUTHORITY</th> <th style='width:10%'>ACTION</th> </thead> </table> </div> <div id='execomList' class='PRFTableItems' style='width:60%;height:250px;border:1px solid gray;overflow:auto'> <?php echo "<table id='deleteEXECOM'>"; $getExecomList = mysql_query("SELECT vts_users.u_id,vts_users.u_fname,vts_users.u_lname,prf_poapprover.id,prf_poapprover.po_officer_id,prf_poapprover.authority,prf_poapprover.comp_id FROM `vts_users` JOIN `prf_poapprover` ON `prf_poapprover`.po_officer_id = vts_users.u_id WHERE `vts_users`.u_id=`prf_poapprover`.po_officer_id AND `prf_poapprover`.deleted=0"); while($row=mysql_fetch_array($getExecomList)){ ?> <tr onclick="javascript:getExecomID(this);"><!-- getCategoryIDonDblclick="javascript:showActionViewDelete(this);" >--> <?php echo "<td style='width:10%'>".$row['id']."</td> <td style='width:50%'>".$row['u_lname'].", ".$row['u_fname']."</td> <td style='width:30%'>".$row['authority']."</td> <td style='width:10%;text-align:center'>❌</td>"; echo "</tr>"; } echo "</table>"; ?> </div> <div id='execomListx' class='PRFTableItems' style='width:60%;height:240px;'> <p style='font-family:Yu Gothic;font-size:14px;color:black;margin-bottom:2px;padding-bottom:2px'>SELECT EMPLOYEE:</p> <div style='float:left;width:60%;margin:0px;background:white;padding:2px'> Employee Name:<br> <select id='getExecom' style='margin:0px;padding:0px;height:30px;' > <option value='0'>-- Select -- </option> <?php $getExecomMember = mysql_query("SELECT vts_users.u_id,vts_users.u_fname,vts_users.u_lname,vts_users.company FROM vts_users WHERE u_status=1"); while($uRow=mysql_fetch_array($getExecomMember)){ echo "<option value='".$uRow['u_id']."'>".strtoupper($uRow['u_lname']).", ".strtoupper($uRow['u_fname'])."</option>"; } ?> </select> </div> <div style='float:left;width:20%;margin:0px;background:white;padding:2px'> Level of Authority: <input type='number' value='1' min='1' max='3' id='getAuthority' style='margin:0px;height:30px;text-align:center'> </div> <div style='float:left;width:20%;margin:0px;background:white;padding:2px'> <br> <button id='addApprover' style='margin:0px;width:100%;height:30px;'>Add Approver</button> </div> <div style='float:left;width:90%;margin:2px;padding:10px;background:white;border:0px solid gray;color:gray'> <u style='font-family:Yu Gothic;font-weight:bold;color:Black'>LEVEL OF AUTHORITY:</u> <br><br> 1 = Can approve PO without the need of other approving officers<br> <br> 2 = Two (2) Offices are required to approved PO<br> <br> 3 = Three (3) Officers are required to approved PO<br> </div> </div> </div> </div> <!--########################## END OF EDIT/UPDATING PURCHASE REQEUST ############################################--> </body> </html> <!--- LOCALIZED COPY OF JAVASCRIPT --> <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.js"></script> <script type="text/javascript"> $(document).ready(function(){ //====================================================================================================== $("#deleteEXECOM").click(function(){ //getAuthority getExecom addExecom var SelExecomID = $("#SelExecomID").val(); //alert(SelExecomID); //exit; if(confirm("CONFIRM DELETE ACTION: \n\nAre you sure you want to DELETE this record? \n\n Press 'OK' button to proceed...")){ ShowUploadBar(); $.ajax({ url: "PRF_DeletePOApprover.php", type: "POST", async: false, data: { "SelExecomID": SelExecomID, "done": 1 }, success: function(d){ ShowUploadBar(); $("#execomList").html(d); hideActionViewDelete(); //$('#searchText').val(''); 015334295-1005 } }) } }); $("#addApprover").click(function(){ // getExecom var getAuthority = $("#getAuthority").val(); var getExecom = $("#getExecom").val(); //alert(getAuthority); //exit; //if(confirm("CONFIRM DELETE ACTION: \n\nAre you sure you want to ADD ? \n\n Press 'OK' button to proceed...")){ ShowUploadBar(); $.ajax({ url: "PRF_AddPOApprover.php", type: "POST", async: false, data: { "getAuthority": getAuthority, "getExecom": getExecom, "done": 1 }, success: function(d){ ShowUploadBar(); $("#execomList").html(d); hideActionViewDelete(); //$('#searchText').val(''); 015334295-1005 } }) //} }); //====================================================================================================== function updateCREATENEWPRF(){ $.ajax({ url: "PRF_Update_CREATE_NEW_PRF.php", type: "POST", async: false, data: { "trans":1 }, success: function(d){ updatePostedPRF(); $("#unPostedPRFRequestCount").html(d); } }) } //====================================================================================================== function updatePostedPRF(){ $.ajax({ url: "PRF_Update_POSTEDPRF.php", type: "POST", async: false, data: { "trans":2 }, success: function(d){ $("#PostedPRFRequestCount").html(d); } }) } //====================================================================================================== function updateApprovalPRF(){ $.ajax({ url: "PRF_procIncomingInfo.php", type: "POST", async: false, data: { "trans":2 }, success: function(d){ $("#forMyApprovalCount").html(d); } }) } //====================================================================================================== function refreshMainTable(){ $.ajax({ url: "PRF_MainTableHeaderDisplay.php", type: "POST", async: false, data: { }, success: function(d){ //invShowAssignMsg(); $("#mainTable").html(d); //invHideAssignMsg(); //$('#searchText').val(''); } }) } }); </script> <!--- LOCALIZED COPY OF JAVASCRIPT --> <script type="text/javascript"> function getExecomID(row) { var x=row.cells; document.getElementById("SelExecomID").value = x[0].innerHTML; } </script>
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings