Viewing file: FrmEditFormRoom.php (17 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
session_start();
/** Define Validate Access */
define( '_VALID_ACCESS', 1 );
/** Check Session User Login */
if( !session_is_registered("valid_user") && !session_is_registered("Priority") ) {
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=windows-874\" />";
echo "<p style=padding-top:115px><p align=center><br /><font color=red><strong>กรุณาทำการ Login ก่อน</strong></font></p></p>";
echo "<meta http-equiv=\"refresh\" content=\"1; URL=../login.php\" />";
exit();
}
else {
/** Configuration */
require_once( "../configuration.php" );
require_once( $_Config_absolute_path . "/includes/framework.php" );
require_once( "../include/Function.php" );
require_once( "../include/FunctionDB.php" );
require_once( "../calendar/check.php" );
require_once( "../calendar/cal_func.php" );
/** Create Database Object */
$dbObj = new DBConn;
//=== SESSION
$Username = $valid_user;
/** Config Table for This Page */
$myTable1 = "personal_tb";
$myTable2 = "room_rent";
/** Table --> personal_tb */
$query = " SELECT *, prefixName as First_name FROM prefix LEFT JOIN personal_tb ON personal_tb.First_name = prefix.prefixId LEFT JOIN faculty_tb ON faculty_tb.Faculty_code=personal_tb.Faculty_code WHERE Teacher_code='$Teacher_code' ";
$result = $dbObj->execQuery($query);
$rss = $dbObj->fetchArray($result);
//$Teacher_code = $rss['Teacher_code'];
/** Table --> tech_plan_tb */
$query1 = " SELECT * FROM $myTable2 WHERE Rent_code='$Rent_code' ";
$result1 = $dbObj->execQuery($query1);
$rs1 = $dbObj->fetchArray($result1);
} # else
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<link href="../css/default.css" rel="stylesheet" type="text/css" />
<link href="../css/calendar.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="../js/utilities.js"></script>
<script type="text/javascript" src="../js/calendarDateInput2.js"></script>
<title>MIS-การขอใช้ห้องประชุม</title>
</head>
<body topmargin="0" rightmargin="0" bottommargin="0" leftmargin="0">
<?php
include("../templates/incHeader.php");
?>
<table width="1003" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="203" align="left" valign="top" style="padding:10px 0px 0px 5px"><?php include("./_incMainMenu.php");?></td>
<td width="800" height="440" align="center" valign="top" style="padding:10px 0px 5px 10px; color: #000;"><fieldset>
<form id="form1" name="form1" method="post" action="EditFromRoom.php" >
<table width="765" border="0" cellspacing="0" cellpadding="0">
<tr>
</tr>
<tr>
<td height="30" background="../images/background/bg-head-topic-w780.gif" class="PADDING-LEFT-10"><strong><a href="index.php">หน้าหลัก</a></strong> <strong>» <a href="Menu_Form.php?Teacher_code=<?=$Teacher_code ;?>">แบบฟอร์ราชการ</a> » <span class="NOTE">ใบขออนญาตใช้ห้องประชุม</span></strong></td>
</tr>
<tr>
<td><span class="PADDING-TOP-10"><img src="../images/icons/arrow-circle-225-left.png" width="16" height="16" border="0" align="absmiddle" /> <a href="javascript:;" onclick="window.history.back();"><strong>‹ ย้อนกลับ</strong></a></span></td>
</tr>
<tr>
<td><table width="760" align="center" cellpadding="0" cellspacing="0">
<tr height="31">
<td height="17" colspan="6" align="center" class="PATRON11"><hr /></td>
</tr>
<tr height="31">
<td height="27" colspan="6" align="center" class="PATRON11">ใบขออนุญาตใช้ห้องประชุม</td>
</tr>
<tr>
<td height="15" colspan="6" align="center" class="PATRON11"> </td>
</tr>
<tr height="29">
<td height="18" colspan="6">
<?php
$collegeCode = $rss["collegeCode"];
$sql = "Select * From college Where collegeStatus ='1'";
$result1 = mysql_query($sql) or die("Error".mysql_error());
$rs2 = mysql_fetch_array($result1);
?>
<input name="Teacher_code" type="hidden" id="Teacher_code" value="<? echo $rss["Teacher_code"]?>" />
</td>
</tr>
<tr height="29">
<td height="24" colspan="4" align="left"> </td>
<td height="24" align="right">
<script>DateInput('mDate', true,'DD/MM/YYYY','<?=(isset($rs1["Rent_date"]))?ymdE2dmyE2($rs1["Rent_date"]):date("d/m/Y");?>');</script>
</td>
</tr>
<tr height="29">
<td height="24" colspan="5" align="left">ส่วนราชการ ภาค/ฝ่าย
<input name="Name4" type="text" id="Name4" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="30" value="<?= $rss['Faculty_name'];?> " readonly/>
<?=$rs2["collegeName"];?> </td>
</tr>
<tr height="29">
<td height="29" colspan="3" align="left">เรื่อง </a>
<input name="Da" type="text" id="Da" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" value="ขอใช้ห้องประชุม" size="20" /> </font></td>
<td width="3"></td>
<td width="317"></td>
<td width="1"></td>
</tr>
<tr height="29">
<td height="29" colspan="5" align="left">เรียน ผู้อำนวยการ <font size="2" face="Tahoma">
<?php
$collegeCode = $rss["collegeCode"];
$sql = "Select * From college Where collegeStatus ='1'";
$result1 = mysql_query($sql) or die("Error".mysql_error());
$rs2 = mysql_fetch_array($result1);
echo "$rs2[collegeName] ";
?>
</font></td>
<td></td>
</tr>
<tr height="29">
<td width="58" height="25"></td>
<td colspan="5" align="left">ด้วย ภาค/ฝ่าย/หน่วย/ศูนย์</a>
<input name="Name" type="text" id="Name" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="70" value="<?= $rss['Faculty_name'];?>" readonly/>
มีความประสงค์จะขอใช้</td>
</tr>
<tr height="29">
<td height="36" colspan="6" align="left">
<table width="753">
<tr>
<td width="115">ห้องประชุมระหว่าง</td>
<td width="134">
<script>DateInput('mDate2', true,'DD/MM/YYYY','<?=(isset($rs1["Date_start"]))?ymdE2dmyE2($rs1["Date_start"]):date("d/m/Y");?>');</script>
</td>
<td width="140">
เวลา
<input name="hr" type="text" id="hr" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="3" maxlength="2" onkeypress="return checkNumeric();" value=<?= substr($rs1["Time_start"],0,2); ?> />.
<input name="mn" type="text" id="mn" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="3" maxlength="2" onkeypress="return checkNumeric();" value=<?= substr($rs1["Time_start"],-2); ?> /></td>
<td width="44">ถึงวันที่</td>
<td width="143">
<script>DateInput('mDate3', true,'DD/MM/YYYY','<?=(isset($rs1["Date_finish"]))?ymdE2dmyE2($rs1["Date_finish"]):date("d/m/Y");?>');</script>
</td>
<td width="151">
เวลา
<input name="hr1" type="text" id="hr1" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="3" maxlength="2" onkeypress="return checkNumeric();" value=<?= substr($rs1["Time_finish"],0,2); ?> />.
<input name="mn1" type="text" id="mn1" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="3" maxlength="2" onkeypress="return checkNumeric();" value=<?= substr($rs1["Time_finish"],-2); ?> /></td>
</tr>
</table>
</td>
</tr>
<tr height="29">
<td height="29" colspan="6" align="left">เพื่อจัดประชุม/อบรม/สัมนา เรื่อง<a>
<input name="Topic" type="text" id="Topic" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="96" value="<?=$rs1['Topic'];?>" />
</a>
</td>
</tr>
<tr height="29">
<td height="29" colspan="6" align="left">จำนวน
<input name="Make" type="text" id="Make" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" onkeypress="return checkNumeric();" size="20" maxlength="4" value="<?=$rs1['Make'];?>"/>
คน โดยมีรายละเอียดในการขอใช้ห้องประชุม ดังนี้</td>
</tr>
<tr height="29">
<td height="29" align="left"> </td>
<td height="29" align="center">เลือกห้องประชุม</td>
<td height="29" align="left" colspan="4">
<select name="Room_code" id="Room_code" />
<option value=" "> </option>
<?php
$strSQL = " SELECT * FROM room_tb Where roomtyId ='1' ";
$result4 = mysql_query($strSQL);
while( $rs4 = mysql_fetch_array($result4) ) {
?>
<option value="<?=$rs4['Room_code'];?>" <?php if( $rs4['Room_code']==$rs1['Room_code'] ) echo 'selected'; ?>>
<?=$rs4['Room_code']." ".$rs4['Room_name'];?>
</option>
<?php
} # while
?>
</select>
</td>
</tr>
<tr height="29">
<td height="29" align="left"> </td>
<td height="29" align="left">
<input type="checkbox" name="Check_format" value="1" <? if ($rs1["Check_format"] == 1) echo "checked"; ?> />
จัดรูปแบบห้องประชุม
</td>
<td height="29" align="left" colspan="4">
<input name="Detail_format" type="text" id="Detail_format" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="90" value="<?=$rs1['Detail_format'];?>"/>
</td>
</tr>
<tr height="29">
<td height="29" align="left"> </td>
<td height="29" align="left">
<input type="checkbox" name="Check_tool" value="2" <? if ($rs1["Check_tool"] == 2) echo "checked"; ?>/>
อุปกรณ์โสตทัศนูปกรณ์
</td>
<td height="29" align="left" colspan="4">
<input name="Detail_tool" type="text" id="Detail_tool" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="90" value="<?=$rs1['Detail_tool'];?>"/>
</td>
</tr>
<tr height="29">
<td height="29" align="left"> </td>
<td height="29" align="left">
<input type="checkbox" name="Check_food" value="3" <? if ($rs1["Check_food"] == 3) echo "checked"; ?> />
อาหารว่างและเครื่องดื่ม
</td>
<td height="29" align="left" colspan="4">
<input name="Detail_food" type="text" id="Detail_food" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="90" value="<?=$rs1['Detail_food'];?>"/>
</td>
</tr>
<tr height="29">
<td height="29" colspan="6" align="left"> จึงเรียนมาเพื่อโปรดอนุญาตและดำเนินการต่อไปด้วย จะเป็นพระคุณ</td>
</tr>
<tr height="29">
<td height="49" colspan="6" align="left"><p> </p></td>
</tr>
<tr height="31">
<td height="23" colspan="3" align="left"></td>
<td> </td>
<td align="center">ลงชื่อ................................................</td>
<td></td>
</tr>
<tr height="29">
<td height="29" colspan="3"> </td>
<td></td>
<td align="center">( <? echo $rss[First_name]?> <? echo $rss[Teacher_name]?> <? echo $rss[Teacher_lastname]?> )
<input name="Teacher_code" type="hidden" id="Teacher_code" value="<? echo $rss[Teacher_code];?>" /></td>
<td></td>
</tr>
<tr height="31">
<td height="31"> </td>
<td> </td>
<td> </td>
<td colspan="3" align="center">ตำแหน่ง<font color="#0000FF" size="2" face="Tahoma">
<input name="Name3" type="text" id="Name3" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="20" value="<? //$PositionId = $rss["PositionId"];
$sql = "Select * From position_tb Where PositionId ='$rss[PositionId]' ";
$result1 = mysql_query($sql) or die("Error".mysql_error());
$rs2 = mysql_fetch_array($result1);
echo "$rs2[Position_name] ";?>
" />
</font></td>
</tr>
<tr height="31">
<td height="31"> </td>
<td> </td>
<td> </td>
<td colspan="3" align="center"> </td>
</tr>
<tr height="31">
<td height="31"> </td>
<td width="158"> </td>
<td width="230"> </td>
<td colspan="3" align="center"><span class="style13">ความเห็นหัวหน้าหน่วยงาน</span></td>
</tr>
<tr height="29">
<td height="16" colspan="2" align="center"> </td>
<td></td>
<td colspan="3" align="left"> </td>
</tr>
<tr height="29">
<td height="29"></td>
<td></td>
<td colspan="2"></td>
<td colspan="2" align="left"> <label>
<input type="radio" name="radio" value="Y" />
</label>
อนุญาต
<input type="radio" name="radio" value="N" />
ไม่อนุญาต<br/><br/>
เนื่องจาก
<input name="Detail" type="text" id="Detail" style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: black 1px dashed" size="40" /> </td>
</tr>
<tr height="31">
<td height="23" colspan="3" align="left"></td>
<td> </td>
<td align="center"> </td>
<td></td>
</tr>
<tr height="31">
<td height="23" colspan="3" align="left"></td>
<td> </td>
<td align="center">ลงชื่อ...................................................</td>
<td></td>
</tr>
<tr height="29">
<td height="29" colspan="3"> </td>
<td></td>
<td align="center">( .................................................. ) </td>
<td></td>
</tr>
<tr height="31">
<td height="31"> </td>
<td> </td>
<td> </td>
<td colspan="3" align="center">ตำแหน่ง ......................................................</td>
</tr>
<tr height="31">
<td height="10" colspan="6" align="center"><hr /></td>
</tr>
<tr height="31">
<td height="24" colspan="6" align="center"><input type="submit" name="Submit" value="บันทึก" class="WIDTH60 CURSOR-HAND" />
<input name="Rent_code" type="hidden" id="Rent_code" value="<? echo $rs1["Rent_code"]?>" />
<input type="reset" name="Reset" value="รีเซ็ต" class="WIDTH60 CURSOR-HAND" />
<input type="button" name="Button" value="ยกเลิก" class="WIDTH60 CURSOR-HAND" onclick="location.href=FormCarList.php?Teacher_code=<?=$Teacher_code;?>'" /></td>
</tr>
</table></td>
</tr>
<tr>
<td><span class="NOTE">หมายเหตุ : รูปแบบการใส่เวลา เช่น 18.30 , 07.30 เป็นต้น</span></td>
</tr>
</table>
</form>
</fieldset></td>
</tr>
</table>
<?php include("../templates/incFooter.php"); ?>
</body>
</html>
<?php
/** Free Resource */
$dbObj->freeresult($result);
/** Close the Database */
$dbObj->disconn();
/** Unset Class */
unset($dbObj);
?>
|