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 : 3.141.19.115
<?php
function savevacantseats($aobj_context)
{
$mobile = $_SESSION['MOBILE'];
$vacant_seat = $aobj_context->mobj_data["vacant_seat"];
$enhanced_quota = $aobj_context->mobj_data["enhanced_quota"];
$managment_quota = $aobj_context->mobj_data["managment_quota"];
if($mobile == '')
{
$data = 'Login and try';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
return;
}
$query = "select * From entstudadm s inner join entoptdeg od on s.fappno = od.fappno
inner join entdeg d on od.fdegree = d.fdegree
where s.fmobileno = '{$mobile}'
and ifnull(flock,'') = 'T'";
$result = $aobj_context->mobj_db->GetRow($query);
if($result)
{
$data = 'Reisration is over';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
return;
}else
{
}
$query = "delete from entstudint where fmobile = '{$mobile}'";
$res1 = $aobj_context->mobj_db->Execute($query);
$query = "insert into entstudint (fmobile,fvacant,fenhanced,fmanagment,finterested)
values ('{$mobile}','{$vacant_seat}','{$enhanced_quota}','{$managment_quota}','F')";
$result = $aobj_context->mobj_db->Execute($query);
if($result){
$data = 'Saved';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,0,"success");
}else{
$data = 'Failed';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
}
}
function notintsavevacantseats($aobj_context)
{
$mobile = $_SESSION['MOBILE'];
if($mobile == '')
{
$data = 'Login and try';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
return;
}
$query = "select * From entstudadm s inner join entoptdeg od on s.fappno = od.fappno
inner join entdeg d on od.fdegree = d.fdegree
where s.fmobileno = '{$mobile}'
and ifnull(flock,'') = 'T'";
$result = $aobj_context->mobj_db->GetRow($query);
if($result)
{
$data = 'Reisration is over';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
return;
}else
{
}
$query = "delete from entstudint where fmobile = '{$mobile}'";
$res1 = $aobj_context->mobj_db->Execute($query);
$query = "insert into entstudint (fmobile,fvacant,fenhanced,fmanagment,finterested)
values ('{$mobile}','No','No','No','T')";
$result = $aobj_context->mobj_db->Execute($query);
if($result){
$data = 'Saved';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,0,"success");
}else{
$data = 'Failed';
echo $aobj_context->mobj_output->ToJSONEnvelope($data,-1,"failure");
}
}
?>
|