Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64
Your IP : 52.15.70.0
<?php
function getdropdown($aobj_context)
{
$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
$query1 = "SELECT fcatid AS internal_code, CONCAT(fcatdespn) AS value from mascat order by forder";
$result1 = $aobj_context->mobj_db->GetAll($query1);
$arr['catcode']=$result1;
$query2 = "SELECT fdegncode AS internal_code, fdegndesc AS value from masdegn where ifnull(fdeleted,'') <> 'T'";
$result2=$aobj_context->mobj_db->GetAll($query2);
$arr['post']=$result2;
$query3 = "SELECT fdegree AS internal_code, fdescpn AS value from mascourse
where ifnull(fdeleted,'') <> 'T'";
$result3=$aobj_context->mobj_db->GetAll($query3);
$arr['course']=$result3;
$query4 = "SELECT fdegree AS internal_code, fdescpn AS value from mascourse
WHERE ffaculty = 'UG' and ifnull(fdeleted,'') <> 'T'";
$result4 = $aobj_context->mobj_db->GetAll($query4);
$arr['UG']=$result4;
$query5 = "SELECT fdegree AS internal_code, fdescpn AS value from mascourse
WHERE ffaculty = 'PG' and ifnull(fdeleted,'') <> 'T'";
$result5=$aobj_context->mobj_db->GetAll($query5);
$arr['PG']=$result5;
echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"success");
}
function getdepartment($aobj_context)
{
$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
$postappiled = trim($aobj_context->mobj_data["postappiled"]);
$postapp = trim($aobj_context->mobj_data["postapp"]);
if($postappiled == 'A')
{
$str = "ifnull(fassistant,'') = 'T'";
}
if($postappiled == 'S')
{
$str = "ifnull(fassociate,'') = 'T'";
}
if($postappiled == 'P')
{
$str = "ifnull(fprofessor,'') = 'T'";
}
$query3 = "SELECT fdegree AS internal_code, fdescpn AS value from mascourse
where {$str} order by fdescpn";
$result3=$aobj_context->mobj_db->GetAll($query3);
$arr['course']=$result3;
echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"success");
}
function getwithvacdepartment($aobj_context)
{
$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
$postapp = trim($aobj_context->mobj_data["postapp"]);
if($postapp == 'Reserved Vacancies(But not filled / Backlog)')
{
$str = "ifnull(fvacancies,'') = 'T'";
}else
{
$str = "IFNULL(fassistant,'') = 'T'";
}
$query3 = "SELECT fdegree AS internal_code, fdescpn AS value from mascourse
where {$str}";
//var_dump($query3);
$result3=$aobj_context->mobj_db->GetAll($query3);
$arr['course']=$result3;
echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"success");
}
function loadresearch($aobj_context)
{
$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
$query1 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC01'
order by forder";
$result1 = $aobj_context->mobj_db->GetAll($query1);
$arr['RC01']=$result1;
$query2 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC02'
order by forder";
$result2=$aobj_context->mobj_db->GetAll($query2);
$arr['RC02']=$result2;
$query3 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC03'
order by forder";
$result3 =$aobj_context->mobj_db->GetAll($query3);
$arr['RC03'] = $result3;
$query4 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC04'
order by forder";
$result4 = $aobj_context->mobj_db->GetAll($query4);
$arr['RC04']=$result4;
$query5 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC05'
order by forder";
$result5=$aobj_context->mobj_db->GetAll($query5);
$arr['RC05']=$result5;
$query6 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC06'
order by forder";
$result6 =$aobj_context->mobj_db->GetAll($query6);
$arr['RC06']=$result6;
$query7 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC07'
order by forder";
$result7=$aobj_context->mobj_db->GetAll($query7);
$arr['RC07']=$result7;
$query8 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC08'
order by forder";
$result8=$aobj_context->mobj_db->GetAll($query8);
$arr['RC08']=$result8;
$query9 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC09'
order by forder";
$result9=$aobj_context->mobj_db->GetAll($query9);
$arr['RC09']=$result9;
$query10 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC10'
order by forder";
$result10=$aobj_context->mobj_db->GetAll($query10);
$arr['RC10']=$result10;
echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"success");
}
function loadresearch2($aobj_context)
{
$aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
$query1 = "select freasoncode AS internal_code, freasonname AS value,fscreen
from reason where fscreen like 'RC2%'
order by forder";
$result1 = $aobj_context->mobj_db->GetAll($query1);
$arr['RC01']=$result1;
$query2 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC02'
order by forder";
$result2=$aobj_context->mobj_db->GetAll($query2);
$arr['RC02']=$result2;
$query3 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC03'
order by forder";
$result3 =$aobj_context->mobj_db->GetAll($query3);
$arr['RC03'] = $result3;
$query4 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC04'
order by forder";
$result4 = $aobj_context->mobj_db->GetAll($query4);
$arr['RC04']=$result4;
$query5 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC05'
order by forder";
$result5=$aobj_context->mobj_db->GetAll($query5);
$arr['RC05']=$result5;
$query6 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC06'
order by forder";
$result6 =$aobj_context->mobj_db->GetAll($query6);
$arr['RC06']=$result6;
$query7 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC07'
order by forder";
$result7=$aobj_context->mobj_db->GetAll($query7);
$arr['RC07']=$result7;
$query8 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC08'
order by forder";
$result8=$aobj_context->mobj_db->GetAll($query8);
$arr['RC08']=$result8;
$query9 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC09'
order by forder";
$result9=$aobj_context->mobj_db->GetAll($query9);
$arr['RC09']=$result9;
$query10 = "SELECT freasoncode AS internal_code, freasonname AS value
from reason where fscreen = 'RC10'
order by forder";
$result10=$aobj_context->mobj_db->GetAll($query10);
$arr['RC10']=$result10;
echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"success");
}
?>
|