Hacked By AnonymousFox

Current Path : C:/AppServ/www/stat/
Upload File :
Current File : C:/AppServ/www/stat/homeuser.php

<? 
include("lib/config.php");
include("lib/connect.php");
include("lib/session.php");

if($System_Session_Level=="") {
echo "<SCRIPT LANGUAGE=\"JavaScript\">window.location = \"index.php\";alert(\"You must Login first.\");</SCRIPT>";
 } 

$sql="select * from ncis_staff where StaffID='$System_Session_User_ID'";
$query=mysql_query($sql);
$row=mysql_fetch_array($query);

function ShowDateLongTh($myDate) {
		$myDateArray=explode("-",$myDate);
		$myDay = sprintf("%d",$myDateArray[2]);
		switch($myDateArray[1]) {
			case "01" : $myMonth = "มกราคม";  break;
			case "02" : $myMonth = "กุมภาพันธ์";  break;
			case "03" : $myMonth = "มีนาคม"; break;
			case "04" : $myMonth = "เมษายน"; break;
			case "05" : $myMonth = "พฤษภาคม";   break;
			case "06" : $myMonth = "มิถุนายน";  break;
			case "07" : $myMonth = "กรกฎาคม";   break;
			case "08" : $myMonth = "สิงหาคม";  break;
			case "09" : $myMonth = "กันยายน";  break;
			case "10" : $myMonth = "ตุลาคม";  break;
			case "11" : $myMonth = "พฤศจิกายน";   break;
			case "12" : $myMonth = "ธันวาคม";  break;
		}
		$myYear = sprintf("%d",$myDateArray[0])+543;
        return($myDay . " " . $myMonth . " " . $myYear);
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
	<title>:: ระบบ NCIS ::</title>
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width, initial-scale=1">
<!--===============================================================================================-->	
	<link rel="icon" type="image/png" href="images/icons/list.ico"/>
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="vendor/bootstrap/css/bootstrap.min.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="fonts/font-awesome-4.7.0/css/font-awesome.min.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="fonts/Linearicons-Free-v1.0.0/icon-font.min.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="vendor/animate/animate.css">
<!--===============================================================================================-->	
	<link rel="stylesheet" type="text/css" href="vendor/css-hamburgers/hamburgers.min.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="vendor/animsition/css/animsition.min.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="vendor/select2/select2.min.css">
<!--===============================================================================================-->	
	<link rel="stylesheet" type="text/css" href="vendor/daterangepicker/daterangepicker.css">
<!--===============================================================================================-->
	<link rel="stylesheet" type="text/css" href="css/splash.css">
    	<link rel="stylesheet" type="text/css" href="css/util.css">

<!--===============================================================================================-->
<style type="text/css">

.inputlogin{

background:#056839;

font-family:Tahoma, Geneva, sans-serif;

font-size:16px;  

padding: 5px 10px 5px 10px;

color: #fff;

font-weight: bold;

-moz-border-radius: 6px;

-webkit-border-radius: 6px;

-moz-box-shadow: 0 1px 3px rgba(0,0,0,0.5);

-webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.5);

text-shadow: 0 -1px 1px rgba(0,0,0,0.25);

border-bottom: 1px solid rgba(0,0,0,0.25);

cursor: pointer;

border-left:none;

border-top:none;

margin:10px 0 10px 0;

}

.inputlogin:hover{

background:#727FB2;

}
</style>
         <link rel="stylesheet" href="dist/css/default/zebra_datepicker.min.css" type="text/css">
        <link rel="stylesheet" href="examples.css" type="text/css">
</head>
<body>
<div class="pages_container">
                                       <div align="center"><img src="logo_sm.png" width="160" /><br>
                                         <strong>&nbsp;ระบบสารสนเทศสิ่งที่ไม่เป็นไปตามข้อกำหนดมาตรฐาน<br>
