course add in doc
This commit is contained in:
parent
789336251d
commit
a3506dae4c
@ -219,6 +219,8 @@ $route['updateCourseDetailss'] = 'DataCorrection_Controller/updateCourseDetailss
|
||||
|
||||
$route['getStudentAllInfo'] = 'DayBook_Controller/getStudentAllInfo';
|
||||
|
||||
$route['getCourse'] = 'Student_Controller/getCourse';
|
||||
|
||||
|
||||
/*
|
||||
|
||||
|
||||
@ -274,6 +274,7 @@ class Student_Controller extends REST_Controller {
|
||||
$reqData['Status'] = $updateDetails['checkTracking'];
|
||||
$reqData['StatusName'] = "PENDING";
|
||||
$reqData['CreatedBy'] = $localdata['localUserID'];
|
||||
$reqData['CourseID'] = $updateDetails['CourseID'];
|
||||
$date = date('Y-m-d H:i:s');
|
||||
$reqData['CreatedOn'] = $date;
|
||||
$addStudentPendingDocDetails = $this->student_model->addStu_PendingDoc_Details($reqData, $localdata);
|
||||
@ -644,4 +645,28 @@ class Student_Controller extends REST_Controller {
|
||||
$this->response(['message' => 'No users were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public function getCourse_post()
|
||||
{
|
||||
$data = $this->post('data');
|
||||
|
||||
$localBranchID =$data['localBranchID'];
|
||||
|
||||
$getcourselist= $this->student_model->get_All_Course($localBranchID);
|
||||
|
||||
if ($getcourselist) {
|
||||
$getcourselist['status'] = REST_Controller::HTTP_OK;
|
||||
// Set the response and exit
|
||||
$this->response($getcourselist, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code
|
||||
} else {
|
||||
// Set the response and exit
|
||||
$this->response(['message' => 'No users were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -1325,8 +1325,9 @@ class Student_model extends CI_Model {
|
||||
$localBranch = $localData['localBranchID'];
|
||||
|
||||
$this->db->select('*');
|
||||
$this->db->order_by('CreatedOn', 'DESC');
|
||||
$this->db->order_by('T_Student_DocumentTrack_Details.CreatedOn', 'DESC');
|
||||
$this->db->from(STUDENTDOCUMENTTRACKDETAILS);
|
||||
$this->db->join('T_CourseMaster','T_CourseMaster.CourseID=T_Student_DocumentTrack_Details.CourseID','left');
|
||||
$this->db->where('StudentID', $stuID);
|
||||
$getPendDocDetails = $this->db->get();
|
||||
$documentPendingDetails = $getPendDocDetails->result();
|
||||
@ -1342,6 +1343,10 @@ class Student_model extends CI_Model {
|
||||
|
||||
// add student enrollment pending document details
|
||||
public function addStu_PendingDoc_Details($reqData, $localdata) {
|
||||
|
||||
|
||||
//print_r($reqData);die();
|
||||
|
||||
$this->db->insert(STUDENTDOCUMENTTRACKDETAILS, $reqData);
|
||||
if ($this->db->affected_rows() > 0) {
|
||||
// Entry for call track
|
||||
@ -1715,4 +1720,35 @@ class Student_model extends CI_Model {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function get_All_Course($localBranchID)
|
||||
{
|
||||
$this->db->select('CourseID,T_CourseMaster.CourseCode,CourseName,T_CourseMaster.UniversityID,UniversityName');
|
||||
$this->db->from('T_CourseMaster');
|
||||
$this->db->join('T_UniversityMaster','T_UniversityMaster.UniversityID=T_CourseMaster.UniversityID');
|
||||
$this->db->where('T_CourseMaster.BranchCode',$localBranchID);
|
||||
$this->db->order_by('UniversityID','asc');
|
||||
|
||||
$courseDetails = $this->db->get();
|
||||
|
||||
if($courseDetails->result())
|
||||
{
|
||||
|
||||
//print_r($searchDetails->result());
|
||||
$result_array['feeStatus'] = true;
|
||||
$result_array['details'] = $courseDetails->result();
|
||||
}
|
||||
else
|
||||
{
|
||||
$result_array['feeStatus'] = false;
|
||||
$result_array['details'] = "No records found!";
|
||||
}
|
||||
|
||||
// print_r($this->db->last_query());die();
|
||||
|
||||
return $result_array;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -72,6 +72,30 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
|
||||
}
|
||||
|
||||
|
||||
var allcourse = {
|
||||
|
||||
method: 'POST',
|
||||
url: apiPoint.url + 'getCourse/',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
data: {
|
||||
data: localDetails
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
$http(allcourse).then(function (response) {
|
||||
if (response.data.details) {
|
||||
$scope.allcourselist = response.data.details;
|
||||
// console.log($scope.allcourselist)
|
||||
} else {
|
||||
$scope.employeeList = '';
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
@ -1252,12 +1276,17 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
|
||||
$scope.myModelAddPendingDocDetails = {
|
||||
"documentDetails": "",
|
||||
"documentdate":"",
|
||||
"course":"",
|
||||
"checkTracking": false
|
||||
}
|
||||
$scope.documentTrackAddDetailsLoading = false;
|
||||
|
||||
$scope.studentEntrollPendingDocFORM = {
|
||||
submit: function (form, myModelAddPendingDocDetails, stuID) {
|
||||
|
||||
|
||||
// alert('in');
|
||||
// return false;
|
||||
var firstError = null;
|
||||
if (form.$invalid) {
|
||||
var field = null, firstError = null;
|
||||
@ -1281,6 +1310,7 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
|
||||
"student": stuID,
|
||||
"doc_Details": myModelAddPendingDocDetails.documentDetails,
|
||||
"checkTracking": myModelAddPendingDocDetails.checkTracking,
|
||||
"CourseID":myModelAddPendingDocDetails.course,
|
||||
"documentdate": $filter('date')(new Date($scope.docFollowupDate),'dd-MM-yyyy')
|
||||
};
|
||||
var updateStudentPendingDocDetails = {
|
||||
@ -1300,6 +1330,7 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
|
||||
$scope.documentTrackAddDetailsLoading = false;
|
||||
$scope.myModelAddPendingDocDetails = {
|
||||
"documentDetails": "",
|
||||
"course":"",
|
||||
"checkTracking": false
|
||||
}
|
||||
form.$setPristine(true);
|
||||
@ -1311,8 +1342,12 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
|
||||
}
|
||||
},
|
||||
reset: function (form) {
|
||||
|
||||
// alert('reset')
|
||||
// return false;
|
||||
$scope.myModelAddPendingDocDetails = {
|
||||
"documentDetails": "",
|
||||
"course":"",
|
||||
"checkTracking": false
|
||||
}
|
||||
}
|
||||
@ -1490,10 +1525,13 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
var localDetails = ipCookie('cookiechk');
|
||||
$scope.localBranchDetails = "";
|
||||
$scope.loader = false;
|
||||
$scope.allcourselist ='';
|
||||
$scope.che='abc';
|
||||
|
||||
$scope.viewStudentDetailsPage = false;
|
||||
// load when html page load
|
||||
$scope.init = function () {
|
||||
$scope.che='123';
|
||||
$scope.localUserType = localDetails.localType;
|
||||
if (localDetail != null) {
|
||||
if (localDetails.localType === 'R004') {
|
||||
@ -1505,6 +1543,33 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
}
|
||||
} else {
|
||||
}
|
||||
|
||||
|
||||
var allcourse = {
|
||||
|
||||
method: 'POST',
|
||||
url: apiPoint.url + 'getCourse/',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
data: {
|
||||
data: localDetails
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
$http(allcourse).then(function (response) {
|
||||
if (response.data.details) {
|
||||
$scope.allcourselist = response.data.details;
|
||||
// console.log($scope.allcourselist)
|
||||
} else {
|
||||
$scope.employeeList = '';
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -2831,6 +2896,7 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
|
||||
$scope.myModelAddPendingDocDetails = {
|
||||
"documentDetails": "",
|
||||
"course":"",
|
||||
"checkTracking": false
|
||||
}
|
||||
|
||||
@ -2838,6 +2904,10 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
|
||||
$scope.studentEntrollPendingDocFORM = {
|
||||
submit: function (form, myModelAddPendingDocDetails, stuID) {
|
||||
|
||||
//console.log(myModelAddPendingDocDetails)
|
||||
// alert('in');
|
||||
// return false;
|
||||
var firstError = null;
|
||||
if (form.$invalid) {
|
||||
var field = null, firstError = null;
|
||||
@ -2862,6 +2932,7 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
"student" : stuID,
|
||||
"doc_Details": myModelAddPendingDocDetails.documentDetails,
|
||||
"checkTracking": myModelAddPendingDocDetails.checkTracking,
|
||||
"CourseID":myModelAddPendingDocDetails.course,
|
||||
"documentdate" :$filter('date')(new Date($scope.docFollowupDate),'dd-MM-yyyy')
|
||||
};
|
||||
var updateStudentPendingDocDetails = {
|
||||
@ -2894,6 +2965,7 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
|
||||
reset: function (form) {
|
||||
$scope.myModelAddPendingDocDetails = {
|
||||
"documentDetails": "",
|
||||
"course":"",
|
||||
"checkTracking": false
|
||||
}
|
||||
}
|
||||
|
||||
@ -598,7 +598,25 @@
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-2 form-group">
|
||||
<!-- {{che}} -->
|
||||
|
||||
<div class="col-md-4" >
|
||||
<label for="form-field-select-2">Course</label>
|
||||
|
||||
<select class="form-control" tabindex="3" class="cs-select cs-skin-elastic" name="course" ng-model="myModelAddPendingDocDetails.course">
|
||||
|
||||
<option value="" selected>Select Course</option>
|
||||
<option ng-repeat="item in allcourselist" value="{{item.CourseID}}">{{item.CourseName}}-{{item.CourseCode}} ({{item.UniversityName}}) </option>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-4 form-group">
|
||||
<label>
|
||||
Track Status
|
||||
</label>
|
||||
@ -646,6 +664,7 @@
|
||||
<tr>
|
||||
<th>Detail</th>
|
||||
<th>Follow_Up_Date</th>
|
||||
<th>Course</th>
|
||||
<th>Status</th>
|
||||
<th class="center">Delete</th>
|
||||
</tr>
|
||||
@ -658,6 +677,7 @@
|
||||
<span ng-if="penddoc.Status == 1">Open</span>
|
||||
<span ng-if="penddoc.Status == 0">Close</span>
|
||||
</td>-->
|
||||
<td>{{penddoc.CourseName}}</td>
|
||||
<td>
|
||||
{{penddoc.StatusName | ucfirst}}
|
||||
</td>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user