Viewing file: checkDoc2.php (7.18 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
include_once("../../class/clsConnection.php");
include_once("../../class/clsDB.php");
include_once "../global.php";
include_once "../class/clsDocReceiveSend.php";
include_once "../class/clsDocuments.php";
include_once "../class/clsDepartment.php";
include_once "../class/clsDocLinePosition.php";
include_once "../class/clsDocLineConfig.php";
$oC = new clsConnection($GLOBALS['DBHOST'], $GLOBALS['DBNAME_EOFFICE'], $GLOBALS['DBUSER_EOFFICE'], $GLOBALS['DBPASS_EOFFICE']);
$oRs = new DocReceiveSend($oC);
$oRs2 = new DocReceiveSend($oC);
$oDoc = new Documents($oC);
$oDoc2 = new Documents($oC);
$oDP = new Department($oC);
$oDlp = new docLinePosition($oC);
$oDlp2 = new docLinePosition($oC);
$oDlp3 = new docLinePosition($oC);
$oDlp4 = new docLinePosition($oC);
$oDlc = new docLineConfig($oC);
$oDlc1 = new docLineConfig($oC);
$oDlc2 = new docLineConfig($oC);
$oDlc3 = new docLineConfig($oC);
$oDlp1 = new docLinePosition($oC);
$Maxgroup=$oDP->SearchMaxDocGroup();
if($flagshowvalue==1){
?>
<html>
<title>ระบบสารบรรณ</title>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874">
<link href="../source/style.css" rel="stylesheet" type="text/css">
</head>
<body>
<br>
<table width="100%" border="0" cellpadding="2" cellspacing="2">
<tr><td><img src="../picture/alert.gif"> <font size="3" color="#FFCC66"><strong>ระบบสารบรรณ</strong></font><br><hr color="#000099"></td></tr>
<?
}
$i=0;
$oRs2->SearchBypersonIdDocGroupDsID0($personId,$Maxgroup);
while($oRs2->GetRecord()){
$oDoc2->SearchByKey($oRs2->DocID);
$oDoc2->GetRecord();
$i++;
}
$countdoc=$countdoc+$i;
if($flagshowvalue==1){
if($i!="0"){
?>
<tr><td><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>ผู้ใช้ทั่วไป ::</strong></font></td></tr>
<tr><td> มีรายการหนังสือเข้าที่ยังไม่ได้เปิดอ่าน <? echo $i;?> รายการ</td></tr>
<?
}
}
$oDlp->SearchByGpID(107);
while($oDlp->GetRecord()){
$oDlc->SearchByPsPositionDlpID($personId,$oDlp->DlpID,$Maxgroup);
while($oDlc->GetRecord()){
$oDlp1->SearchByKey($oDlc->DlpID);
$oDlp1->GetRecord();
$oDP->SearchByKey($oDlc->deptId);
$oDP->GetRecord();
$oDlc2->SearchByKey($oDlc->DlcID); $oDlc2->GetRecord();
$oDlp1->SearchByKey($oDlc->DlpID); $oDlp1->GetRecord();
if($oDlp1->DlpPID!="0"){
$DlcPS2=$oDlc2->DlcID;
}else{
$DlcPS2=$oDlc3->SearchDlc2($oDlc->DlcSeq,$oDlp1->DlpPID,$oDlc->deptId);
}
$oDoc->SearchByDlcIDDocGroupPSDlcID2DsID0DrsSendDate($oDlc2->DlcID,$Maxgroup,$DlcPS2);
$i=0;
while($oDoc->GetRecord()){
$i++;
}
$countdoc=$countdoc+$i;
if($flagshowvalue==1){
if($i!="0"){
?>
<tr><td><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>เจ้าหน้าที่สารบรรณ ::</strong></font></td></tr>
<tr><td><? echo " - ".$oDlp1->DlpName;?> <? echo "(".$oDP->deptName.")"; ?></td></tr>
<tr><td> มีรายการหนังสือเข้า <? echo $i;?> รายการ</td></tr>
<?
}
}
}
}
$oDlp2->SearchByGpID(110);
while($oDlp2->GetRecord()){
$oDlc2->SearchByPsPositionDlpID($personId,$oDlp2->DlpID,$Maxgroup);
while($oDlc2->GetRecord()){
$oDlp1->SearchByKey($oDlc2->DlpID);
$oDlp1->GetRecord();
$oDP->SearchByKey($oDlc2->deptId);
$oDP->GetRecord();
$oDlc->SearchByKey($oDlc2->DlcID); $oDlc->GetRecord();
$oDlp1->SearchByKey($oDlc->DlpID); $oDlp1->GetRecord();
if($oDlp1->DlpPID!="0"){
$DlcPS2=$oDlc2->DlcID;
}else{
$DlcPS2=$oDlc2->SearchDlc2($oDlc->DlcSeq,$oDlp1->DlpPID,$oDlc->deptId);
}
$oDoc->SearchByDocGroupDsID2DocIDDlcIDDrsReceiveDlcID2Status2($Maxgroup,$oDlc2->DlcID,$DlcPS2);
$i=0;
while($oDoc->GetRecord()){
$i++;
}
$countdoc=$countdoc+$i;
if($flagshowvalue==1){
if($i!="0"){
?>
<tr><td><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>หัวหน้าสารบรรณ ::</strong></font></td></tr>
<tr><td><? echo " - ".$oDlp1->DlpName;?> <? echo "(".$oDP->deptName.")"; ?></td></tr>
<tr><td> มีรายการหนังสือที่ยังไม่ได้ลงนาม <? echo $i;?> รายการ</td></tr>
<?
}
}
}
}
$oDlp3->SearchByGpID(111);
while($oDlp3->GetRecord()){
$oDlc2->SearchByPsPositionDlpID($personId,$oDlp3->DlpID,$Maxgroup);
while($oDlc2->GetRecord()){
$oDlp1->SearchByKey($oDlc2->DlpID);
$oDlp1->GetRecord();
$oDP->SearchByKey($oDlc2->deptId);
$oDP->GetRecord();
$oDlc->SearchByKey($oDlc2->DlcID); $oDlc->GetRecord();
$oDlp1->SearchByKey($oDlc->DlpID); $oDlp1->GetRecord();
if($oDlp1->DlpPID!="0"){
$DlcPS2=$oDlc2->DlcID;
}else{
$DlcPS2=$oDlc2->SearchDlc2($oDlc->DlcSeq,$oDlp1->DlpPID,$oDlc->deptId);
}
$oDoc->SearchByDocGroupDsID2DocIDDlcIDDrsReceiveDlcID2Status2($Maxgroup,$oDlc2->DlcID,$DlcPS2);
$i=0;
while($oDoc->GetRecord()){
$i++;
}
$countdoc=$countdoc+$i;
if($flagshowvalue==1){
if($i!="0"){
?>
<tr><td><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>หัวหน้าหน่วยงาน ::</strong></font></td></tr>
<tr><td><? echo " - ".$oDlp1->DlpName;?> <? echo "(".$oDP->deptName.")"; ?></td></tr>
<tr><td> มีรายการหนังสือที่ยังไม่ได้ลงนาม <? echo $i;?> รายการ</td></tr>
<?
}
}
}
}
$oDlp4->SearchByGpID(112);
while($oDlp4->GetRecord()){
$oDlc2->SearchByPsPositionDlpID($personId,$oDlp4->DlpID,$Maxgroup);
while($oDlc2->GetRecord()){
$oDlp1->SearchByKey($oDlc2->DlpID);
$oDlp1->GetRecord();
$oDP->SearchByKey($oDlc2->deptId);
$oDP->GetRecord();
$oDlc->SearchByKey($oDlc2->DlcID); $oDlc->GetRecord();
$oDlp1->SearchByKey($oDlc->DlpID); $oDlp1->GetRecord();
if($oDlp1->DlpPID!="0"){
$DlcPS2=$oDlc2->DlcID;
}else{
$DlcPS2=$oDlc2->SearchDlc2($oDlc->DlcSeq,$oDlp1->DlpPID,$oDlc->deptId);
}
$oDoc->SearchByDocGroupDsID2DocIDDlcIDDrsReceiveDlcID2Status2($Maxgroup,$oDlc2->DlcID,$DlcPS2);
$i=0;
while($oDoc->GetRecord()){
$i++;
}
$countdoc=$countdoc+$i;
if($flagshowvalue==1){
if($i!="0"){
?>
<tr><td><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><strong>ผู้อำนวยการ ::</strong></font></td></tr>
<tr><td><? echo " - ".$oDlp1->DlpName;?> <? echo "(".$oDP->deptName.")"; ?></td></tr>
<tr><td> มีรายการหนังสือที่ยังไม่ได้ลงนาม <? echo $i;?> รายการ</td></tr>
<?
}
}
}
}
if($flagshowvalue!=1){
echo $countdoc;
}
if($flagshowvalue==1){ ?>
</table>
</body>
</html>
<? } ?>
|