0001620: Admission
This commit is contained in:
parent
c4b8a3bc29
commit
c2c41ba1a2
@ -76,13 +76,13 @@ $query_builder = TRUE;
|
|||||||
$db['default'] = array(
|
$db['default'] = array(
|
||||||
'dsn' => '',
|
'dsn' => '',
|
||||||
'hostname' => 'apollodec.com',
|
'hostname' => 'apollodec.com',
|
||||||
'username' => 'apollod4_DEV',
|
// 'username' => 'apollod4_DEV',
|
||||||
'password' => 'apollo1234',
|
// 'password' => 'apollo1234',
|
||||||
'database' => 'apollod4_ApolloDECDev',
|
// 'database' => 'apollod4_ApolloDECDev',
|
||||||
|
|
||||||
// 'username' => 'apollod4_SIT',
|
'username' => 'apollod4_SIT',
|
||||||
// 'password' => 'apollosit1234',
|
'password' => 'apollosit1234',
|
||||||
// 'database' => 'apollod4_ApolloDECNEWSIT',
|
'database' => 'apollod4_ApolloDECNEWSIT',
|
||||||
|
|
||||||
// 'username' => 'apollod4_PROD',
|
// 'username' => 'apollod4_PROD',
|
||||||
// 'password' => 'approd!2017',
|
// 'password' => 'approd!2017',
|
||||||
|
|||||||
@ -454,6 +454,9 @@ class Dashboard_Controller extends REST_Controller {
|
|||||||
public function admissionBatch_post(){
|
public function admissionBatch_post(){
|
||||||
$branchId = $this->post('branchId');
|
$branchId = $this->post('branchId');
|
||||||
$univ = $this->post('univ');
|
$univ = $this->post('univ');
|
||||||
|
// print_r($univ);
|
||||||
|
// print_r($branchId);
|
||||||
|
|
||||||
$admissionBatch = $this->dashboard_model->admissionBatch($univ,$branchId);
|
$admissionBatch = $this->dashboard_model->admissionBatch($univ,$branchId);
|
||||||
if ($admissionBatch) {
|
if ($admissionBatch) {
|
||||||
$admissionBatch['status'] = REST_Controller::HTTP_OK;
|
$admissionBatch['status'] = REST_Controller::HTTP_OK;
|
||||||
|
|||||||
@ -893,21 +893,26 @@ $sql="select sum(TotalBalance) as total FROM (select (sum(totalpayable) - sum(to
|
|||||||
public function admissionBatch($univ = null, $branchId = null){
|
public function admissionBatch($univ = null, $branchId = null){
|
||||||
|
|
||||||
|
|
||||||
$sql="SELECT BatchName, BatchDate,University,AdmittedBy,count(*)as count FROM admissions
|
// $sql="SELECT BatchName, BatchDate,University,AdmittedBy,count(*)as count FROM admissions
|
||||||
WHERE CASE WHEN MONTH(curdate()) >= 6 THEN CreatedYear = YEAR(curdate())
|
// WHERE CASE WHEN MONTH(curdate()) >= 6 THEN CreatedYear = YEAR(curdate())
|
||||||
ELSE (CreatedYear = YEAR(curdate()) - 1 AND CreatedMonth >= 6) OR CreatedYear = YEAR(curdate()) END
|
// ELSE (CreatedYear = YEAR(curdate()) - 1 AND CreatedMonth >= 6) OR CreatedYear = YEAR(curdate()) END
|
||||||
|
// and BranchCode ='".$branchId."' and UniversityID ='".$univ."'";
|
||||||
|
|
||||||
|
$sql="SELECT BatchName, BatchDate,University,AdmittedBy,1 as count FROM admissions where CASE WHEN MONTH(curdate())>=6 THEN CreatedYear =
|
||||||
|
concat(YEAR(curdate()), '-',right(YEAR(curdate())+1,2))
|
||||||
|
ELSE CreatedYear = concat(YEAR(curdate())-1,'-' ,right(YEAR(curdate()),2)) END
|
||||||
and BranchCode ='".$branchId."' and UniversityID ='".$univ."'";
|
and BranchCode ='".$branchId."' and UniversityID ='".$univ."'";
|
||||||
|
|
||||||
// if($univ != ''){
|
// if($univ != ''){
|
||||||
// $sql.= " and UniversityID ='".$univ."'";
|
// $sql.= " and UniversityID ='".$univ."'";
|
||||||
// }
|
// }
|
||||||
|
|
||||||
$sql.= " GROUP BY BatchName,AdmittedBy";
|
//$sql.= " GROUP BY BatchName";
|
||||||
|
|
||||||
|
|
||||||
$sql.= " ORDER BY BatchDate DESC";
|
//$sql.= " ORDER BY BatchDate DESC";
|
||||||
|
|
||||||
// print_r($sql); //die();
|
|
||||||
|
|
||||||
|
|
||||||
$ltd=$this->db->query($sql);
|
$ltd=$this->db->query($sql);
|
||||||
@ -919,7 +924,7 @@ and BranchCode ='".$branchId."' and UniversityID ='".$univ."'";
|
|||||||
$results['lList'] = false;
|
$results['lList'] = false;
|
||||||
$results['message'] = 'No record found';
|
$results['message'] = 'No record found';
|
||||||
}
|
}
|
||||||
|
//print_r($sql); die();
|
||||||
return $results;
|
return $results;
|
||||||
}
|
}
|
||||||
//To Filters
|
//To Filters
|
||||||
|
|||||||
@ -2188,6 +2188,7 @@ $REGID='';
|
|||||||
$result['deleteStatus']=false;
|
$result['deleteStatus']=false;
|
||||||
$result['message']="Something went wrong.please try again";
|
$result['message']="Something went wrong.please try again";
|
||||||
}
|
}
|
||||||
|
print_r($this->db->last_query());die();
|
||||||
return $result;
|
return $result;
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -60,6 +60,8 @@ group by sid,sem) as apdate on apdate.sid=sms.sid and apdate.sem=sms.sem
|
|||||||
|
|
||||||
$leadDet=$this->db->query($sql);
|
$leadDet=$this->db->query($sql);
|
||||||
$statusDetails = $leadDet->result();
|
$statusDetails = $leadDet->result();
|
||||||
|
//print_r($this->db->last_query());die();
|
||||||
|
|
||||||
if (count($statusDetails) > 0) {
|
if (count($statusDetails) > 0) {
|
||||||
$results['statusList'] = true;
|
$results['statusList'] = true;
|
||||||
$results['statusr'] = $statusDetails;
|
$results['statusr'] = $statusDetails;
|
||||||
@ -612,8 +614,9 @@ where STU.IsActive = '1' and APFS.ID in (select max(ID) from T_ApplicationFormS
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$sql.="and STU_COUR.IsActive='1'";
|
$sql.=" and STU_COUR.IsActive='1'";
|
||||||
$sql.="and STU.BranchCode='".$br."'";
|
$sql.=" and STU.BranchCode='".$br."'";
|
||||||
|
$sql.=" and sfs.FeesID IS not null";
|
||||||
$sql.=" group by regid,Student_id,RD.CourseID,Sem_Year ";
|
$sql.=" group by regid,Student_id,RD.CourseID,Sem_Year ";
|
||||||
$sql.=" ORDER BY StatusUpdationOn,InitialPayDate ASC ";
|
$sql.=" ORDER BY StatusUpdationOn,InitialPayDate ASC ";
|
||||||
|
|
||||||
|
|||||||
@ -897,82 +897,85 @@ app.controller('dashboardCtrl', ["$scope", "$rootScope", "toaster", "$filter", "
|
|||||||
columns: ['TrackingId', 'name', 'mobileNo', 'course', 'university', 'activity', 'AssignTo', 'FollowUpDate', 'status']
|
columns: ['TrackingId', 'name', 'mobileNo', 'course', 'university', 'activity', 'AssignTo', 'FollowUpDate', 'status']
|
||||||
};
|
};
|
||||||
//Admissions batch
|
//Admissions batch
|
||||||
var AdmissionsBatch = {
|
// var AdmissionsBatch = {
|
||||||
method: 'POST',
|
// method: 'POST',
|
||||||
url: apiPoint.url + 'admissionBatch/',
|
// url: apiPoint.url + 'admissionBatch/',
|
||||||
headers: {
|
// headers: {
|
||||||
'Content-Type': 'application/json'
|
// 'Content-Type': 'application/json'
|
||||||
},
|
// },
|
||||||
data: {
|
// data: {
|
||||||
requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
// requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
||||||
branchId: JSON.parse(localStorage.getItem('localObj')).localBranchID,
|
// branchId: JSON.parse(localStorage.getItem('localObj')).localBranchID,
|
||||||
univ: $scope.filters.univ
|
// univ: $scope.filters.univ
|
||||||
|
|
||||||
}
|
// }
|
||||||
};
|
// };
|
||||||
//var gridData = 0;
|
//var gridData = 0;
|
||||||
$http(AdmissionsBatch).then(function (response) {
|
// $http(AdmissionsBatch).then(function (response) {
|
||||||
if (response.data.lList == true) {
|
// console.log(response);
|
||||||
$scope.fbselect = false;
|
// if (response.data.lList == true) {
|
||||||
$scope.adBatch = response.data.l_data;
|
// $scope.fbselect = false;
|
||||||
for (var i = 0; i < $scope.adBatch.length; i++)
|
// $scope.adBatch = response.data.l_data;
|
||||||
$scope.adBatch[i].Sl_No = i + 1;
|
// for (var i = 0; i < $scope.adBatch.length; i++)
|
||||||
// var gridData = $scope.adBatch;
|
// $scope.adBatch[i].Sl_No = i + 1;
|
||||||
$scope.adb = false;
|
// // var gridData = $scope.adBatch;
|
||||||
//console.log($scope.adBatch);
|
// $scope.adb = false;
|
||||||
$scope.adBatchgrid = {
|
// //console.log($scope.adBatch);
|
||||||
|
// $scope.adBatchgrid = {
|
||||||
|
|
||||||
allowSortingBySummary: true,
|
// allowSortingBySummary: true,
|
||||||
allowSorting: true,
|
// allowSorting: true,
|
||||||
allowFiltering: true,
|
// allowFiltering: true,
|
||||||
height: 440,
|
// height: 440,
|
||||||
showBorders: true,
|
// showBorders: true,
|
||||||
fieldChooser: {
|
// fieldChooser: {
|
||||||
enabled: false
|
// enabled: false
|
||||||
},
|
|
||||||
// scrolling: {
|
|
||||||
// mode: "virtual"
|
|
||||||
// },
|
// },
|
||||||
"export": {
|
// // scrolling: {
|
||||||
enabled: true,
|
// // mode: "virtual"
|
||||||
fileName: "AdmissionsBatch"
|
// // },
|
||||||
|
// "export": {
|
||||||
|
// enabled: true,
|
||||||
|
// fileName: "AdmissionsBatch"
|
||||||
|
|
||||||
},
|
// },
|
||||||
dataSource: {
|
// dataSource: {
|
||||||
fields: [{
|
// fields: [{
|
||||||
caption: "BatchName",
|
// caption: "BatchName",
|
||||||
width: 100,
|
// width: 100,
|
||||||
dataField: "BatchName",
|
// dataField: "BatchName",
|
||||||
area: "row"
|
// area: "row"
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
caption: "AdmittedBy",
|
// caption: "AdmittedBy",
|
||||||
dataField: "AdmittedBy",
|
// dataField: "AdmittedBy",
|
||||||
area: "column"
|
// area: "column"
|
||||||
}, {
|
// }, {
|
||||||
caption: "count",
|
// caption: "count",
|
||||||
dataField: "count",
|
// dataField: "count",
|
||||||
dataType: "number",
|
// dataType: "number",
|
||||||
//summaryType: "sum",
|
// //summaryType: "sum",
|
||||||
width: 100,
|
// width: 100,
|
||||||
area: "data"
|
// area: "data"
|
||||||
}],
|
// }],
|
||||||
store: $scope.adBatch
|
// store: $scope.adBatch
|
||||||
}
|
// }
|
||||||
};
|
// };
|
||||||
} else {
|
// } else {
|
||||||
$scope.adb = true;
|
// $scope.adb = true;
|
||||||
$scope.message = response.data.message;
|
// $scope.message = response.data.message;
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
//function for batch filter
|
//function for batch filter
|
||||||
|
|
||||||
$scope.batchFilter = function () {
|
$scope.batchFilter = function () {
|
||||||
|
|
||||||
|
console.log('hi');
|
||||||
|
|
||||||
$scope.adBatchgrid1 = '';
|
$scope.adBatchgrid1 = '';
|
||||||
//Admissions batch
|
//Admissions batch
|
||||||
@ -989,8 +992,10 @@ app.controller('dashboardCtrl', ["$scope", "$rootScope", "toaster", "$filter", "
|
|||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
//var gridData = 0;
|
//var gridData = 0;
|
||||||
$http(AdmissionsBatch).then(function (response) {
|
$http(AdmissionsBatch).then(function (response) {
|
||||||
|
|
||||||
if (response.data.lList == true) {
|
if (response.data.lList == true) {
|
||||||
$scope.adBatch = '';
|
$scope.adBatch = '';
|
||||||
|
|
||||||
@ -1003,7 +1008,8 @@ app.controller('dashboardCtrl', ["$scope", "$rootScope", "toaster", "$filter", "
|
|||||||
// var gridData = $scope.adBatch;
|
// var gridData = $scope.adBatch;
|
||||||
|
|
||||||
$scope.adb = false;
|
$scope.adb = false;
|
||||||
// console.log($scope.adBatchfilter);
|
|
||||||
|
|
||||||
|
|
||||||
$scope.adBatchgrid1 = {
|
$scope.adBatchgrid1 = {
|
||||||
|
|
||||||
@ -1050,15 +1056,17 @@ app.controller('dashboardCtrl', ["$scope", "$rootScope", "toaster", "$filter", "
|
|||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
$scope.batchFilterClick();
|
// $scope.batchFilterClick();
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
$scope.fbselect = false;
|
$scope.fbselect = false;
|
||||||
$scope.message = response.data.message;
|
$scope.message = response.data.message;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
$scope.batchFilterClick = function () {
|
$scope.batchFilterClick = function ()
|
||||||
$scope.grid.option('dataSource', {
|
{
|
||||||
|
$scope.grid.option('dataSource', {
|
||||||
fields: [{
|
fields: [{
|
||||||
caption: "BatchName",
|
caption: "BatchName",
|
||||||
width: 100,
|
width: 100,
|
||||||
@ -1078,10 +1086,10 @@ app.controller('dashboardCtrl', ["$scope", "$rootScope", "toaster", "$filter", "
|
|||||||
// width: 100,
|
// width: 100,
|
||||||
area: "data"
|
area: "data"
|
||||||
}],
|
}],
|
||||||
store: $scope.adBatchfilter
|
// store: $scope.adBatchfilter
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
////
|
||||||
$scope.foutFilter = function(){
|
$scope.foutFilter = function(){
|
||||||
$scope.fout = '';
|
$scope.fout = '';
|
||||||
var fOut = {
|
var fOut = {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user