Viewing file: showRegisDoc.php (52.27 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
include_once "template.php";
include_once "../class/clsTable.php";
include_once "../class/clsDepartment.php";
include_once "../class/clsPerson.php";
include_once "../link/function.php";
include_once "../link/functionshow.php";
include_once "../class/clsDocLinePosition.php";
include_once "../class/clsDocLineConfig.php";
include_once "../class/clsReceiveSendType.php";
include_once "../class/clsDocType.php";
include_once "../class/clsDocSpeedLevel.php";
include_once "../class/clsDocSecreLevel.php";
include_once "../class/clsDocattatchesTmp.php";
include_once "../class/clsDocuments.php";
include_once "../class/clsDocattatches.php";
include_once "../class/clsDocReceiveSend.php";
include_once "../class/clsProposeType.php";
include_once "funct.php";
include_once "../class/clsannounceDocType.php";
include_once "../link/keyThai.php";
include_once "../class/clsDocWSign.php";
include_once "../class/clsDocCommentPropose.php";
include_once "getPrefix.php";
include_once "../class/clsNoticeEditDoc.php";
include_once "../class/clsDocInboxStaff.php";
$oC = new clsConnection($GLOBALS['DBHOST'], $GLOBALS['DBNAME_EOFFICE'], $GLOBALS['DBUSER_EOFFICE'], $GLOBALS['DBPASS_EOFFICE']);
$oDP = new Department($oC);
$oDP2 = new Department($oC);
$oDP3 = new Department($oC);
$oDP4 = new Department($oC);
$oDP5 = new Department($oC);
$oPS = new person($oC);
$oPS1 = new person($oC);
$oPS2 = new person($oC);
$oPS3 = new person($oC);
$oDlc = new DocLineConfig($oC);
$oDlc2 = new DocLineConfig($oC);
$oDlc3 = new DocLineConfig($oC);
$oDlc4 = new DocLineConfig($oC);
$oDlc5 = new DocLineConfig($oC);
$oDlc6 = new DocLineConfig($oC);
$oDlc7 = new DocLineConfig($oC);
$oDlp = new docLinePosition($oC);
$oDlp1 = new docLinePosition($oC);
$oRSt = new receiveSendType($oC);
$oDt = new doctype($oC);
$oDsl = new DocSpeedLevel($oC);
$oDcl = new DocSecretLevel($oC);
$oDtmp = new DocattatchesTmp($oC);
$oDoc = new Documents($oC);
$oDoc2 = new Documents($oC);
$oDoc3=new Documents($oC);
$oDatt = new Docattatches($oC);
$oRs = new DocReceiveSend($oC);
$oRs2 = new DocReceiveSend($oC);
$oRs3 = new DocReceiveSend($oC);
$oRs4 = new DocReceiveSend($oC);
$oRs5 = new DocReceiveSend($oC);
$oRs6 = new DocReceiveSend($oC);
$oRs7 = new DocReceiveSend($oC);
$oRs8 = new DocReceiveSend($oC);
$oRs9 = new DocReceiveSend($oC);
$oPt = new ProposeType($oC);
$oAn=new announceDocType($oC);
$MaxDocGroup=$oDP->SearchMaxDocGroup();
$InputThai=$oSys->SearchByInputThai();
$oDws = new docwsign($oC);
$oDcp = new doccommentpropose($oC);
$oNe = new NoticeEditDoc($oC);
$oNe1 = new NoticeEditDoc($oC);
$oDbxS = new DocInboxStaff($oC);
$oDbxS1 = new DocInboxStaff($oC);
$oDbxS3 = new DocInboxStaff($oC);
$oDbxS2 = new DocInboxStaff($oC);
if($_SESSION['DLCID'] && $_SESSION['one_position']!="1"){ include_once "selectposition.php";
?>
<?
$oDlc->SearchByKey($_SESSION['DLCID']); $oDlc->GetRecord();
if($_SESSION['DLCIDSECOND']=="Y"){
$oDlc7->SearchByKey($_SESSION['DLCIDSECONDID']); $oDlc7->GetRecord();
$mypersonId=$oDlc7->personId;
}else{
$mypersonId=$oDlc->personId;
}
$oDlp1->SearchByKey($oDlc->DlpID); $oDlp1->GetRecord();
$oDoc->SearchByKey($DocID); $oDoc->GetRecord();
$oRs5->SearchByKey($DrsID);$oRs5->GetRecord();
//echo $DLCID."<br>";
//echo $oDlc->personId;
/*
function pre($value="") { // Create Tag "<pre>...</pre>"
echo "<pre>";
if($value!=""){
if(is_array($value)) {
print_r($value);
} else {
var_dump($value);
}
}else{
echo "Not value to function \"pre\".";
}
echo "</pre>";
}
*/
//echo "SESSION =";
//pre($_SESSION);
?>
<html>
<head>
<script language="javascript">
var XMLHttpRequestObject=false;
if(window.XMLHttpRequest){
XMLHttpRequestObject=new XMLHttpRequest();
}else if(window.ActiveXObject){
XMLHttpRequestObject=new ActiveXObject("Microsoft.XMLHTTP");
}
function getData(data,divID){
document.getElementById("div2").style.display = "";
if(XMLHttpRequestObject){
var searchName = document.getElementById("name").value;
var obj = document.getElementById(divID);
data=data+"?name="+searchName;
XMLHttpRequestObject.open("GET",data);
XMLHttpRequestObject.onreadystatechange=function(){
if(XMLHttpRequestObject.readyState==4 &&
XMLHttpRequestObject.status==200){
obj.innerHTML=XMLHttpRequestObject.responseText;
}
}
XMLHttpRequestObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
XMLHttpRequestObject.send(null);
}
}
</script>
<script language="javascript" src="../source/calendarDateInput.js"></script>
<script src="getinfo.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=tis-620">
<link href="../source/style.css" rel="stylesheet" type="text/css">
</head>
<body>
<table width="100%" align="center">
<tr><td >
<fieldset>
<legend><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>"><a href="regisDoc.php">ลงทะเบียนใหม่/เสนอหนังสือ</a>
<img src="../picture/ico3.gif" width="10" border="0" align="absmiddle">รายละเอียดข้อมูลทะเบียนหนังสือ</font>
</font></legend>
<form name="ff" METHOD="POST" action="processProposeDoc.php">
<table align="center" width="93%" >
<tr>
<td width="68%" height="25"><img src="../picture/official_letter.gif" border="0" >
<font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="3"><strong>การเสนอลงนามหนังสือ</strong></font>
</td>
</tr>
<tr>
<td colspan="3"><hr color="#000099"></hr>
</td>
</tr>
<tr align="right"><td align="right"><a href="addRegisDoc.php"><img src="../picture/regist_tc.jpg" title="ลงทะเบียน" border="0" style="cursor:pointer;"></a></td></tr>
</table>
<table width="93%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>" style="border-collapse:collapse">
<tr><td colspan="2" background="../picture/table_header_bg2.gif" height="25">
<font color="<?php echo $GLOBALS["COLOR_FONT_1"]; ?>" size="2"><strong>
รายละเอียดของหนังสือ: </strong></font>
<font color="<?php echo $GLOBALS["COLOR_FONT_8"]; ?>" size="2"><strong>
<? if($RsID==1){
echo $oRSt->SearchShowRsName(1);
}else if($RsID==2){
echo $oRSt->SearchShowRsName(2);
}else if($oDoc->RsID==3){
echo $oRSt->SearchShowRsName(3);
}else if($RsID==4){
echo $oRSt->SearchShowRsName(4);
}
?>
</strong></font>
<font color="<?php echo $GLOBALS["COLOR_FONT_1"]; ?>" size="2"><strong> ชนิดหนังสือ: </strong></font>
<font color="<?php echo $GLOBALS["COLOR_FONT_8"]; ?>" size="2"><strong>
<? $oDt->SearchByKey($DtID);
$oDt->GetRecord();
echo $oDt->DtName;
?>
</strong></font>
</td></tr>
<tr>
<? //---------detail doc------------------------------?>
<td width="52%" align="center" valign="top">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>" style="border-collapse:collapse"><tr>
<td valign="top">
<table width="97%" border="0" align="center" cellpadding="0" cellspacing="1" bordercolor="#DADADA" >
<tr><td> </td></tr>
<? if($oDoc->DocIDHisOld!='0'){ ?>
<tr><td colspan=3 align=right> <a onClick = "newPagej('printDetailRepHisRegisDocDept.php?DocID=<? echo $oDoc->DocIDHisOld; ?>')" style="cursor:pointer;">ดูหนังสือนี้ในโครงสร้างเก่า [ที่นี่]</a></td></tr>
<? }?>
<tr height=22><td width="32%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong><? echo ShowNameDocNo($DtID); ?></strong></td>
<td width="1%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DtID!="15"){ if($oDoc->DocNo!=""){ echo $oDoc->DocNo; } }else{ echo '-';} ?></td></tr>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong><? echo ShowNameDate2($DtID); ?></strong></td>
<td width="2%" align="center" ><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>">
<? if($oDoc->DocDate!="" && $oDoc->DocDate!="0000-00-00"){
echo " ".abbreDate2($oDoc->DocDate,'/');
} ?>
</td></tr>
<? //if($DtID!=13){ ?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>" > <strong><? echo ShowNameSubject($DtID); ?></strong></td>
<td width="2%" align="center"><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocSubject!=""){ echo $oDoc->DocSubject; } ?></td>
</tr>
<? //} ?>
<? if($DtID==1 || $DtID==2 || $DtID==3 || $DtID==14 || $DtID==13 || $DtID==15){?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong><? echo ShowNameFrom($DtID); ?></strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocFrom!=""){ echo $oDoc->DocFrom; } ?></td>
</tr>
<? } ?>
<? if($DtID==13){?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>ชื่อผู้ได้รับการรับรอง</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->CertificatePs!=""){ echo $oDoc->CertificatePs; } ?></td>
</tr>
<? } ?>
<? if($DtID==1 || $DtID==2 || $DtID==14 || $DtID==3 || $DtID==15){?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong><? if($DtID==3 || $DtID==15){ echo "เรียน"; }else{ echo "ถึง"; } ?></strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocTo!=""){ echo $oDoc->DocTo; }?></td>
</tr>
<? }?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>แฟ้มหนังสือ</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td width="67%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>">
<? if($oDoc->DocPID=="0" || $oDoc->DocPID==""){ $searchDoc=$oDoc->DocID; }else{ $searchDoc=$oDoc->DocPID; } ?>
<font size="2" color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>">
<img src="../picture/attach_ico.gif" border="0" > แฟ้มที่เกี่ยวข้อง <? $cdoc=$oDatt->CountDocByDocID($searchDoc); echo a2th($cdoc); ?> รายการ
<? echo downloadProgramRead($oSys->downloadPpdf); ?></font><br>
<?
$oDatt->SearchByDocID($searchDoc);
while($oDatt->GetRecord()){
$c++;
$pathfile=$GLOBALS['path_download_documents'].$oDatt->DaUpFileName;
?>
<a href="<? echo $pathfile ; ?>" target="_blank"><img src="../picture/allregistered_ico.gif" title="เปิดดูแฟ้มหนังสือ" border="0" style="cursor:pointer;" ></a>
<? echo " ".$c.". ".$oDatt->DaFileName."<br>";
} ?>
<? include("uploadDocSended.php"); echo manageDocAtt2($searchDoc);?>
</td>
</tr>
<? if(($DtID==1 || $DtID==2) && ($RsID=="2" || $RsID=="1")){?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>อ้างถึง</strong></td>
<td width="2%" align="center"><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocRef!=""){ echo $oDoc->DocRef; } ?></td>
</tr>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>สิ่งที่ส่งมาด้วย</strong></td>
<td width="2%" align="center"><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocOther!=""){ echo $oDoc->DocOther; }?></td>
</tr>
<? } ?>
<? if($DtID==3 && ($RsID=="3" || $RsID=="4")){?>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>อ้างถึงหนังสือ<br>เพื่อตอบกลับ</strong></td>
<td width="2%" align="center"><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <? if($oDoc->DocRefAns!=""){ echo $oDoc->DocRefAns; } ?></td>
</tr>
<? } ?>
<? if($DtID==1 || $DtID==2 || $DtID==3 || $DtID==14 || $DtID==15){?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>ชั้นความเร็ว</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>">
<? $oDsl->SearchByKey($oDoc->DslID); $oDsl->GetRecord(); echo " ".$oDsl->DslName;?>
</td></tr>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>ชั้นความลับ</strong></td>
<td width="2%" align="center" ><strong>:</strong></td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>">
<? $oDcl->SearchByKey($oDoc->DclID); $oDcl->GetRecord(); echo " ".$oDcl->DclName;?></td>
</tr>
<? } ?>
<? if($DtID==1 || $DtID==2 || $DtID==14){?>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>หน่วยงานเจ้าของเรื่อง</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><? if($oDoc->DocDeptOwner!=""){ echo " ".$oDoc->DocDeptOwner; } ?></td>
</tr>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>เบอร์โทรศัพท์เจ้าของเรื่อง</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><? if($oDoc->DocTelOwner!=""){ echo " ".$oDoc->DocTelOwner; } ?></td>
</tr>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>โทรสารเจ้าของเรื่อง</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><? if($oDoc->DocFaxOwner!=""){ echo " ".$oDoc->DocFaxOwner; } ?></td>
</tr>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>สำเนาส่ง</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><? if($oDoc->DocCopySend!=""){ echo " ".$oDoc->DocCopySend; } ?></td>
</tr>
<tr height=22><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>การติดต่อทางอิเล็กทรอนิกส์</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><? if($oDoc->DocContactE!=""){ echo " ".$oDoc->DocContactE; } ?></td>
</tr>
<? } ?>
<tr height=22><td width="31%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"> <strong>หมายเหตุ</strong></td>
<td width="2%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>">
<? if($oDoc->DocShortDesc!=""){ echo " ".$oDoc->DocShortDesc; } ?>
</td>
</tr>
<? if($oDoc->DocforSign=="Y"){ ?>
<tr height=22><td width="25%"> </td>
<td width="2%" align="center"> </td>
<td >
<input name="" type="checkbox" value="" checked disabled> ลงทะเบียนหนังสือลงนาม
</td>
</tr>
<? } ?>
<? if($oDoc->sendToPs=="Y"){ ?>
<tr height=22><td width="25%"> </td>
<td width="2%" align="center"> </td>
<td >
<input name="" type="checkbox" value="" checked disabled> ส่งด่วน
</td>
</tr>
<? } ?>
<? if(($DtID==1 || $DtID==2 || $DtID==14) && $oDoc->DocSendReal=="Y"){?>
<tr height=22>
<td width="24%"> </td>
<td width="1%" align="center"> </td>
<td > <input name="" type="checkbox" value="" checked disabled>
ส่งหนังสือตัวจริงตามไปด้วย </td>
</tr>
<? } ?>
<tr><td> </td></tr>
</table>
</td></tr></table>
</td>
<? //---------propose doc------------------------------?>
<td width="48%" align="center" valign="top">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>"><tr><td >
<? if($caseother!="1"){ ?>
<table width="97%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr height=25 valign="middle">
<td colspan="3" height="25"> <font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>
<br> รายละเอียดสำหรับเสนอลงนาม<br></strong></font></td>
</tr>
<tr height="40">
<td width="33%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>" > <strong>ผู้มีอำนาจลงนาม</strong></td>
<td width="1%" align="center"><strong>:</strong></td>
<td width="66%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>" align="center">
<? //$DlcPs=GetNextPsToSign($DLCID,$oDlc->deptId);
$DlcPs=GetNextPrePsToSign($DLCID,$oDlc->deptId);
if($DlcPs=="N"){ $NoSign=1; ?>
<font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2">ไม่ได้กำหนดสิทธิ์ผู้มีอำนาจเสนอลงนาม กรุณาติดต่อผู้รับผิดชอบระบบ</font>
<? }else{
$oRs9->SearchByDocGroupDocIDStatus2($oDoc->DocGroup,$DocID);
$oRs9->GetRecord();
if($oDoc->DsID=="2" && $oRs9->DrsReceivePersonId!=0){ //update sign
$oPS1->SearchByKey($oRs9->DrsReceivePersonId); $oPS1->GetRecord();
$oDlc2->SearchByKey($oRs9->DlcID); $oDlc2->GetRecord();
$oDlp->SearchByKey($oDlc2->DlpID); $oDlp->GetRecord();
echo " ".GetPrefix($oPS1->prefixId).$oPS1->fName." ".$oPS1->lName."<br>";
}else{
// no set personId
$oDlc2->SearchByKey($DlcPs); $oDlc2->GetRecord();
$oPS->SearchByKey($oDlc2->personId); $oPS->GetRecord();
$oDlp->SearchByKey($oDlc2->DlpID); $oDlp->GetRecord();
}
?>
<font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><? echo " (".$oDlp->DlpName.")"; ?></font>
<? }?>
</td>
</tr>
<? if($oDoc->DsID=="1"){ ?>
<tr height=22>
<td rowspan="2" align="left" width="33%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>"> <strong><!--a style="cursor:pointer;" onClick = "addSupplementMsg('<? echo $DtID; ?>','<? echo $RsID; ?>','<? echo $DocID; ?>','<? echo $DrsID;?>')"-->การบันทึก<br> ต่อเนื่อง<!--/a--></strong></td>
<td width="1%" align="center"><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>" align="left">
<table width="100%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_4"]; ?>"><tr><td ><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><b>เลือกข้อความบันทึกต่อเนื่อง</b><br><font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2">(คลิก <img src=../picture/arrow_down.gif border=0> เพื่อเลือก)</font></font></td></tr></table>
<div style="overflow: auto; height: 100px;">
<table align="left" width="93%">
<? $oDcp->RSdoccommentpropose();
while($oDcp->GetRecord()){
$commentP=str_replace(' ','_',$oDcp->commentP);
?><tr><td height="20"><img src=../picture/arrow_down.gif title=เลือก border=0 style="cursor:pointer;" onclick=ShowInfoProposeSign('showSelectPropose.php','div3','<? echo $commentP; ?>','<? echo $InputThai; ?>')> <? echo $oDcp->commentP; ?></td></tr>
<? } ?>
</table></div><br>
<table width="100%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_4"]; ?>"><tr><td ><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><b>เลือกชื่อหน่วยงานย่อย</b><br><font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2">(คลิก <img src=../picture/arrow_down.gif border=0> เพื่อเลือก)</font></font></td></tr></table>
<div style="overflow: auto; height: 100px;">
<table align="left" width="93%">
<?
$oDP5->RSDeptByMaxdeptDate2();
while($oDP5->GetRecord()){
$deptName=str_replace(' ','_',$oDP5->deptName);
?>
<tr><td height="20"><img src=../picture/arrow_down.gif title=เลือก border=0 style="cursor:pointer;" onclick=ShowInfoProposeSign2('showSelectPropose.php','div3','<? echo $deptName; ?>','<? echo $InputThai; ?>')><? echo $oDP5->deptName; ?></td></tr>
<? } ?>
</table></div><br>
</td>
</tr>
<tr><td> </td><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>"><span id="div3"><textarea name="DrsPropose" id="DrsPropose" cols="30" rows="5" <? echo showtextarea('DrsPropose',$InputThai); ?>></textarea></div>
</td></tr>
<? } ?>
<? if($oDoc->DsID=="2"){ // status sign ?>
<tr>
<td width="33%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>"> <strong>การบันทึกต่อเนื่อง</strong></td>
<td width="1%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>" align="left">
<?
//echo "docid=".$DocID."<br>";
$oRs->SearchByDocGroupDocIDStatus2($oDoc->DocGroup,$DocID);
$oRs->GetRecord();
echo nl2br($oRs->DrsPropose);
?>
</td>
</tr>
<? } ?>
<tr>
<td width="33%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>"> <strong>ผู้เสนอลงนาม</strong></td>
<td width="1%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_17"]; ?>" align="center">
<table>
<? if($oDoc->DsID=="2"){ // status sign ?>
<tr><td align="center">
<? $oPS->SearchByKey($oRs5->DrsPsIDCreate); $oPS->GetRecord();
echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName."<br>";
$oDlc4->SearchByKey($oRs->DrsDlcIDCreate); $oDlc4->GetRecord();
$oDlp->SearchByKey($oDlc4->DlpID); $oDlp->GetRecord();
?>
<font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">
<?
echo " (".$oDlp->DlpName.")<br>";
if($oDoc->DsID=="2"){
list($DocD,$DocT) = preg_split('[ ]',$oRs->DrsReceiveDate );
echo abbreDate2($DocD,'/')." ".a2th($DocT)." ";
} ?></font>
</td></tr>
<? }else{ //status not sign?>
<tr><td align="center">
<? $oPS->SearchByKey($oRs->DrsPsIDCreate); $oPS->GetRecord(); ?>
<? echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName."<br>";
$oDlp->SearchByKey($oDlc->DlpID); $oDlp->GetRecord();
?>
<font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">
<?
echo " (".$oDlp->DlpName.")<br>";
if($oDoc->DsID=="2"){
list($DocD,$DocT) = preg_split('[ ]',$oRs->DrsReceiveDate );
echo abbreDate2($DocD,'/')." ".a2th($DocT)." ";
} ?></font>
</td></tr>
<? } //status not sign?>
</table>
</td>
</tr>
<tr><td> </td></tr>
<? //} ?>
<tr height=25>
<td align="center" colspan="3">
<? if($oDP4->GetattachFile($oDlc->deptId)=="Y"){
$cdoc=1;
}
?>
<? if($oDoc->DtID==15){ $DocForSign=1; }?>
<? if($oDoc->DsID=="1"){ ?>
<input type="submit" name="addpropose" value="เสนอลงนาม" onClick="return checkFormat('<? echo $NoSign; ?>','<? echo $NoPs;?>','<? echo $cdoc; ?>','<? echo $DocID; ?>','<? echo $DrsID;?>','<? echo $DtID; ?>','<? echo $RsID;?>');" <? if($oDlc->DlcActive!='Y'){ echo "disabled"; } ?>>
<? } ?>
<input type="button" name="cancel" value="กลับหน้าหลัก" onClick="location.href = 'regisDoc.php?page_id2=<? echo $page_id2;?>&DtID=<? echo $DtID;?>&RsID=<? echo $RsID;?>&selectpredocdatevalue=<? echo $selectpredocdatevalue;?>&searchpredocdate=<? echo $searchpredocdate; ?>&folderstaff2=<? echo $folderstaff2;?>&forfolderstaff2=<? echo $forfolderstaff2;?>'">
<? if($oDoc->DsID=="1"){ ?>
<input type="hidden" name="method" id="method" >
<input type="hidden" name="DlcPs" id="DlcPs" value="<? echo $DlcPs; ?>">
<input type="hidden" name="DlcPsId" id="DlcPsId" value="<? echo $oDlc2->personId; ?>">
<input type="hidden" name="DocID" id="DocID" value="<? echo $DocID; ?>">
<input type="hidden" name="DrsID" id="DrsID" value="<? echo $DrsID; ?>">
<input type="hidden" name="DocGroup" id="DocGroup" value="<? echo $MaxDocGroup; //echo $oDoc->DocGroup; ?>">
<input type="hidden" name="DlcID" id="DlcID" value="<? echo $oDoc->DlcID; ?>">
<input type="hidden" name="personId" id="personId" value="<? echo $mypersonId; ?>">
<input type="hidden" name="DlcIDlogin" id="DlcIDlogin" value="<? echo $DLCID; ?>">
<input type="hidden" name="RsID" id="RsID" value="<? echo $RsID; ?>">
<input type="hidden" name="DtID" id="DtID" value="<? echo $DtID; ?>">
<? } ?>
<input type="hidden" name="searchpredocdate" id="searchpredocdate" value="<? echo $searchpredocdate; ?>">
<input type="hidden" name="selectpredocdatevalue" id="selectpredocdatevalue" value="<? echo $selectpredocdatevalue; ?>">
<input type="hidden" name="DocForSign" id="DocForSign" value="<? echo $DocForSign; ?>">
<input type="hidden" name="DocPID" id="DocPID" value="<? echo $oDoc->DocPID; ?>">
<input type="hidden" name="page_id2" id="page_id2" value="<? echo $page_id2; ?>">
<input type="hidden" name="folderstaff2" id="folderstaff2" value="<? echo $folderstaff2; ?>">
<input type="hidden" name="forfolderstaff2" id="forfolderstaff2" value="<? echo $forfolderstaff2; ?>">
</td>
</tr>
</table>
<? $DlcPsByPass=GetNextPsToByPass($DLCID,$oDlc->deptId);
if($DlcPsByPass=="Y"){
if($oDoc->DsID!="2"){ // status sign
?>
<table width="97%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" style="border-collapse:collapse">
<tr><td colspan="2"><hr color="#000099"></hr></td></tr>
<tr><td width="33%" align="center" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>ไม่ต้องเสนอลงนาม</strong></font></td>
<td width="67%" align="left" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_16"]; ?>"> <input name="ByPass" type="submit" value="<? if($DtID!="15" || ($DtID==15 && $oDoc->DocPID==0)){ echo "ส่งผ่าน"; }else{ echo "ส่งผ่าน/ลงนามแล้ว";}?>" onClick="return checkFormat2('<? echo $DocID; ?>','<? echo $DrsID;?>','<? echo $DtID; ?>','<? echo $RsID;?>','<? echo $cdoc; ?>')" <? if($oDlc->DlcActive!='Y'){ echo "disabled"; } ?>></td></tr>
</table>
<? } } //end bypass ?><? } //if case other?>
</td></tr></table>
</td>
<? //---------end propose doc------------------------?>
</tr></table>
<? if($oNe1->NumRowNoticeEditDoc($DocID,$DrsID)!=0){ ?><br>
<table width="93%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="<?php echo $GLOBALS["COLOR_BG_TD_1"]; ?>" style="border-collapse:collapse">
<tr><td colspan="2" background="../picture/table_header_bg2.gif" height="25"><font color="<?php echo $GLOBALS["COLOR_FONT_1"]; ?>" size="2"><strong> การแก้ไขข้อมูลหนังสือ</strong></font></td></tr>
<tr><td>
<? $i=0;
$oNe->SearchNumRowNoticeEditDoc($DocID,$DrsID);
while($oNe->GetRecord()){ ?>
<table width="100%" border="0">
<tr><td width="56%"><font color="#66CC00"><b>ครั้งที่ <? echo ($i+1); ?></b></font> <b>สถานะ</b> <? echo showStatusNoticeDoc($oNe->statusDoc)?><? if($oNe->statusDoc=="1"){ ?> <input type="button" name="editdoc" value="แก้ไขแล้ว" onClick="return checkEditNoticeDoc('<? echo $DtID; ?>','<? echo $RsID; ?>','<? echo $DocID; ?>','<? echo $DrsID; ?>','<? echo $oNe->neID; ?>','<? echo $DLCID; ?>','<? echo $mypersonId; ?>','<? echo $selectpredocdatevalue; ?>','<? echo $searchpredocdate; ?>');"><? }?></td></tr>
<? if($oNe->statusDoc==1 || $oNe->statusDoc==2){ ?>
<tr><td height=22><b>ผู้แจ้งแก้ไข ::</b> <? $oPS->SearchByKey($oNe->PsCreate); $oPS->GetRecord();
echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName; ?> (<? $oDlc5->SearchByKey($oNe->DlcIDCreate); $oDlc5->GetRecord();
$oDlp1->SearchByKey($oDlc5->DlpID); $oDlp1->GetRecord(); echo $oDlp1->DlpName; ?>)</td>
<td width="44%" ><b>วันเวลาที่แจ้ง ::</b> <? list($DocD,$DocT) = preg_split('[ ]',$oNe->DocCommentDate); echo abbreDate2($DocD,'/')." ".a2th($DocT);?></td>
</tr>
<tr><td height=22><b>แจ้งถึง ::</b><? $oPS->SearchByKey($oNe->PsReceive); $oPS->GetRecord();
echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName; ?> (<? $oDlc5->SearchByKey($oNe->DlcIDReceive); $oDlc5->GetRecord();
$oDlp1->SearchByKey($oDlc5->DlpID); $oDlp1->GetRecord(); echo $oDlp1->DlpName; ?>)
</td>
<td><b>ข้อความแจ้งแก้ไข ::</b> <? echo $oNe->DocComment;?></td></tr>
<? } ?>
<? if($oNe->statusDoc==2 || $oNe->statusDoc==3){ ?>
<tr><td height="22"><b>ผู้แก้ไข ::</b> <? $oPS->SearchByKey($oNe->PsSend); $oPS->GetRecord();
echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName; ?> (<? $oDlc5->SearchByKey($oNe->DlcIDSend); $oDlc5->GetRecord();
$oDlp1->SearchByKey($oDlc5->DlpID); $oDlp1->GetRecord(); echo $oDlp1->DlpName; ?>)</td>
<td><b>วันเวลาที่แก้ไข ::</b> <? list($DocD,$DocT) = preg_split('[ ]',$oNe->DocSendDate); echo abbreDate2($DocD,'/')." ".a2th($DocT);?></td></tr>
<? } ?>
</table><? $i++; } ?>
</td></tr>
</table><br><? }?><br>
<?
//if($oDoc->RsID=="3"){
if($oDlc->DlcView=="Y"){
$lineDoc=GetLineDoc($DocID,$oDoc->DocGroup,$oDoc->DsID,$DrsID);
$checkshow=0;
if($lineDoc!=$DrsID){ $lineDoc=$lineDoc.$oRs5->DrsID; $checkshow=1;} //echo "=".$lineDoc."<br>";
?>
<table width="93%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr><td align="right"><a onClick = "showline('<? echo $searchDoc;?>')" style="cursor:pointer;"><img src="../picture/button_showline.jpg" border="0" style="cursor:pointer;"></a>
<a onClick = "showline2('<? echo $searchDoc;?>')" style="cursor:pointer;"><img src="../picture/sign_tc.jpg" border="0" style="cursor:pointer;"></a>
</td></tr>
</table>
<table width="93%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#FFCC99" style="border-collapse:collapse" >
<tr><td><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" background="../picture/table_header_bg4.gif">
<tr>
<td width="68%" height="25">
<font color="<?php echo $GLOBALS["COLOR_FONT_1"]; ?>" size="2"><strong> <? if($checkshow==1){ ?>เส้นทางเดินของหนังสือ<? }else{ ?>ข้อมูลการลงรับหนังสือ <? } ?></strong></font>
</td>
</tr>
</table><br>
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#DADADA" style="border-collapse:collapse">
<tr>
<td align="center">
<? if($checkshow==1){ ?><div style="overflow: auto; height: 300px; width: 100%;"><? } ?>
<?
while($lineDoc!=""){
list($line,$lineDoc)=preg_split('[,]',$lineDoc,2);
$oRs2->SearchByKey($line);
$oRs2->GetRecord();
$oDoc2->SearchByKey($oRs2->DocID);
$oDoc2->GetRecord();
$oDlc3->SearchByKey($oDoc2->DlcID);
$oDlc3->GetRecord();
if($oRs2->DsID=="1"){
?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#DADADA" >
<tr height=22>
<td colspan="3"> <strong>ข้อมูลการลงรับของหน่วยงาน <? $oDP->SearchByKey($oDlc3->deptId); $oDP->GetRecord(); echo $oDP->deptName;?></strong><? if($oRs2->DrsNoRegisReceive=='Y'){ ?> (รับหนังสือแต่ไม่ลงเลขรับใหม่)<? } ?><br>
</td>
</tr>
<tr height=22>
<td width="36%"> ชนิดหนังสือ : <? $oDt->SearchByKey($oDoc2->DtID); $oDt->GetRecord(); echo $oDt->DtName; ?></td>
<td width="20%">เลขทะเบียน<? echo ShowNameRSDoc2($oDoc2->RsID);?> : <?php echo a2th($oDoc2->DocTypeNo);?></td>
<td width="44%">วันที่ลงทะเบียน : <?php
list($DocD,$DocT) = preg_split('[ ]',$oDoc2->DocDateCreate);
echo abbreDate2($DocD,'/')." ".a2th($DocT); ?></td>
</tr>
<tr height=22>
<td colspan="3"> ลงรับโดย : <? $oPS->SearchByKey($oRs2->DrsReceivePersonId); $oPS->GetRecord(); ?>
<? echo " ".GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName; ?>
<? $oDlp->SearchByKey($oDlc3->DlpID); $oDlp->GetRecord();
echo " (".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->deptName).")"; ?></td>
</tr>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? if($oRs2->DrsByPass=="Y"){
$oRs3->SearchByDrsFromDrsID($oRs2->DrsID);
$oRs3->GetRecord();
?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr><td colspan="3"> <strong>ข้อมูลการส่งผ่าน</strong></td></tr>
<tr><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> การบันทึกต่อเนื่อง</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo nl2br($oRs2->DrsByPassPropose); ?></td>
</tr>
<tr height=22>
<td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้ส่งผ่าน</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td width="75%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>" align="center">
<? $oPS->SearchByKey($oRs3->DrsPsIDCreate); $oPS->GetRecord(); ?>
<? echo GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName." "; ?>
<? $oDlc5->SearchByKey($oRs2->DlcID); $oDlc5->GetRecord();
$oDlp->SearchByKey($oDlc5->DlpID); $oDlp->GetRecord();
echo "(".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->SearchDeptName($oDlc5->deptId)).")";
list($DocD,$DocT) = preg_split('[ ]',$oRs2->DrsSendDate );
echo "<br>".abbreDate2($DocD,'/')." ".a2th($DocT);
?>
</td>
</tr>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? } //DrsByPass?>
<? }else if($oRs2->DsID=="2"){ ?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr><td height="17" colspan="3"> <strong>ข้อมูลการเสนอลงนาม</strong></td></tr>
<tr><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> การบันทึกต่อเนื่อง</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo nl2br($oRs2->DrsPropose); ?></td>
</tr>
<tr height=22>
<td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้เสนอลงนาม</td>
<td width="0%" align="center" ><strong>:</strong></td>
<? $oRs3->SearchByKey($oRs2->DrsFromDrsID);
$oRs3->GetRecord();
?>
<td width="75%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>" align="center">
<? $oPS->SearchByKey($oRs2->DrsPsIDCreate); $oPS->GetRecord(); ?>
<? echo GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName." "; ?>
<? $oDlc5->SearchByKey($oRs2->DrsDlcIDCreate); $oDlc5->GetRecord();
$oDlp->SearchByKey($oDlc5->DlpID); $oDlp->GetRecord();
echo "(".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->SearchDeptName($oDlc5->deptId)).") ";
list($DocD,$DocT) = preg_split('[ ]',$oRs2->DrsReceiveDate );
echo abbreDate2($DocD,'/')." ".a2th($DocT);
?>
</td>
</tr>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? if($oRs2->DrsWSign=='Y'){ //case DrsWSign
$oDws->SearchByDrsIDDocID($oRs2->DrsID,$oRs2->DocID);
$oDws->GetRecord();
?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr><td colspan="3"> <strong>ข้อมูลการ<? echo $GLOBALS['DOCFORSIGNNAME'];?></strong></td></tr>
<tr><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> การบันทึกต่อเนื่อง</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo nl2br($oDws->DocSign); ?></td>
</tr>
<tr height=22>
<td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้ลงนาม</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td width="75%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>" align="center">
<? $oPS->SearchByKey($oDws->personId); $oPS->GetRecord(); ?>
<? echo GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName." "; ?>
<? $oDlc5->SearchByKey($oDws->DlcID); $oDlc5->GetRecord();
$oDlp->SearchByKey($oDlc5->DlpID); $oDlp->GetRecord();
echo "(".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->SearchDeptName($oDlc5->deptId)).") ";
list($DocD,$DocT) = preg_split('[ ]',$oDws->signDateTime);
echo abbreDate2($DocD,'/')." ".a2th($DocT);
?>
</td>
</tr>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? } //case DrsWSign?>
<? }else if($oRs2->DsID=="3"){
$oRs4->SearchByKey($oRs2->DrsFromDrsID);
$oRs4->GetRecord();
if($oRs4->DrsByPass!="Y"){
?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr><td colspan="3"> <strong>ข้อมูลการลงนาม</strong></td></tr>
<tr><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> การบันทึกต่อเนื่อง</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo nl2br($oRs2->DrsSign); ?></td>
</tr>
<tr height=22>
<td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้ลงนาม</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td width="75%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>" align="center">
<? $oPS->SearchByKey($oRs2->DrsPsIDCreate); $oPS->GetRecord(); ?>
<? echo GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName." "; ?>
<?
$oDlc5->SearchByKey($oRs2->DrsDlcIDCreate); $oDlc5->GetRecord();
$oDlp->SearchByKey($oDlc5->DlpID); $oDlp->GetRecord();
echo "(".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->SearchDeptName($oDlc5->deptId)).") ";
list($DocD,$DocT) = preg_split('[ ]',$oRs2->DrsReceiveDate );
echo abbreDate2($DocD,'/')." ".a2th($DocT);
?>
</td>
</tr>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? }
}else if($oRs2->DsID=="0" || $oRs2->DsID=="4" || $oRs2->DsID=="5"){ ?>
<? //if($oRs2->DrsSendDate!="0000-00-00 00-00-00"){ //show status=3 send to person ?>
<? $oRs6->SearchByKey($oRs2->DrsID);
$oRs6->GetRecord();
//echo "DrsID=".$oRs6->DrsID."<br>";
?>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="2" bordercolor="#DADADA" >
<tr><td colspan="3"> <strong>ข้อมูลการส่งถึงผู้รับผิดชอบ</strong></td></tr>
<? if($oRs6->PtID!=0 && $oRs6->PtID!=""){
$oPt->SearchByKey($oRs6->PtID);
$oPt->GetRecord();
?>
<? if($oRs6->DrsSendDocNew!="0000-00-00 00:00:00"){ ?>
<tr><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ส่งเพิ่มเติม</td>
<td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>">
<? list($DocD2,$DocT2) = preg_split('[ ]',$oRs6->DrsSendDocNew);
echo abbreDate2($DocD2,'/')." ".a2th($DocT2);
?></td>
</tr>
<? } ?>
<tr><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ลักษณะหนังสือ</td>
<td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo $oPt->PtName; ?></td>
</tr>
<? } ?>
<? if($oRs6->AnID!=0 && $oRs6->AnID!=""){
$oAn->SearchByKey($oRs6->AnID);
$oAn->GetRecord();
?>
<tr><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ข้อมูลขึ้นเว็บ</td>
<td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo $oAn->AnName; ?>
<br> แจ้งขึ้นเว็บ <? echo ShowNameonweb($oDoc2->DocShowInOut); ?>
<br> วันที่ประกาศขึ้นเว็บ
<? if($oRs6->DrsstartDatePost!="0000-00-00"){
if($oRs6->DrsstartDatePost==$oRs6->DrsendDatePost){
echo abbreDate2($oRs6->DrsstartDatePost,'/');
}else{
echo abbreDate2($oRs6->DrsstartDatePost,'/')." ถึง ".abbreDate2($oRs6->DrsendDatePost,'/');
}
}
?>
</td>
</tr>
<? } ?>
<tr><td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> การบันทึกต่อเนื่อง</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo nl2br($oRs6->DrsPropose); ?></td>
</tr>
<tr height=22>
<td width="25%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้ส่งหนังสือ</td>
<td width="0%" align="center" ><strong>:</strong></td>
<td width="75%" bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>" align="center">
<? $oPS->SearchByKey($oRs6->DrsPsIDCreate); $oPS->GetRecord(); ?>
<? echo GetPrefix($oPS->prefixId).$oPS->fName." ".$oPS->lName." "; ?>
<?
$oDlc5->SearchByKey($oRs6->DrsDlcIDCreate); $oDlc5->GetRecord();
$oDlp->SearchByKey($oDlc5->DlpID); $oDlp->GetRecord();
echo "(".ShowNamePosition($oDlp->DlpID,$oDlp->DlpName,$oDP->SearchDeptName($oDlc5->deptId)).") ";
$oRs8->SearchByKey($oRs6->DrsFromDrsID);
$oRs8->GetRecord();
list($DocD,$DocT) = preg_split('[ ]',$oRs8->DrsSendDate);
echo abbreDate2($DocD,'/')." ".a2th($DocT);
?>
</td>
</tr>
<? //$oDoc3->SearchByKey($oRs6->DocID); $oDoc3->GetRecord();
if($oRs6->DrsDocDueDate!="0000-00-00"){ ?>
<tr><td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> กำหนดระยะเวลาดำเนินการ</td>
<td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> ภายในวันที่ <? echo abbreDate2($oRs6->DrsDocDueDate,'/');?></td></tr>
<? } ?>
<?
$MainPsDept=$oRs9->SearchByDrsFromDrsIDDrsMainPsDept($oRs2->DrsFromDrsID);
if($MainPsDept!="" && $MainPsDept!="0"){
$oDlc6->SearchByKey($MainPsDept);
$oDlc6->GetRecord();
$oDP3->SearchByKey($oDlc6->deptId); $oDP3->GetRecord();
?>
<tr>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> หน่วยงานรับผิดชอบหลัก</td><td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo $oDP3->deptName; ?></td>
</tr>
<? } ?>
<?
$MainPs=$oRs7->SearchByDrsFromDrsIDDrsMainPsY($oRs2->DrsFromDrsID);
if($MainPs!="" && $MainPs!="0"){
$oPS2->SearchByKey($MainPs); $oPS2->GetRecord();
?>
<tr>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_21"]; ?>"> ผู้รับผิดชอบหลัก</td><td><strong>:</strong></td>
<td bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_22"]; ?>"> <? echo GetPrefix($oPS2->prefixId).$oPS2->fName." ".$oPS2->lName." "; ?></td>
</tr>
<? } ?>
<tr>
<td colspan=3><hr color="#C87904"></hr></td>
</tr>
</table>
<? } //show status=3 send to person?>
<? // }
} //each lineDoc ?>
<? if($checkshow==1){ ?></div><? } ?> </td>
</tr>
<tr><td> </td></tr>
</table>
</td></tr></table>
<? } //DlcView
// } //show RsID==3 ?>
<br>
<? if($oDlp1->DlpPID==0){
//==================================================================================
//========= จัดเก็บหนังสือในโฟลเดอร์ =========================================================
//==================================================================================
?>
<div id="showDIb" ><? //include("showSelectDIb_RegisDoc.php");?></div>
<? } ?>
<br>
</form> <div align="center"><input type="button" name="cancel" value="กลับหน้าหลัก" onClick="location.href = 'regisDoc.php?DtID=<? echo $DtID;?>&RsID=<? echo $RsID;?>&selectpredocdatevalue=<? echo $selectpredocdatevalue;?>&searchpredocdate=<? echo $searchpredocdate; ?>&folderstaff2=<? echo $folderstaff2;?>&forfolderstaff2=<? echo $forfolderstaff2;?>'"></div>
</fieldset> <table width="95%" border="0" align="center">
<tr>
<td width="142" align="left"><font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2"> <strong>หมายเหตุ
: </strong> </font></td>
<td width="1022" align="left"><img src="../picture/allregistered_ico.gif" border="0" >
<font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2">คลิกเพื่อเปิดดูแฟ้มหนังสือ </font></td>
</tr>
<tr>
<td width="142"> </td>
<td width="1022" align="left">
<font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2"> </font></td>
</tr></table>
</td>
</tr>
</table>
</body>
</html>
<? }else{ include_once "unselectposition.php"; } ?>
<script language="javascript">
function checkEditNoticeDoc(x,y,p,q,r,rr,ss,selectpredocdatevalue,searchpredocdate){
page_id2=document.getElementById("page_id2").value;
folderstaff2=document.getElementById("folderstaff2").value;
forfolderstaff2=document.getElementById("forfolderstaff2").value;
var agreee=confirm("คุณต้องการแจ้งแก้ไขหนังสือแล้วแน่นอนใช่หรือไม่");
if (agreee){
//alert("processProposeDoc.php?DtID="+x+"&RsID="+y+"&DocID="+p+"&DrsID="+q+"&neID="+r+"&method=noticeEditDoc"+"&dlcidsend="+rr+"&pssend="+ss+"&selectpredocdatevalue="+selectpredocdatevalue+"&searchpredocdate="+searchpredocdate);
window.location.href="processProposeDoc.php?page_id2="+page_id2+"&DtID="+x+"&RsID="+y+"&DocID="+p+"&DrsID="+q+"&neID="+r+"&method=noticeEditDoc"+"&dlcidsend="+rr+"&pssend="+ss+"&selectpredocdatevalue="+selectpredocdatevalue+"&searchpredocdate="+searchpredocdate+"&folderstaff2="+folderstaff2+"&forfolderstaff2="+forfolderstaff2;
return false ;
}else{
return false ;
}
}
function checkFormat(p,q,r,pp,qq,rr,ss){
if(p=="1" || q=="1"){
window.alert("ไม่สามารถเสนอลงนามได้ กรุณาติดต่อผู้รับผิดชอบระบบ");
return false ;
}
if(r==0){
var agreee=confirm("ยังไม่ได้แนบแฟ้มหนังสือ\nคุณต้องการกลับไปแนบแฟ้มหนังสือหรือไม่");
if (agreee){
window.location.href="editRegisDoc.php?DocID="+pp+"&DrsID="+qq+"&DtID="+rr+"&RsID="+ss;
return false ;
}else{
return false ;
}
}
var agree=confirm("คุณต้องการเสนอลงนามหนังสือแน่นอนใช่หรือไม่ ?");
if (agree){
document.ff.method.value="addpropose";
return true;
}else{
return false ;
}
}
function checkFormat2(p,q,r,s,t){
if(t==0){
var agreee=confirm("ยังไม่ได้แนบแฟ้มหนังสือ\nคุณต้องการกลับไปแนบแฟ้มหนังสือหรือไม่");
if (agreee){
window.location.href="editRegisDoc.php?DocID="+p+"&DrsID="+q+"&DtID="+r+"&RsID="+s;
return false ;
}else{
return false ;
}
}else{
var agree=confirm("คุณต้องการส่งผ่านแน่นอนใช่หรือไม่ ?");
if (agree){
document.ff.method.value="addByPass";
return true;
}else{
return false ;
}
}
}
function addSupplementMsg(p,q){
FileName = "addSupplementMsgTable.php?DLCID="+p+"&DlcPS2="+q;
var w=350;
var h=300;
strOption = "scrollbars=yes,left=400,top=100,width=" + w + ",height=" + h;
window.open(FileName,"",strOption);
}
function showline(p){
FileName = "showlinedocTable.php?searchDoc="+p;
var w=900;
var h=500;
strOption = "scrollbars=yes,left=370,top=100,menubar=1,width=" + w + ",height=" + h;
window.open(FileName,"",strOption);
}
function showline2(p){
FileName = "showlinedocTable2.php?searchDoc="+p;
var w=900;
var h=500;
strOption = "scrollbars=yes,left=370,top=100,menubar=1,width=" + w + ",height=" + h;
window.open(FileName,"",strOption);
}
function ShowInfoProposeSign2(data,divID,showName,InputThai){
str=showName;
showName=str.replace(/_/gi,' ');
showNameOld=document.getElementById('DrsPropose').value;
if(XMLHttpRequestObject){
var obj = document.getElementById(divID);
data=data+"?showName="+showNameOld+showName+"&InputThai="+InputThai;
XMLHttpRequestObject.open("GET",data);
XMLHttpRequestObject.onreadystatechange=function(){
if(XMLHttpRequestObject.readyState==4 &&
XMLHttpRequestObject.status==200){
obj.innerHTML=XMLHttpRequestObject.responseText;
}
}
XMLHttpRequestObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
XMLHttpRequestObject.send(null);
}
}
function ShowInfoProposeSign(data,divID,showName,InputThai){
str=showName;
showName=str.replace(/_/gi,' ');
if(XMLHttpRequestObject){
var obj = document.getElementById(divID);
data=data+"?showName="+showName+"&InputThai="+InputThai;
XMLHttpRequestObject.open("GET",data);
XMLHttpRequestObject.onreadystatechange=function(){
if(XMLHttpRequestObject.readyState==4 &&
XMLHttpRequestObject.status==200){
obj.innerHTML=XMLHttpRequestObject.responseText;
}
}
XMLHttpRequestObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
XMLHttpRequestObject.send(null);
}
}
</script>
|