| Server IP : 172.67.187.206 / Your IP : 172.71.28.156 Web Server : Apache/2.4.25 (Win32) OpenSSL/1.0.2j PHP/5.6.30 System : Windows NT WIN-ECQAAA40806 6.2 build 9200 (Windows Server 2012 Standard Edition) i586 User : SYSTEM ( 0) PHP Version : 5.6.30 Disable Function : NONE MySQL : ON | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /Inetpub/www/myoffice/2566/modules/car/ |
Upload File : |
<?
CheckUser($_SESSION['user_user'], $_SESSION['user_pwd']);
?>
<SCRIPT LANGUAGE='JAVASCRIPT' TYPE='TEXT/JAVASCRIPT'>
<!--
var win=null;
function NewWindow(mypage,myname,w,h,pos,infocus){
if(pos=="random"){myleft=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;mytop=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
if(pos=="center"){myleft=(screen.width)?(screen.width-w)/2:100;mytop=(screen.height)?(screen.height-h)/2:100;}
else if((pos!='center' && pos!="random") || pos==null){myleft=0;mytop=20}
settings="width=" + w + ",height=" + h + ",top=" + mytop + ",left=" + myleft + ",scrollbars=yes,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=no";win=window.open(mypage,myname,settings);
win.focus();}
// -->
</script>
<TABLE cellSpacing=0 cellPadding=0 width=100% height=500 border=0>
<TBODY>
<TR>
<TD vAlign=top> <b>บันทึกการขออนุญาตใช้รถยนต์ส่วนกลาง</>
<?
if($_GET[op] == "car_read"){
//////////////////////////////////////////// กรณีแก้ไข Form
if(CheckLevelUser($_SESSION['user_user'], $_GET[op])){
{
//ดึงค่า
// CheckUser($_SESSION['user_user']);
$db->connectdb(DB_NAME,DB_USERNAME,DB_PASSWORD);
$res[user] = $db->select_query("SELECT * FROM ".TB_user." WHERE username='".$_SESSION['user_user']."' ");
$arr[user] = $db->fetch($res[user]);
$db->connectdb(DB_NAME,DB_USERNAME,DB_PASSWORD);
$res[years] = $db->select_query("SELECT * FROM ".TB_YEARS_CAT." ORDER BY id ");
$arr[years] = $db->fetch($res[years]);
?>
<TABLE width="100%" align=center cellSpacing=1 cellPadding=1 border=0 >
<tr bgcolor="#336633" height=25>
<td width="5%" align=center ><font color="#FFFFFF"><B>ประเภท</B></font></td>
<td align=center width="25%"><font color="#FFFFFF"><B>เรื่อง</B></font></td>
<td width="20%" align=center ><font color="#FFFFFF"><B>ผู้ส่งเรื่อง</B></font></td>
<td width="20%" align=center ><font color="#FFFFFF"><B>ผู้ผ่านเรื่อง</B></font></td>
<td width="15%" align=center ><font color="#FFFFFF"><B>สถานะ</B></font></td>
<td width="5%" align=center ><font color="#FFFFFF"><B>ยกเลิก</B></font></td>
</tr>
<?
//แสดงข่าวสาร/ประชาสัมพันธ์
$db->connectdb(DB_NAME,DB_USERNAME,DB_PASSWORD);
$limit = 10 ;
$SUMPAGE = $db->num_rows(TB_CAR,"id","$SQLwhere cat='".$arr[user][id]."' and year='".$arr[years][name]."' ");
$page=$_GET[page];
if (empty($page)){
$page=1;
}
$rt = $SUMPAGE%$limit ;
$totalpage = ($rt!=0) ? floor($SUMPAGE/$limit)+1 : floor($SUMPAGE/$limit);
$goto = ($page-1)*$limit ;
$res[car] = $db->select_query("SELECT * FROM ".TB_CAR." WHERE cat='".$arr[user][id]."' and year='".$arr[years][name]."' ORDER BY id DESC LIMIT $goto, $limit ");
$count=0;
while($arr[car] = $db->fetch($res[car])){
?>
<tr bgcolor="#FFFFFF">
<td align="center" ><IMG SRC="myoffice/100.png"></td>
<td ><A HREF="javascript:NewWindow('popup2.php?name=car&file=readcar&id=<?echo $arr[car][id];?> ','acepopup','1024','720','center','front');"><?echo $arr[car][topic];?></A>
</td>
<td > <CENTER><? echo $arr[car][name];?><br><?echo ThaiTimeConvert($arr[car][post_date],'','2');?></CENTER></td>
<td align="center" >
<?=$arr[car][namecom];?><br>
<?
if($arr[car][update_date]){
?>
<?echo ThaiTimeConvert($arr[car][update_date],'','2');?>
<? } else {
echo "-";
}?>
</td>
<td align="center" >
<?
if($arr[car][comment1]==B){
?>
เสนอ ผอ.กลุ่ม
<?}?>
<?
if($arr[car][comment1]==A){
?>
รอเสนอแฟ้ม
<?}?>
<?
if($arr[car][comment1]==1){
?>
รอเสนอแฟ้ม
<?}?>
<?
if(($arr[car][comment1]==3)OR($arr[car][comment1]==4)){
?>
เจ้าหน้าที่
<?}?>
<?
if(($arr[car][comment1]==5)OR($arr[car][comment1]==6)){
?>
เสนอ ผอ.กลุ่ม
<?}?>
<?
if(($arr[car][comment1]==7)OR($arr[car][comment1]==8)){
?>
เสนอรองผู้บริหาร
<?}?>
<?
if(($arr[car][comment1]==9)OR($arr[car][comment1]==10)){
?>
เสนอผู้บริหาร
<?}?>
<?
if($arr[car][comment1]==ไม่อนุญาต){
?>
ไม่อนุญาต
<?}?>
<?
if(($arr[car][comment1]==11)OR($arr[car][comment1]==12)){
?>
ส่งคืน<BR>
<? echo $arr[car][reson];?>
<?}?>
<?
if($arr[car][comment1]==อนุญาต){
?>
อนุญาต
<?
if(($arr[car][comment1]==อนุญาต)AND($arr[user][car]==13)){
?>
<BR>
<A HREF="popup.php?name=car&file=addevent&id=<? echo $arr[car][id]; ?>" onclick="return hs.htmlExpand(this, { contentId: 'highslide-html', objectType: 'iframe', objectWidth: 800, objectHeight: 600} )" class="highslide"><font color=blue><b><u><font color=red>บันทึกปฏิทินการใช้รถ</u><b></font></A>
<?}?>
<?}?>
</td>
<td align=center >
<?
if(($arr[car][comment1]!=อนุญาต)AND($arr[car][cat]==$arr[user][id])){
?>
<?
if($_SESSION['user_user']){
?>
<a href="javascript:Confirm('?name=car&file=index2&op=car_del&id=<? echo $arr[car][id];?>&prefix=<? echo $arr[car][post_date];?>','กรณีไม่อนุญาตลบวันลาออกไป');"><IMG SRC="images/delete.gif"></a>
<?
}
?>
<?}?>
<?
if($arr[car][category]==o){
?>
<IMG SRC="images/tick.png">
<?}?>
</TR>
<?
$count++;
if (($count%1) == 0) { echo ""; $count=0; }
}
$db->closedb ();
//จบการแสดงข่าวสาร
?>
<!-- End tkk3 -->
</table>
</form>
</TR>
</TD>
</TABLE>
<BR>
<table border="0" cellpadding="0" cellspacing="1" width="100%" align=center>
<tr>
<td>
<?
SplitPage($page,$totalpage,"?name=car&file=indexsent&op=car_read&category=".$_GET[category]."");
echo $ShowSumPages ;
echo $ShowPages ;
// CheckUser($_SESSION['user_user']);
$db->connectdb(DB_NAME,DB_USERNAME,DB_PASSWORD);
$res[user] = $db->select_query("SELECT * FROM ".TB_user." WHERE username='".$_SESSION['user_user']."' ");
$arr[user] = $db->fetch($res[user]);
?>
<?
}
?>
<?
}else{
//กรณีไม่ผ่าน
$ProcessOutput = $PermissionFalse ;
}
echo $ProcessOutput ;
}
?>
</TD>
</TR>
</TABLE>
</TD>
</TR>
</TBODY>
</TABLE>