Viewing file: 2552-05-19-1.0.04-processCourseTableTmp.php (2.42 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?
include_once "../global1.php";
include_once "../../class/clsConnection.php";
include_once "../../class/clsDB.php";
include_once "../class/clsHoldCourseTmp.php";
$oCA = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB_EASS'], $GLOBALS['USER_EASS'], $GLOBALS['PASSWORD_EASS']);
$oHCT = new HoldCourseTmp($oCA);
if($method=="add"){
if($selectFlag==7){
$oHCT->DeleteByClassId($classId);
for($i=0; $i<$cnt; $i++){
if($ttId[$i]) {
$oHCT->AddNew();
$oHCT->holdid=$holdid;
$oHCT->classId=$classId;
$oHCT->ttId=$ttId[$i];
$oHCT->officerId=$officerId[$i];
$oHCT->Save();
}
}
?><script language="javascript1.2">
window.opener.location.href="./courseInProgramTableTmp.php?assid=<?=$assid;?>&acadYear=<?=$acadYear;?>&semester=<?=$semester;?>&startDate=<?=$startDate;?>&endDate=<?=$endDate;?>&closeDate=<?=$closeDate;?>&selectFlag=<?=$selectFlag;?>&isPreAssess=<?=$isPreAssess;?>";
window.close();
</script>
<?
}elseif($selectFlag==8){
$oHCT->DeleteByClassId($classId);
for($i=0; $i<$cnt; $i++){
if($officerId[$i]) {
$oHCT->AddNew();
$oHCT->holdid=$holdid;
$oHCT->classId=$classId;
$oHCT->officerId=$officerId[$i];
$oHCT->Save();
}
}
?><script language="javascript1.2">
window.opener.location.href="./courseInProgramTableTmpF8.php?assid=<?=$assid;?>&acadYear=<?=$acadYear;?>&semester=<?=$semester;?>&startDate=<?=$startDate;?>&endDate=<?=$endDate;?>&closeDate=<?=$closeDate;?>&selectFlag=<?=$selectFlag;?>&isPreAssess=<?=$isPreAssess;?>";
window.close();
</script>
<?
}else{ // flag=6
for($i=0; $i<$cnt; $i++){
if($classId[$i]) {
$oHCT->AddNew();
$oHCT->holdid=$holdid;
$oHCT->classId=$classId[$i];
$oHCT->Save();
}
}
if($edit==1){
echo "<meta http-equiv='refresh' content='0; URL=editDefineSomeCourse.php?defineid=$defineid&acadYear=$acadYear&semester=$semester&noAss=$noAss&startDate=$startDate&endDate=$endDate'>";
}
?>
<script language="javascript1.2">
window.opener.location.href="addDefineSomeCourse.php?assid=<?php echo $assid;?>&acadYear=<?php echo $acadYear;?>&semester=<?php echo $semester;?>&startDate=<?php echo $startDate;?>&endDate=<?php echo $endDate;?>&closeDate=<?php echo $closeDate;?>&selectFlag=<?php echo $selectFlag;?>&isPreAssess=<?=$isPreAssess;?>";
//window.opener.location.reload();
window.close();
</script>
<?
}
} //end if method
?>
|