application status
This commit is contained in:
parent
872e039bf5
commit
c57d3c23b1
@ -613,48 +613,49 @@ class Studentview_model extends CI_Model
|
||||
|
||||
|
||||
|
||||
$this->db->select('max(t1.CreatedOn) as maxdate');
|
||||
$this->db->from('T_ApplicationFormStatus as t1');
|
||||
$this->db->join('T_Registration_Details as t2', 't2.ID = t1.Registration_Details_ID');
|
||||
$this->db->where('t2.StudentID',$studentid);
|
||||
$this->db->where('t2.CourseID', $courseid);
|
||||
// $subquery = 'select max(ID) from T_ApplicationFormStatus group by Registration_Details_ID';
|
||||
|
||||
$dateres=$this->db->get();
|
||||
|
||||
$dateval = $dateres->result();
|
||||
|
||||
$madate ='';
|
||||
|
||||
foreach($dateval as $va)
|
||||
{
|
||||
$madate = $va->maxdate;
|
||||
}
|
||||
|
||||
// echo $madate;
|
||||
// die();
|
||||
|
||||
|
||||
$this->db->select('t1.ID, t2.BatchCode, t2.FeeType as SemID, CFD.Sem_Year as Sem_Year, t2.RegistrationMode, t2.RegistrationType, t1.AppFormDate as StatusUpdateDate,t3.ListName ,t1.Comments');
|
||||
$this->db->from('T_ApplicationFormStatus as t1');
|
||||
$this->db->join('T_Registration_Details as t2', 't2.ID = t1.Registration_Details_ID');
|
||||
$this->db->join('T_Course_Fees_Details as CFD', 'CFD.ID = t2.FeeType');
|
||||
$this->db->join('' . PICK_LIST_DETAILS . ' as t3', 't3.ListCode = t1.ListCode', 'LEFT');
|
||||
// $this->db->select('t1.ID, t2.BatchCode, t2.FeeType as SemID, CFD.Sem_Year as Sem_Year, t2.RegistrationMode, t2.RegistrationType, t1.AppFormDate as StatusUpdateDate,t3.ListName ,t1.Comments');
|
||||
// $this->db->from('T_ApplicationFormStatus as t1');
|
||||
// $this->db->join('T_Registration_Details as t2', 't2.ID = t1.Registration_Details_ID');
|
||||
// $this->db->join('T_Course_Fees_Details as CFD', 'CFD.ID = t2.FeeType');
|
||||
// $this->db->join('' . PICK_LIST_DETAILS . ' as t3', 't3.ListCode = t1.ListCode', 'LEFT');
|
||||
|
||||
$this->db->where('t2.StudentID', $studentid);
|
||||
$this->db->where('t2.CourseID', $courseid);
|
||||
$this->db->where('t1.CreatedOn',$madate);
|
||||
$fromTypes = $this->db->get();
|
||||
$formTypeDetails = $fromTypes->result();
|
||||
if($formTypeDetails)
|
||||
{
|
||||
return $fromTypes->result();
|
||||
}
|
||||
else
|
||||
{
|
||||
// print_r($formTypeDetails);exit();
|
||||
// $this->db->where('t2.StudentID', $studentid);
|
||||
// $this->db->where('t2.CourseID', $courseid);
|
||||
// $this->db->where('t1.ID ',$subquery);
|
||||
|
||||
// $fromTypes = $this->db->get();
|
||||
// $formTypeDetails = $fromTypes->result();
|
||||
// if($formTypeDetails)
|
||||
// {
|
||||
// return $fromTypes->result();
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// return false;
|
||||
|
||||
// }
|
||||
|
||||
|
||||
|
||||
$subquery='SELECT t1.ID, t2.BatchCode, t2.FeeType as SemID, CFD.Sem_Year as Sem_Year,t2.RegistrationMode,t2.RegistrationType,t1.AppFormDate as StatusUpdateDate, t3.ListName,t1.Comments FROM T_ApplicationFormStatus as t1 JOIN T_Registration_Details as t2 ON t2.ID = t1.Registration_Details_ID JOIN T_Course_Fees_Details as CFD ON CFD.ID = t2.FeeType LEFT JOIN T_PickListDetails as t3 ON t3.ListCode = t1.ListCode WHERE t2.StudentID =? AND t2.CourseID = ? and t1.ID in (select max(ID) from T_ApplicationFormStatus group by Registration_Details_ID)';
|
||||
|
||||
$query = $this->db->query($subquery,array($studentid,$courseid));
|
||||
|
||||
$fromTypes = $query->result();
|
||||
|
||||
if(count($query)>0)
|
||||
{
|
||||
return $fromTypes;
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
return false;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -304,7 +304,7 @@
|
||||
|
||||
</tab>
|
||||
|
||||
<!-- {{course.applicationDetails}} -->
|
||||
<!-- {{course.applicationDetails}} -->
|
||||
<tab heading="Application Details" id="application">
|
||||
<div class="panel-scroll ng-scope ps-container ps-theme-default ps-active-y" perfect-scrollbar="" data-ps-id="6fc3054c-6292-144d-eff7-cd557f527468">
|
||||
<div ng-if="course.applicationDetails==false">
|
||||
@ -330,7 +330,7 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr ng-repeat="apps in course.applicationDetails | unique:'CertificateName'">
|
||||
<tr ng-repeat="apps in course.applicationDetails">
|
||||
<!-- <td>
|
||||
<span>{{apps.CertificateName}}</span>
|
||||
</td>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user