예제 #1
0
 private function showEmpSelectionForm()
 {
     if (empty($this->empID)) {
         $this->empID = $_SESSION['userIDnum'];
     }
     $empq = getEmployeeInfo($this->config, $this->empID);
     $empInfo = getQueryResult($this->config, $empq, $debug = false);
     $emp = $empInfo->fetch_assoc();
     $this->empName = $emp['Name'];
     echo '<h3>Submission for Employee: <font color="yellow">' . $this->empName . '</font>';
     if ($this->config->adminLvl >= 25) {
         //echo ' Lookup Employee... work in progress<br/>';
         if (empty($this->subTypeID)) {
             echo ' <br/><br/><input type="submit" name="reqFormEmpSearch" value="Submit For Employee" />';
         }
         echo '<input type="hidden" name="empID" value="' . $this->empID . '" /><br/><br/>';
     }
     echo '</h3>';
 }
예제 #2
0
 public function showPrintFriendlyRequest()
 {
     if ($this->config->adminLvl >= 0) {
         //Valid user
         $this->refNo = isset($_GET['printRequestNo']) ? $_GET['printRequestNo'] : '';
         $this->refNo = isset($_POST['requestID']) ? $_POST['requestID'] : $this->refNo;
         if (!empty($this->refNo)) {
             echo '<div style="font-size:16px"> <h1><center>MAHONING COUNTY SHERIFF\'S OFFICE <br/>
                 EMPLOYEE REQUEST FORM<br/></center></h1>
                 <h2><center>Request reference #' . $this->refNo . '</center></h2>';
             $this->filters = getFilterByRefNo($this->config, $this->refNo);
             $this->currentQuery = getTimeRequestTable($this->config, $this->filters, $orderBy = '', $limit = ' LIMIT 1');
             $result = getQueryResult($this->config, $this->currentQuery, $this->debug);
             $req = $result->fetch_assoc();
             $mydivq = getEmployeeInfo($this->config, $req['Requester']);
             $myDivResult = getQueryResult($this->config, $mydivq, $debug = false);
             $empInfo = $myDivResult->fetch_assoc();
             if ($this->config->adminLvl >= 25 || $req['Requester'] == $_SESSION['userIDnum']) {
                 //Must be admin or viewing own requests
                 echo '<div align="right"> DATE FILED: ' . $req['Request_Date'] . '</div>';
                 echo '<h1>Employee Information</h1>';
                 echo 'EMPLOYEE: <div style="display: inline;font-size:24px">' . $req['Name'];
                 if (strcmp($req['Name'], $req['Audit_Name']) != 0) {
                     echo ' <font color="darkred">Submission By: ' . $req['Audit_Name'] . '</font>';
                 }
                 echo '</div><br/>';
                 echo 'Dvision: <div style="display: inline;font-size:20px">' . $empInfo['DESCR'] . '</div><br/>';
                 echo 'RANK: <div style="display: inline;font-size:20px">' . $empInfo['RANK'] . '</div><br/>';
                 echo '<br/><h2>Requested Information</h2>';
                 echo '<br/>';
                 echo 'TYPE OF REQUEST: <div style="display: inline;font-size:20px">' . $req['Type'] . '</div><br/>';
                 echo 'SUBTYPE: <div style="display: inline;font-size:20px">' . $req['Subtype'] . '</div><br/>';
                 echo 'DATE OF USE: <div style="display: inline;font-size:20px">' . $req['Used'] . '</div><br/>';
                 echo 'START TIME: <div style="display: inline;font-size:20px">' . $req['Start'] . '</div><br/>';
                 echo 'END TIME: <div style="display: inline;font-size:20px">' . $req['End'] . '</div><br/>';
                 echo 'CALCULATED HOURS: <div style="display: inline;font-size:20px">' . $req['Hrs'] . '</div><br/>';
                 echo 'EMPLOYEE NOTES: <div style="display: inline;font-size:20px">' . $req['Comment'] . '</div><br/><br/>';
                 if ($this->config->adminLvl >= 25) {
                     if (strcmp($req['Name'], $req['Audit_Name']) != 0) {
                         echo '<br/><h2>Employee Signature: _______________________________________  Date: _____________________</h2>';
                     } else {
                         $fname = capitolizeFirstLetterOnly($req['Emp_Fname']);
                         $lname = capitolizeFirstLetterOnly($req['Emp_Lname']);
                         echo '<h2>Employee Signature:                                
                             <div id="HaloSignature">' . '&nbsp;&nbsp;&nbsp;&nbsp;' . $fname . ' ' . $lname . '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</div>' . '  Date: <div id="HaloSignature">&nbsp;&nbsp;&nbsp;&nbsp;' . $req['Submit_Date'] . '&nbsp;&nbsp;&nbsp;&nbsp;</div></h2>';
                     }
                     echo '<div class="divider"></div>';
                 }
                 echo '<h1>O.I.C.</h1>';
                 echo 'REQUEST STATUS: <div style="display: inline;font-size:20px">' . $req['Status'] . '</div><br/>';
                 echo 'SUPERVISOR NOTES: <div style="display: inline;font-size:20px">' . $req['Reason'] . '</div><br/>';
                 echo 'SUPERVISOR FILED DATE: <div style="display: inline;font-size:20px">' . $req['approveTS'] . '</div><br/>';
                 echo 'SUPERVISOR: <div style="display: inline;font-size:20px">' . $req['ApprovedBy'] . '</div><br/><br/><br/>';
                 if ($this->config->adminLvl >= 25) {
                     echo '<h2>Supervisor Signature: _____________________________________  Date: _____________________</h2>';
                     echo '<br/><br/><h1>OFFICE USE ONLY</h1><br/><br/>';
                     echo '<h2>Office Signature: _________________________________________  Date: _____________________</h2>';
                     echo '</div>';
                 }
             } else {
                 echo 'You can only view your own requests';
             }
         } else {
             echo 'Error Getting Reference Number to Print!';
         }
     } else {
         echo 'You must login first';
     }
 }