0xV3NOMx
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 : 18.226.186.109


Current Path : /var/www/html/collportal/src/
Upload File :
Current File : //var/www/html/collportal/src/studentsem.php

<?php
function studentsemester($aobj_context){
   
    $univcode = $aobj_context->mobj_data["univcode"];
    $type = $aobj_context->mobj_data["type"];
    $collcode = $aobj_context->mobj_data["collcode"];
    $degree_code=trim($aobj_context->mobj_data["degree_range"]);

    $query="SELECT IFNULL(fdescpn,'')AS VALUE,  CONCAT(IFNULL(fdescpn,''), ' ', '[',IFNULL(fdeggrp,''),']') AS label FROM deggrp";
//   var_dump($query);
//   die();
      $result = $aobj_context->mobj_db->getAll($query);
  
         if($result){
           echo $aobj_context->mobj_output->ToJSONEnvelope($result,0,"success"); 
         }else{
           $arr['msg']='Failed to Load';
           echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"failure");
           return;
         }
}

function studentsemdeg($aobj_context){
    // var_dump("ffhgg");
    // die();
    $univcode = $aobj_context->mobj_data["univcode"];
    $type = $aobj_context->mobj_data["type"];
    $collcode = $aobj_context->mobj_data["collcode"];
    $degree_code=trim($aobj_context->mobj_data["degree_range"]);

    $query1="SELECT IFNULL(fdegree, '') AS VALUE,CONCAT(IFNULL(fdescpn, ''), ' ', '[', IFNULL(fdegree, ''), ']') AS label
FROM degree";
    // var_dump($query);
    // die();
   
   
      $result = $aobj_context->mobj_db->getAll($query1);
    //       var_dump($result);
    // die();
   
         if($result){
           echo $aobj_context->mobj_output->ToJSONEnvelope($result,0,"success"); 
         }else{
           $arr['msg']='Failed to Load';
           echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"failure");
           return;
         }
}

function studentsemexam($aobj_context){
    // var_dump("ffhgg");
    // die();
    $univcode = $aobj_context->mobj_data["univcode"];
    $type = $aobj_context->mobj_data["type"];
    $collcode = $aobj_context->mobj_data["collcode"];
    $degree_code=trim($aobj_context->mobj_data["degree_range"]);

    $query2="SELECT IFNULL(fexamno, '') AS VALUE,CONCAT(IFNULL(fexamname, ''), ' ', '[', IFNULL(fexamno, ''), ']') AS label
FROM degree GROUP BY fexamno";
    // var_dump($query);
    // die();
   
   
      $result = $aobj_context->mobj_db->getAll($query2);
    //       var_dump($result);
    // die();
   
         if($result){
           echo $aobj_context->mobj_output->ToJSONEnvelope($result,0,"success"); 
         }else{
           $arr['msg']='Failed to Load';
           echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"failure");
           return;
         }
}

function studentsemsave($aobj_context){
    // var_dump("sana");
    // die();
    $collcode = $aobj_context->mobj_data["collcode"];

    $univcode = $aobj_context->mobj_data["univcode"];
    $degree = $aobj_context->mobj_data["degree"];
    // var_dump($degree);
    // die();
    $degree= $aobj_context->mobj_data["dept"];
    $regNoStart=$aobj_context->mobj_data["regNoStart"]; 
    // var_dump($regNoStart);
    // die(); 
   $regNoEnd=$aobj_context->mobj_data["regNoEnd"];
//    var_dump($regNoEnd);
//    die();
  
   $sem=$aobj_context->mobj_data["sem"];
  
  
    $query1="select s.fregno as FREGNO,s.FPHOTOPATH,s.FDEGREE,s.FNAME, c.FUNIVCODE from student s, control c 
      where s.fcollcode = '{$collcode}' and s.fdegree ='{$degree}'
      and s.fregno between '{$regNoStart}' and '{$regNoEnd}' 
      order by s.fregno";   
    // var_dump($query1); 
    // die();              
     
   
  $result = $aobj_context->mobj_db->getAll($query1);
//    var_dump($result); 
//     die();
         
  
  if($result){
  echo $aobj_context->mobj_output->ToJSONEnvelope($result,0,"success"); 
  }else{
    $arr['msg']='Failed to Load'; 
  echo $aobj_context->mobj_output->ToJSONEnvelope($arr,0,"failure");  
    return; 
  }
            
  }
  

?>