Non conformity information system (NCIS)</strong></div>
                                       <br />
 <h4 align="right"><span class="page_title">ยินดีต้อนรับ ! 
                                            คุณ<?=$System_Session_FullName?> เข้าสู่ระบบ 
                                            <input type="submit" name="button2" id="button2" class="inputlogin" value="แก้ไขรหัสผ่าน"  onclick="window.location='system/logout.php'" />&nbsp;&nbsp;
  <input type="submit" name="button" id="button" class="inputlogin" value="ออกจากระบบ"  onclick="window.location='system/logout.php'" /></span></h4>
  <br />
  <p>&nbsp;</p>
 <table width="100%" border="0" align="center" cellpadding="10">
   <tr>
     <td width="25%"><strong>ประวัติ NC ที่ได้รับ</strong></td>
     <td width="25%">&nbsp;</td>
     <td width="25%">&nbsp;</td>
   </tr>
   <tr>
     <td colspan="3"><strong>สถานะ</strong> <strong><img src="yellow-status.png" width="30" height="30"> หมายถึง ยังไม่เลยเวลาและยังไม่เสร็จ <img src="green-status.png" width="30"> หมายถึง เสร็จแล้ว <img src="red-status.png" width="30" height="30"> หมายถึง เลยเวลาแล้วและยังไม่ได้ปิด</strong></td>
     </tr>
   <tr>
     <td colspan="3"><table width="100%"  border="1" bordercolor="#CCCC99" style="border-collapse:collapse" cellpadding="10">
       <tr>
         <td width="7%" bgcolor="#CCFFCC"><div align="center"><strong>รหัส NC        
         </strong></div></td>
         <td width="12%" bgcolor="#CCFFCC"><div align="center"><strong>Assessment</strong></div></td>
         <td width="10%" bgcolor="#CCFFCC"><div align="center"><strong>วันที่ตรวจพบ</strong></div></td>
         <td width="5%" bgcolor="#CCFFCC"><div align="center"><strong>NC TYPE </strong></div></td>
         <td width="13%" bgcolor="#CCFFCC"><div align="center"><strong>หน่วยงานที่ถูกตรวจ</strong></div></td>
         <td width="18%" colspan="2" bgcolor="#CCFFCC"><div align="center"><strong>สถานะ</strong></div></td>
         <td width="13%" bgcolor="#CCFFCC"><div align="center"><strong>จัดการ NC</strong></div></td>
       </tr>
	   <?
	   $sql="select * from ncis_auditor where Instituteid='1' and sectionname='กลุ่ม/งาน/ห้องปฏิบัติการเคมี'";
	   $query=mysql_query($sql);
	  while($row=mysql_fetch_array($query)){
	   ?>
       <tr>
         <td bgcolor="#FFFFFF"><div align="center"><?=$row[Ncnumber]?></div></td>
         <td bgcolor="#FFFFFF"><div align="center">
           <?=$row[Assessment]?>
         </div></td>
         <td bgcolor="#FFFFFF"><div align="center">
           <? 
		 $datefind=substr($row[Datefind],0,2);
		 $monthfind=substr($row[Datefind],3,2); 
		 $yearfind=substr($row[Datefind],6,4)-543; 
		 $conc="-";
		 $dayfind=$yearfind.$conc.$monthfind.$conc.$datefind;
		 ?>
           
           <?=ShowDateLongTh($dayfind)?></div></td>
         <td bgcolor="#FFFFFF"><div align="center"><? if($row[Nctype]=="Observation"){ echo"Obs"; } 
		 if($row[Nctype]=="NC"){ echo"Nc"; } if($row[Nctype]=="Car"){ echo"C"; } ?></div></td>
         <td bgcolor="#FFFFFF"><div align="center"><?=$row[Deptname]?></div></td>
         <td bgcolor="#FFFFFF" width="5%"><div align="center">
           <? if($row[Status]=="0"){ ?>
           <img src="yellow-status.png" width="30" height="30">
           <?   } ?>
           <? if($row[Status]=="1"){ ?>
           <img src="green-status.png" width="30" height="30">
           <?   } ?>
           <? if($row[Status]=="2"){ ?>
           <img src="red-status.png" width="30" height="30">
           <?   } ?>
         </div></td>
         <td bgcolor="#FFFFFF" align="center" width="13%">
         <? 
if($row[Statusdoc]=="0"){ echo"อยู่ระหว่าง QM บันทึกข้อมูล"; }
if($row[Statusdoc]=="1"){ echo"อยู่ระหว่างเสนอ ผอ."; }
if($row[Statusdoc]=="2"){ echo"ผอ.อนุมัติ และเสนอหัวหน้าห้องปฏิบัติการ"; }
if($row[Statusdoc]=="3"){ echo"อยู่ระหว่างเสนอผู้แก้ไข"; }
if($row[Statusdoc]=="4"){ echo"อยู่ระหว่างหัวหน้าเห็นชอบข้อมูลจากผู้แก้ไข"; }
if($row[Statusdoc]=="5"){ echo"อยู่ระหว่าง QM บันทึกข้อมูลจากหัวหน้า"; }
if($row[Statusdoc]=="6"){ echo"อยู่ระหว่างเสนอ ผอ.ก่อนเสนอ Auditor"; }
if($row[Statusdoc]=="7"){ echo"อยู่ระหว่าง Auditor สรุปข้อมูล"; }
?>
</td>
         <td bgcolor="#FFFFFF">
           <div align="center">
             <input type="submit" name="button22222" id="button22222" class="inputlogin" value="ดูรายละเอียด"  onclick="window.location='savencresponse.php?Id=<?=$row[Id]?>'" />
             <br>
             <br>
           </div></td>
       </tr>
	   <? } ?>
     </table></td>
    </tr>
 </table>
 <p><br>
   </p>
</div>

</body>
</html>

Hacked By AnonymousFox1.0, Coded By AnonymousFox