status updation screen Course details Updates : kdk

This commit is contained in:
resicovenba 2018-02-20 10:34:38 +05:30
parent 27324bae40
commit cca0b0388d
13 changed files with 2216 additions and 1632 deletions

View File

@ -129,6 +129,9 @@ $route['updateStudentImgDetails'] = 'Student_Controller/updateStudentImgDetails'
$route['getBranchListDetails'] = 'Student_Controller/getBranchListDetails';
$route['getBranchActiveStatusforStuAdd'] = 'Student_Controller/getBranchActiveStatusforStuAdd';
$route['getExistingStudentDetails'] = 'Student_Controller/getExistingStudentDetails';
$route['addStudentEntrollDocDetails'] = 'Student_Controller/addStudentEntrollDocDetails';
$route['getListofStuDocDetails'] = 'Student_Controller/getListofStuDocDetails';
$route['deleteStuDocDetails'] = 'Student_Controller/deleteStuDocDetails';
//batch
$route['addBatchDetails'] = 'Batch_Controller/addBatchDetails';

View File

@ -222,6 +222,101 @@ class Student_Controller extends REST_Controller {
}
}
// get student entrollment document details
public function getListofStuDocDetails_post() {
$StudentID = $this->post('exceptId');
$localdata = $this->post('localData');
$studentDocDetails = $this->student_model->getStudent_doc_details($StudentID);
if ($studentDocDetails)
{
$studentDocDetails['status'] = REST_Controller::HTTP_OK;
// Set the response and exit
$this->response($studentDocDetails, 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
}
}
public function deleteStuDocDetails_post() {
$StudentID = $this->post('exceptId');
$docEntryId = $this->post('docDetailsID');
$localdata = $this->post('localData');
$stuDocDeleteDetails = $this->student_model->deleteStu_doc_details($StudentID, $docEntryId);
if ($stuDocDeleteDetails)
{
$stuDocDeleteDetails['status'] = REST_Controller::HTTP_OK;
// Set the response and exit
$this->response($stuDocDeleteDetails, 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
}
}
public function addStudentEntrollDocDetails_post() {
// echo $this->post('stuDocProof_Status');exit();
$docName = $_FILES['stuDocProof']['name'] ;
$docsize = $_FILES['stuDocProof']['size'] ;
$docSource = $_FILES['stuDocProof']['tmp_name'];
$temp= $this->post('data');
$data = json_decode($temp, true);
$updatedBy = $this->post('updatedBy');
$studentId = $this->post('studentID');
$doc_upload_status = $this->post('stuDocProof_Status');
$req['doc_name'] = $docName;
$req['doc_size'] = $docsize;
$req['doc_source'] = $docSource;
$req['document_type_name'] = $data['documentName'];
$req['document_status'] = '';
$req['document_comments'] = $data['documentComments'];
$req['student_id'] = $studentId;
$req['CreatedBy'] = $updatedBy;
$date = date('Y-m-d H:i:s');
$req['CreatedOn'] = $date;
$studentEntrollDocAdd = $this->student_model->student_entroll_doc_add( $req, $doc_upload_status);// Check if the employee exist
if ($studentEntrollDocAdd)
{
$studentEntrollDocAdd['status'] = REST_Controller::HTTP_OK;
// Set the response and exit
$this->response($studentEntrollDocAdd, 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
}
// print_r($temp);
// echo $docName, $studentId, $data['documentName'];
// exit();
}
public function updateStudentImgDetails_post() {
$imagename = $_FILES['idStuUpProof']['name'];

View File

@ -54,19 +54,16 @@ class StatusUpdation_model extends CI_Model
}
public function get_couser_name($cours) {
$this->db->select('t2.CourseName');
// $this->db->from('' . COURSE_FEES . ' as t1');
$this->db->from('' . COURSE . ' as t2');
$this->db->where('t2.CourseID', $cours);
$roleDetails = $this->db->get()->first_row();
return "$roleDetails->CourseName";
}
// update Application status
public function update_applicationStatus($arr,$reqDetails) {
$this->db->insert_batch(APPLICATION_STATUS, $arr);
if ($this->db->affected_rows() >= 1) {
if($this->get_ListCode_status($arr[0]['ListCode'])){
@ -251,7 +248,6 @@ class StatusUpdation_model extends CI_Model
$results['message'] = 'No record found';
}
}
return $results;
}
@ -274,8 +270,6 @@ class StatusUpdation_model extends CI_Model
// update answer booklet status
public function update_answerbooklet($arr,$reqDetails) {
// print_r($arr);exit();
$this->db->insert_batch(ANSWER_BOOKLET, $arr);
if ($this->db->affected_rows() >= 1) {
@ -291,7 +285,6 @@ class StatusUpdation_model extends CI_Model
}
public function get_couser_sem_yr_msg($cours) {
$this->db->select('t1.Sem_Year, t2.CourseName');
$this->db->from('' . COURSE_FEES . ' as t1');
$this->db->join('' . COURSE . ' as t2', 't2.CourseID = t1.CourseID', 'LEFT');
@ -335,52 +328,102 @@ class StatusUpdation_model extends CI_Model
SFS.CourseID = '$reqData'
AND SFS.StudentID = '$stuFor'";
// AND CF.ProgramType ='Y001'";
$queryDetails = $this->db->query($subQuery);
$results['semYearResult'] = true;
$results['semYear_result_details'] = $queryDetails->result();
return $results;
}
// get serach result
public function get_search_result($reqData, $req) {
// print_r($reqData['University']);
// print_r($req);
// exit();
$University = $reqData['University'];
$Course = $reqData['Course'];
$Batch = $reqData['Batch'];
$branch = $req['localBranchID'];
if( $branch == 'All' ) {
$subQuery = "SELECT S.* , SC.CourseID , C.CourseName , U.UniversityName
// echo $University;
// echo $branch
if($University != '' && $Course == '' && $Batch == '') {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName , C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
(SC.UniversityID = '$University'
OR (SC.CourseID = '$Course' AND SC.UniversityID = '$University')
OR (SC.BatchCode = '$Batch' AND SC.CourseID = '$Course' AND SC.UniversityID = '$University'))
SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
} else {
// echo $University;
// echo $branch;
$subQuery = "SELECT S.* , SC.CourseID , C.CourseName , U.UniversityName
} else if ($University != '' && $Course != '' && $Batch == '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName , C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
(SC.UniversityID = '$University'
OR (SC.CourseID = '$Course' AND SC.UniversityID = '$University')
OR (SC.BatchCode = '$Batch' AND SC.CourseID = '$Course' AND SC.UniversityID = '$University'))
SC.CourseID = '$Course' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
} else if ( $University != '' && $Course == '' && $Batch != '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName ,C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.BatchCode = '$Batch' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
}else if ( $University != '' && $Course != '' && $Batch != '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName ,C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.BatchCode = '$Batch' AND SC.CourseID = '$Course' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
}
} else {
// echo $University;
// echo $branch;
if($University != '' && $Course == '' && $Batch == '') {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName , C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.BranchID = '$branch'
AND SC.IsActive = '1'";
@ -388,10 +431,61 @@ class StatusUpdation_model extends CI_Model
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
} else if ($University != '' && $Course != '' && $Batch == '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName , C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.CourseID = '$Course' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.BranchID = '$branch'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
} else if ( $University != '' && $Course == '' && $Batch != '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName ,C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.BatchCode = '$Batch' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.BranchID = '$branch'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
} else if ( $University != '' && $Course != '' && $Batch != '' ) {
$subQuery = "SELECT S.* , SC.ID as UNI_ID, SC.CourseID , C.CourseName , C.CourseCode, U.UniversityName
FROM ".STUDENTS." as S LEFT JOIN ".STUDENTCOURSE." as SC ON SC.StudentID = S.StudentID
LEFT JOIN ".UNIVERSITY." as U ON SC.UniversityID = U.UniversityID LEFT JOIN ".COURSE." as C ON
SC.CourseID = C.CourseID
WHERE
SC.BatchCode = '$Batch' AND SC.CourseID = '$Course' AND SC.UniversityID = '$University'
AND S.IsActive = '1'
AND SC.BranchID = '$branch'
AND SC.IsActive = '1'";
// AND S.BranchCode = '$branch'
// SC.UniversityID LIKE '%$University%'
// AND SC.CourseID LIKE '%$Course%'
// AND SC.BatchCode LIKE '%$Batch%'
$queryDetails = $this->db->query($subQuery);
$results['searchResult'] = true;
$results['search_result_details'] = $queryDetails->result();
}
}
return $results;
}
@ -410,16 +504,14 @@ class StatusUpdation_model extends CI_Model
// University Details
$resultArr['UniversityID'] = $clip->UniversityID;
$resultArr['UniversityName'] = $clip->UniversityName;
// Course Details
$this->db->select('t2.CourseID, t2.CourseName');
$this->db->select('t2.CourseID, t2.CourseName, t2.CourseCode');
$this->db->from(''.COURSE. ' as t2');
$this->db->where('t2.UniversityID', $clip->UniversityID);
$this->db->where('t2.IsActive', 1);
$courDetails = $this->db->get();
$courseDetails = $courDetails->result();
$resultArr['Course'] =$courseDetails;
// Batch Details
$this->db->select('t3.BatchName, t3.BatchCode');
$this->db->from(''.BATCH. ' as t3');
@ -438,10 +530,8 @@ class StatusUpdation_model extends CI_Model
// http://www.24x7sms.com/downloads/24X7SMS_http_API2.0.pdf
// API Key : xegCdYUIMf3
// Your new password for logging into Apollo student portal is (Password). Please change the password as soon as you login.
// This is the template to be used.
public function smssend($arr, $msg)
{
$number =array();
@ -514,8 +604,6 @@ class StatusUpdation_model extends CI_Model
$this->db->where('PLD.IsActive','1');
$checkStatus=$this->db->get()->last_row();
if($checkStatus){
$studentDetails = $this->studentInfo($fromDetails);
if($studentDetails){
$arrayDetails['MobileNumber']=$studentDetails->MobileNumber;
@ -554,43 +642,7 @@ class StatusUpdation_model extends CI_Model
$this->db->where('IsActive', '1');
$activityDetails=$this->db->get(ACTIVITY)->last_row();
if($activityDetails){
$newLeadDetails['MobileNumber'] = $arrayDetails['MobileNumber'];
$newLeadDetails['LeadName'] = $arrayDetails['LeadName'];
$newLeadDetails['CreatedBy'] = $arrayDetails['CreatedBy'];
$newLeadDetails['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_DETAILS, $newLeadDetails);
// this if for insert lead details
if($this->db->affected_rows() == '1'){
// get and store insert id from db
$track_Details['LeadID']=$this->db->insert_id();
$track_Details['ActivityStatus'] = $activityDetails->ActivityID;
$track_Details['University'] = $arrayDetails['University'];
$track_Details['Course'] = $arrayDetails['Course'];
$track_Details['AssignedTo'] = $arrayDetails['CreatedBy'];
$track_Details['StatusCode'] = $arrayDetails['StatusCode'];
$track_Details['CreatedBy'] = $arrayDetails['CreatedBy'];
$track_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$track_Details['CreatedBranch']=$arrayDetails['CreatedBranch'];
$this->db->insert(LEAD_TRACKING, $track_Details);
// this if for insert tracking details
if($this->db->affected_rows() == '1'){
$insertfollowup_Details['TrackingID']=$this->db->insert_id();
$insertfollowup_Details['FollowupOn']=$arrayDetails['FollowupOn'];
$insertfollowup_Details['FollowupComments']=$arrayDetails['FollowupComments'];
$insertfollowup_Details['CreatedBy'] = $arrayDetails['CreatedBy'];
$insertfollowup_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_TRACKING_FOLLOWUP, $insertfollowup_Details);
// this if for insert follow up details
}
}
// hide tracking updated code
/*$this->db->select('LD.LeadID,LT.TrackingID');
$this->db->select('LD.LeadID,LT.TrackingID');
$this->db->from(LEAD_DETAILS.' as LD');
$this->db->join(LEAD_TRACKING.' as LT', 'LT.LeadID = LD.LeadID');
$this->db->where('LD.MobileNumber',$arrayDetails['MobileNumber']);
@ -609,7 +661,6 @@ class StatusUpdation_model extends CI_Model
$changeStatusCode['UpdatedBy'] = $arrayDetails['CreatedBy'];
$changeStatusCode['UpdatedOn'] = $arrayDetails['CreatedOn'];
$changeStatusCode['CreatedBranch']=$arrayDetails['CreatedBranch'];
$this->db->where('TrackingID',$leadDet->TrackingID);
$this->db->update(LEAD_TRACKING, $changeStatusCode);
// end update status
@ -619,9 +670,7 @@ class StatusUpdation_model extends CI_Model
$updateTrackDetails['CreatedBy'] = $arrayDetails['CreatedBy'];
$updateTrackDetails['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_TRACKING_FOLLOWUP, $updateTrackDetails);
}
else{
$this->db->select('LeadID');
$this->db->where('MobileNumber',$arrayDetails['MobileNumber']);
@ -646,9 +695,7 @@ class StatusUpdation_model extends CI_Model
$followup_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_TRACKING_FOLLOWUP, $followup_Details);
// this if for insert follow up details
}
}
else{
$newLeadDetails['MobileNumber'] = $arrayDetails['MobileNumber'];
@ -678,21 +725,12 @@ class StatusUpdation_model extends CI_Model
$insertfollowup_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_TRACKING_FOLLOWUP, $insertfollowup_Details);
// this if for insert follow up details
}
}
}
}*/
}
}
}
}
}
}
return true;
}
else{
@ -762,43 +800,7 @@ class StatusUpdation_model extends CI_Model
$this->db->where('IsActive', '1');
$activityDetails=$this->db->get(ACTIVITY)->last_row();
if($activityDetails){
$newLeadDetails['MobileNumber'] = $arrayDetails['MobileNumber'];
$newLeadDetails['LeadName'] = $arrayDetails['LeadName'];
$newLeadDetails['CreatedBy'] = $arrayDetails['CreatedBy'];
$newLeadDetails['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_DETAILS, $newLeadDetails);
// this if for insert lead details
if($this->db->affected_rows() == '1'){
// get and store insert id from db
$track_Details['LeadID']=$this->db->insert_id();
$track_Details['ActivityStatus'] = $activityDetails->ActivityID;
$track_Details['University'] = $arrayDetails['University'];
$track_Details['Course'] = $arrayDetails['Course'];
$track_Details['AssignedTo'] = $arrayDetails['CreatedBy'];
$track_Details['StatusCode'] = $arrayDetails['StatusCode'];
$track_Details['CreatedBy'] = $arrayDetails['CreatedBy'];
$track_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$track_Details['CreatedBranch']=$arrayDetails['CreatedBranch'];
$this->db->insert(LEAD_TRACKING, $track_Details);
// this if for insert tracking details
if($this->db->affected_rows() == '1'){
$insertfollowup_Details['TrackingID']=$this->db->insert_id();
$insertfollowup_Details['FollowupOn']=$arrayDetails['FollowupOn'];
$insertfollowup_Details['FollowupComments']=$arrayDetails['FollowupComments'];
$insertfollowup_Details['CreatedBy'] = $arrayDetails['CreatedBy'];
$insertfollowup_Details['CreatedOn'] = $arrayDetails['CreatedOn'];
$this->db->insert(LEAD_TRACKING_FOLLOWUP, $insertfollowup_Details);
// this if for insert follow up details
}
}
/// hide seperate track id
/* $this->db->select('LD.LeadID,LT.TrackingID');
$this->db->select('LD.LeadID,LT.TrackingID');
$this->db->from(LEAD_DETAILS.' as LD');
$this->db->join(LEAD_TRACKING.' as LT', 'LT.LeadID = LD.LeadID');
$this->db->where('LD.MobileNumber',$arrayDetails['MobileNumber']);
@ -895,7 +897,7 @@ class StatusUpdation_model extends CI_Model
}
}*/
}
}

File diff suppressed because it is too large Load Diff

View File

@ -71,10 +71,10 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
$http(checkBranchActiveForStuAdd).then(function (response) {
if (response.data) {
var checkStatus = response.data.branch_active_status;
if(checkStatus == "0"){
if (checkStatus == "0") {
$scope.inActiveBranchStatus = true;
swal(" ", "Cannot create a new Student for In-Active Branch", "warning");
}else {
} else {
$scope.inActiveBranchStatus = false;
}
} else {
@ -155,9 +155,9 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams",
"Course": "",
"Status": ""
}
$scope.myUnivSearch = "";
$scope.myUnivSearch = "";
$scope.getUniveId = function (univ) {
if( univ === ''){
if (univ === '') {
$scope.myUnivSearch = "";
$scope.searchData.University = '';
$scope.searchData.Course = '';
@ -188,7 +188,7 @@ $scope.myUnivSearch = "";
// }
$scope.getStudentList();
}
$scope.studentListLength = 0;
$scope.studentListLength = 0;
$scope.getStudentList = function () {
$scope.loader = true;
var empListreq = {
@ -220,7 +220,7 @@ $scope.studentListLength = 0;
$scope.setEditId = function (id) {
$scope.editId = id;
$scope.editCourseId = -1;
$scope.studentViewPage=-1;
$scope.studentViewPage = -1;
}
$scope.setEditCourseId = function (id) {
@ -300,7 +300,7 @@ $scope.studentListLength = 0;
};
$http(req).then(function (response) {
if (response.data.addStuCourseStatus == true) {
swal(" ","Student course added successfully.", "success");
swal(" ", "Student course added successfully.", "success");
$scope.getStudentCourseList($scope.currentStudentId);
} else {
swal(" ", response.data.message, "error");
@ -518,7 +518,7 @@ $scope.studentListLength = 0;
};
$http(checkReq).then(function (response) {
if (response.data.existMobile == true) {
if(response.data.details.type === 'R001'){
if (response.data.details.type === 'R001') {
// swal("Warning!", response.data.message, "warning");
$scope.myModel.primaryPhone = '';
// student registration find student previously exist
@ -526,19 +526,19 @@ $scope.studentListLength = 0;
// $scope.existingStudentId = response.data.details.studentId;
SweetAlert.swal({
title: "Warning!",
text: "Student Exsit with this same Number." + "\n Do you want to Enroll New Cource!",
text: "Student exist with this same number." + "\n Do you want to enroll new course!",
type: "warning",
showCancelButton: true,
confirmButtonColor: "#007aff",
confirmButtonText: "Yes!"
}, function (res) {
if(res === true){
if (res === true) {
$scope.existingStudentView = true;
$scope.existingStudentId = response.data.details.studentId;
}
});
}else if (response.data.details.type === 'R002' || response.data.details.type === 'R003'){
} else if (response.data.details.type === 'R002' || response.data.details.type === 'R003') {
swal("Warning!", response.data.message, "warning");
$scope.myModel.primaryPhone = '';
} else {
@ -552,7 +552,7 @@ $scope.studentListLength = 0;
$scope.stuExistingDetailsShowLoading = false;
$scope.getExistStudentDetails = function() {
$scope.getExistStudentDetails = function () {
// alert($scope.existingStudentId);
$scope.stuExistingDetailsShowLoading = true;
var checkExisReq = {
@ -577,13 +577,13 @@ $scope.studentListLength = 0;
});
}
$scope.cancelExisStudentView = function() {
$scope.cancelExisStudentView = function () {
$scope.existingStudentView = false;
}
// add student course for existing student
$scope.addCourseExistingStudent= {
$scope.addCourseExistingStudent = {
submit: function (form, myModelCourse, p) {
var firstError = null;
@ -621,7 +621,7 @@ $scope.studentListLength = 0;
};
$http(req).then(function (response) {
if (response.data.addStuCourseStatus == true) {
swal(" ","Student course added successfully. ", "success");
swal(" ", "Student course added successfully. ", "success");
$state.go($state.current, {}, { reload: true });
// $scope.getStudentCourseList($scope.currentStudentId);
} else {
@ -632,7 +632,7 @@ $scope.studentListLength = 0;
});
}
},
cancel: function() {
cancel: function () {
$scope.myModelCourse = {
'university': '',
'course': '',
@ -890,6 +890,141 @@ $scope.studentListLength = 0;
}
// start : entrollment document upload =============================
$scope.studentDocumentsList = '';
// get Student Document Details
$scope.getStuEntrollDocDetails = function (stuId) {
$scope.studentDocumentsList = '';
var getStudentDocDetails = {
method: 'POST',
url: apiPoint.url + 'getListofStuDocDetails/',
headers: {
'Content-Type': 'application/json'
},
data: {
exceptId: stuId,
localData: localDetail
}
};
$http(getStudentDocDetails).then(function (response) {
if (response.data.docListStatus == true) {
$scope.docNotFound = false;
$scope.studentDocumentsList = response.data.student_doc_details;
} else {
$scope.docNotFound = true;
}
});
}
$scope.deleteDocDetails = function (id, stuID) {
SweetAlert.swal({
title: "Warning!",
text: "Want to Delete this file ?",
type: "warning",
showCancelButton: true,
confirmButtonColor: "#007aff",
confirmButtonText: "Yes!"
}, function (res) {
if (res === true) {
// alert(id);
// alert(stuId);
var deleteDocEntry = {
method: 'POST',
url: apiPoint.url + 'deleteStuDocDetails/',
headers: {
'Content-Type': 'application/json'
},
data: {
exceptId: stuID,
docDetailsID: id,
localData: localDetail
}
};
$http(deleteDocEntry).then(function (response) {
if (response.data.docDeleteStatus == true) {
$scope.getStuEntrollDocDetails(stuID);
} else {
$scope.docNotFound = true;
}
});
}
});
}
$scope.myModelAddDocuments = {
"documentName": "",
"documentComments": ""
}
//an array of documents selected
$scope.filesDocuments = [];
//listen for the document selected event
$scope.$on("fileSelectedDocument", function (event, args) {
$scope.$apply(function () {
//add the file object to the scope's files collection
$scope.filesDocuments[0] = args.file;
});
});
$scope.studentEntrollDocFORM = {
submit: function (form, myModelAddDocuments, stuID) {
var firstError = null;
if (form.$invalid) {
var field = null, firstError = null;
for (field in form) {
if (field[0] != '$') {
if (firstError === null && !form[field].$valid) {
firstError = form[field].$name;
}
if (form[field].$pristine) {
form[field].$dirty = true;
}
}
}
angular.element('.ng-invalid[name=' + firstError + ']').focus();
// swal("The form cannot be submitted because it contains validation errors!", "Errors are marked with a red, dashed border!", "error");
} else {
if ($scope.filesDocuments[0] == undefined || $scope.filesDocuments[0] == null || $scope.filesDocuments.length === 0) {
swal("Warning!", "Choose the File.", "warning");
} else {
var formData = new FormData();
var stuDocProof = $scope.filesDocuments[0];
var stuDocProofStatus = $scope.filesDocuments[0] !== undefined ? true : false;
formData.append("data", JSON.stringify(myModelAddDocuments));
formData.append("studentID", stuID);
formData.append("updatedBy", localDetails.localUserID);
formData.append('stuDocProof', stuDocProof);
formData.append('stuDocProof_Status', stuDocProofStatus);
$http.post(apiPoint.url + 'addStudentEntrollDocDetails/', formData, {
transformRequest: angular.identity,
headers: { 'Content-Type': undefined, 'Process-Data': false },
}).success(function (res) {
if (res.stuDocUpdateStatus == true) {
$scope.getStuEntrollDocDetails(stuID);
swal(" ", "Updated successfully.", "success");
// $scope.getStudentList();
// $scope.editId = -1;
// $scope.editSaveButtonDisable = false;
} else {
swal(" ", res.data.message, "error");
// $scope.editSaveButtonDisable = false;
}
});
}
}
},
reset: function (form) {
$scope.filesDocuments[0] = undefined;
form.$setPristine(true);
angular.element("input[type='file']").val(null);
}
}
// end : entrollment document upload ====================================
$scope.stepsModelEdit = [];
$scope.imageUploadEdit = function (event) {
@ -932,6 +1067,7 @@ $scope.studentListLength = 0;
$scope.updateStuDetails = function (form, p, hidedob) {
$scope.editSaveButtonDisable = true;
var firstError = null;
// alert(form.$invalid);
if (form.$invalid) {
var field = null, firstError = null;
for (field in form) {
@ -947,6 +1083,7 @@ $scope.studentListLength = 0;
angular.element('.ng-invalid[name=' + firstError + ']').focus();
// swal("The form cannot be submitted because it contains validation errors!", "Errors are marked with a red, dashed border!", "error");
} else {
// alert(p.DOB);
var idProof = $scope.filesEdit[0];
@ -992,10 +1129,10 @@ $scope.studentListLength = 0;
$http.post(apiPoint.url + 'updateStudentImgDetails/', formData, {
transformRequest: angular.identity,
headers: { 'Content-Type': undefined, 'Process-Data': false },
}).success(function(res) {
}).success(function (res) {
// alert(JSON.stringify(res));
if (res.updateStuStatus == true) {
swal(" ","Updated successfully." , "success");
swal(" ", "Updated successfully.", "success");
$scope.getStudentList();
$scope.editId = -1;
$scope.editSaveButtonDisable = false;
@ -1146,10 +1283,10 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
$http(checkBranchActiveForStuAdd).then(function (response) {
if (response.data) {
var checkStatus = response.data.branch_active_status;
if(checkStatus == "0"){
if (checkStatus == "0") {
$scope.inActiveBranchStatus = true;
swal(" ", "Cannot create a new Student for In-Active Branch", "warning");
}else {
} else {
// $scope.inActiveBranchStatus = false;
}
} else {
@ -1206,7 +1343,7 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl
"Course": "",
"Status": ""
}
$scope.myUnivSearch = "";
$scope.myUnivSearch = "";
$scope.getUniveId = function (univ) {
let name = JSON.parse(univ);
$scope.searchData.University = name.UniversityID;
@ -1340,7 +1477,7 @@ $scope.myUnivSearch = "";
};
$http(req).then(function (response) {
if (response.data.addStuCourseStatus == true) {
swal(" ","Student course added successfully. ", "success");
swal(" ", "Student course added successfully. ", "success");
$scope.getStudentCourseList($scope.currentStudentId);
} else {
swal(" ", response.data.message, "error");
@ -1565,7 +1702,7 @@ $scope.myUnivSearch = "";
// } else {
// }
if (response.data.existMobile == true) {
if(response.data.details.type === 'R001'){
if (response.data.details.type === 'R001') {
// swal("Warning!", response.data.message, "warning");
$scope.myModel.primaryPhone = '';
// student registration find student previously exist
@ -1579,13 +1716,13 @@ $scope.myUnivSearch = "";
confirmButtonColor: "#007aff",
confirmButtonText: "Yes!"
}, function (res) {
if(res === true){
if (res === true) {
$scope.existingStudentView = true;
$scope.existingStudentId = response.data.details.studentId;
}
});
}else if (response.data.details.type === 'R002' || response.data.details.type === 'R003'){
} else if (response.data.details.type === 'R002' || response.data.details.type === 'R003') {
swal("Warning!", response.data.message, "warning");
$scope.myModel.primaryPhone = '';
} else {
@ -1599,7 +1736,7 @@ $scope.myUnivSearch = "";
$scope.stuExistingDetailsShowLoading = false;
$scope.getExistStudentDetails = function() {
$scope.getExistStudentDetails = function () {
// alert($scope.existingStudentId);
$scope.stuExistingDetailsShowLoading = true;
var checkExisReq = {
@ -1624,12 +1761,12 @@ $scope.myUnivSearch = "";
});
}
$scope.cancelExisStudentView = function() {
$scope.cancelExisStudentView = function () {
$scope.existingStudentView = false;
}
// add student course for existing student
$scope.addCourseExistingStudent= {
$scope.addCourseExistingStudent = {
submit: function (form, myModelCourse, p) {
var firstError = null;
@ -1667,7 +1804,7 @@ $scope.myUnivSearch = "";
};
$http(req).then(function (response) {
if (response.data.addStuCourseStatus == true) {
swal(" ","Student course added successfully. ", "success");
swal(" ", "Student course added successfully. ", "success");
$scope.disableButton = false;
$scope.viewStudentDetailsPage = false;
$scope.myActivateDiv();
@ -1681,7 +1818,7 @@ $scope.myUnivSearch = "";
});
}
},
cancel: function() {
cancel: function () {
$scope.myModelCourse = {
'university': '',
'course': '',
@ -1773,7 +1910,7 @@ $scope.myUnivSearch = "";
}
}
$scope.myActivateDiv = function() {
$scope.myActivateDiv = function () {
$scope.viewStudentDetailsPage = false;
$scope.myModel = {
'primaryPhone': '',
@ -1811,9 +1948,9 @@ $scope.myUnivSearch = "";
'dateofjoining': '',
'enrollmentid': ''
};
$timeout(function(){
$timeout(function () {
getDetails();
},1000);
}, 1000);
}
// add student
@ -1887,7 +2024,7 @@ $scope.myUnivSearch = "";
};
$http(req).then(function (response) {
if (response.data.addStudentStatus == true) {
swal( "", "Student added successfully.", "success");
swal("", "Student added successfully.", "success");
$scope.disableButton = false;
$scope.viewStudentDetailsPage = false;
// $state.go($state.current, {}, { reload: true });
@ -2156,23 +2293,37 @@ app.directive('fileUploadEdit', function () {
scope.$emit("fileSelectedEdit", { file: files[i] });
}
});
}
};
}
};
});
app.filter('unique', function() {
return function(collection, primaryKey, secondaryKey) { //optional secondary key
// file upload directive - file-upload-document
app.directive('fileUploadDocument', function () {
return {
scope: true, //create a new scope
link: function (scope, el, attrs) {
el.bind('change', function (event) {
var files = event.target.files;
//iterate files since 'multiple' may be specified on the element
for (var i = 0; i < files.length; i++) {
//emit event upward
scope.$emit("fileSelectedDocument", { file: files[i] });
}
});
}
};
});
app.filter('unique', function () {
return function (collection, primaryKey, secondaryKey) { //optional secondary key
var output = [],
keys = [];
angular.forEach(collection, function(item) {
angular.forEach(collection, function (item) {
var key;
secondaryKey === undefined ? key = item[primaryKey] : key = item[primaryKey][secondaryKey];
if(keys.indexOf(key) === -1) {
if (keys.indexOf(key) === -1) {
keys.push(key);
output.push(item);
}
@ -2183,7 +2334,7 @@ app.filter('unique', function() {
});
/*modal controller
* */
app.controller('studentModalDemoCtrl', ["$scope", "$modal", "$log", "API_POINTS", "$http", function ($scope, $modal, $log,apiPoint,$http) {
app.controller('studentModalDemoCtrl', ["$scope", "$modal", "$log", "API_POINTS", "$http", function ($scope, $modal, $log, apiPoint, $http) {
//Tooltip for print button
$scope.dynamicTooltip = 'Student View';
@ -2202,13 +2353,13 @@ app.controller('studentModalDemoCtrl', ["$scope", "$modal", "$log", "API_POINTS"
'Content-Type': 'application/json'
},
data: {
requestedBy :studentDetails.StudentID,
requestedBy: studentDetails.StudentID,
requestedFrom: 1
}
};
$http(getcourse).then(function (response) {
if (response.data.status == 200 && response.data.studentStatus== true) {
if (response.data.status == 200 && response.data.studentStatus == true) {
$scope.courseEditLoading = false;
// $scope.studentDetails = response.data.studentDetails;
$scope.studentDetails = response.data;
@ -2267,7 +2418,7 @@ app.controller('studentModalDemoCtrl', ["$scope", "$modal", "$log", "API_POINTS"
// Please note that $modalInstance represents a modal window (instance) dependency.
// It is not the same as the $modal service used above.
app.controller('ModalInstanceCtrl', ["$scope", "$modalInstance", "items","WordsService", function ($scope, $modalInstance, items,WordsService) {
app.controller('ModalInstanceCtrl', ["$scope", "$modalInstance", "items", "WordsService", function ($scope, $modalInstance, items, WordsService) {
$scope.items = items;
$scope.selected = {
@ -2284,7 +2435,7 @@ app.controller('ModalInstanceCtrl', ["$scope", "$modalInstance", "items","WordsS
}]);
app.controller('ModalInstanceCtrl1', ["$scope", "$modalInstance", "items1","WordsService", function ($scope, $modalInstance, items1,WordsService) {
app.controller('ModalInstanceCtrl1', ["$scope", "$modalInstance", "items1", "WordsService", function ($scope, $modalInstance, items1, WordsService) {
$scope.items1 = items1;

View File

@ -39,7 +39,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}<span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -154,12 +154,12 @@
<td>{{p.Lastname}}</td>
<td><a tooltip="View Student" class="text-dark" ng-click="open(p);">{{p.MobileNumber}}</a></td>
<td>{{p.EmailID}}</td>
<td>{{p.CourseName}}</td>
<td>{{p.CourseName}} (<strong>{{p.CourseCode}}</strong>)</td>
<td class="center">
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.StudentID)"></i> </span>
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.UNI_ID)"></i> </span>
</td>
</tr>
<tr ng-show="editId ===p.StudentID" ng-if="editId === p.StudentID">
<tr ng-show="editId ===p.UNI_ID" ng-if="editId === p.UNI_ID">
<!--<td><pre>{{p.StudentID}}</pre></td>-->
<td colspan="7">

View File

@ -39,7 +39,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}<span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -155,12 +155,12 @@
<td>{{p.Lastname}}</td>
<td><a tooltip="View Student" class="text-dark" ng-click="open(p);">{{p.MobileNumber}}</a></td>
<td>{{p.EmailID}}</td>
<td>{{p.CourseName}}</td>
<td>{{p.CourseName}}(<strong>{{p.CourseCode}}</strong>)</td>
<td class="center">
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.StudentID)"></i> </span>
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.UNI_ID)"></i> </span>
</td>
</tr>
<tr ng-show="editId ===p.StudentID" ng-if="editId === p.StudentID">
<tr ng-show="editId ===p.UNI_ID" ng-if="editId === p.UNI_ID">
<!--<td><pre>{{p.StudentID}}</pre></td>-->
<td colspan="7">

View File

@ -39,7 +39,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}<span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -153,12 +153,12 @@
<td>{{p.Lastname}}</td>
<td><a tooltip="View Student" class="text-dark" ng-click="open(p);">{{p.MobileNumber}}</a></td>
<td>{{p.EmailID}}</td>
<td>{{p.CourseName}}</td>
<td>{{p.CourseName}}(<strong>{{p.CourseCode}}</strong>)</td>
<td class="center">
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.StudentID)"></i> </span>
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.UNI_ID)"></i> </span>
</td>
</tr>
<tr ng-show="editId ===p.StudentID" ng-if="editId === p.StudentID">
<tr ng-show="editId ===p.UNI_ID" ng-if="editId === p.UNI_ID">
<!--<td><pre>{{p.StudentID}}</pre></td>-->
<td colspan="7">

View File

@ -39,7 +39,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}} <span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -155,13 +155,13 @@
<td>{{p.Lastname}}</td>
<td><a tooltip="View Student" class="text-dark" ng-click="open(p);">{{p.MobileNumber}}</a></td>
<td>{{p.EmailID}}</td>
<td>{{p.CourseName}}</td>
<td>{{p.CourseName}}(<strong>{{p.CourseCode}}</strong>)</td>
<td class="center">
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.StudentID)"></i> </span>
<span> <i tooltip="STATUS DETAILS" class="glyphicon glyphicon-list-alt" ng-click="setEditId(p.UNI_ID)"></i> </span>
</td>
</tr>
<!--<pre>{{ editId }}</pre>-->
<tr ng-show="editId ===p.StudentID" ng-if="editId === p.StudentID">
<tr ng-show="editId ===p.UNI_ID" ng-if="editId === p.UNI_ID">
<!--<td><pre>{{p.StudentID}}</pre></td>-->
<td colspan="7">

View File

@ -34,7 +34,7 @@
<tbody ng-repeat="s in studentCourseList">
<tr>
<td>{{s.UniversityName}}</td>
<td>{{s.CourseName}}</td>
<td>{{s.CourseName}}<span ng-show="s.CourseCode !=''">(<b>{{s.CourseCode}}</b>)</span></td>
<td>{{s.Specilization1}}</td>
<td>{{s.Specilization2}}</td>
<td>{{s.BatchName}}</td>
@ -88,7 +88,7 @@
<select class="form-control" ng-model="stucour.CourseID" name="course" class="cs-select cs-skin-elastic" required>
<option value="" disabled selected>Select Course</option>
<option ng-repeat="items in courseData" value="{{items.CourseID}}" ng-selected="stucour.CourseID == items.CourseID">{{items.CourseName}}</option>
<option ng-repeat="items in courseData" value="{{items.CourseID}}" ng-selected="stucour.CourseID == items.CourseID">{{items.CourseName}}<span ng-show="items.CourseCode != ''">(<b>{{items.CourseCode}}</b>)</span></option>
</select>
</div>
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>
@ -283,7 +283,7 @@
<select class="form-control" tabindex="26" name="course" ng-model="myModelCourse.course" class="cs-select cs-skin-elastic"
required>
<option value="" disabled selected>Select Course</option>
<option ng-repeat="item in courseData" value="{{item.CourseID}}">{{item.CourseName}}</option>
<option ng-repeat="item in courseData" value="{{item.CourseID}}">{{item.CourseName}}<span ng-show="item.CourseCode != ''">(<b>{{item.CourseCode}}</b>)</span></option>
</select>
</div>
<span class="error text-small block" ng-if="FormAdd.course.$dirty && FormAdd.course.$error.required">Course is required</span>

View File

@ -1,7 +1,10 @@
<form name="Form" id="form" novalidate>
<tabset class="tabbable">
<tab heading="Personal Details">
<form name="Form" id="form" novalidate>
<div class="row">
<div class="col-md-12">
<div class="col-md-12">
<fieldset>
<legend>
Personal Details
@ -213,7 +216,8 @@
Aadhar Number <span class="symbol required"></span>
</label>
<input type="text" name="aadharNumber" tabindex="12" placeholder="____-____-____" ui-mask="9999-9999-9999" class="form-control"
ng-model="p.AadharNumber" ng-minlength="10" ng-maxlength="15" ng-pattern="/^[0-9]*$/" required>
ng-model="p.AadharNumber" ng-minlength="10" ng-maxlength="15" ng-pattern="/^[0-9]*$/"
required>
<span class="error text-small block" ng-if="Form.aadharNumber.$dirty && Form.aadharNumber.$invalid" ng-hide="Form.aadharNumber.$error.maxlength || Form.aadharNumber.$error.minlength || Form.aadharNumber.$error.pattern">Aadhar Number is required.</span>
<span class="error text-small block" ng-if="Form.aadharNumber.$error.maxlength || Form.aadharNumber.$error.minlength || Form.aadharNumber.$error.pattern">Enter a Valid Aadhar Number</span>
</div>
@ -370,15 +374,14 @@
<span class="text-small block">Max 100 Characters.</span>
<span class="error text-small block" ng-if="Form.DeactiveComments.$dirty && Form.DeactiveComments.$invalid">De-Active Comments is required</span>
</div>
</div>
</div>
<!--<pre>{{ p | json}}</pre>-->
<input type="hidden" ng-init="hidden_DOB=p.DOB" ng-model="hidden_DOB">
<div class="row">
<div class="col-md-12">
<div class="pull-right">
<button type="button" ng-disabled="editSaveButtonDisable" ladda="ldloading1.zoom_in" tabindex="19" class="btn btn-wide btn-success" data-style="zoom-in" ng-click="updateStuDetails(Form, p, hidden_DOB)">
<button type="button" ng-disabled="editSaveButtonDisable" ladda="ldloading1.zoom_in" tabindex="19" class="btn btn-wide btn-success"
data-style="zoom-in" ng-click="updateStuDetails(Form, p, hidden_DOB)">
<i class='fa fa-spinner fa-spin' ng-if="editSaveButtonDisable"> </i> Save
</button>
<button type="reset" class="btn btn-warning btn-wide" tabindex="20" ng-click="cancel()">
@ -388,94 +391,93 @@
</div>
</div>
</fieldset>
<!--<fieldset>
</div>
</div>
</div>
</form>
</tab>
<tab heading="Document Details" id="documentDetails">
<h1>Document Details</h1>
<div ng-init="getStuEntrollDocDetails(p.StudentID)">
<fieldset style="background-color: #eaeaea;">
<legend>
Branch Details
Add Document Details
</legend>
<div class="container">
<form name="FormDoc" id="formDoc" novalidate ng-submit="studentEntrollDocFORM.submit(FormDoc, myModelAddDocuments, p.StudentID)" method="post">
<div class="row">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.homeBranch.$dirty && Form.homeBranch.$invalid, 'has-success':Form.homeBranch.$valid}">
<label for="form-field-select-2">
Home Branch <span class="symbol required"></span>
</label>
<select class="form-control" class="cs-select cs-skin-elastic" name="homeBranch" ng-model="p.BranchCode" required>
<option value="" disabled selected>Select Home Branch</option>
<option ng-repeat="item in branchDetails" value="{{item.BranchCode}}" ng-selected="p.BranchCode == item.BranchCode">{{item.BranchName}}</option>
</select>
<span class="error text-small block" ng-if="Form.homeBranch.$dirty && Form.homeBranch.$error.required">Home Branch is Required</span>
</div>
<div data-ng-controller="DatepickerDemoCtrl">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.dateofjoining.$dirty && Form.dateofjoining.$invalid, 'has-success':Form.dateofjoining.$valid}">
<div class="col-md-6 form-group" ng-class="{'has-error':FormDoc.documentName.$dirty && FormDoc.documentName.$invalid, 'has-success':FormDoc.documentName.$valid}">
<label>
Date Of Joining <span class="symbol required"></span>
Document Name <span
class="symbol required"></span>
</label>
<input type="text" tabindex="6" class="form-control " ng-click="startOpen = !startOpen" datepicker-popup="yyyy-MM-dd" ng-model="p.DOJ"
is-open="startOpen" ng-init="startOpen = false" name="dateofbirth" datepicker-options="dateOptions"
placeholder="Select Date of Joining" close-text="Close" required="required"
/>
<span class="error text-small block" ng-if="Form.dateofjoining.$dirty && Form.dateofjoining.$error.required">Date of Joining required</span>
</div>
<input type="text" name="documentName" tabindex="1" placeholder="Document Name" class="form-control" ng-model="myModelAddDocuments.documentName"
required/>
<span class="error text-small block" ng-if="FormDoc.documentName.$dirty && FormDoc.documentName.$invalid" ng-hide="FormDoc.documentName.$error.maxlength || FormDoc.documentName.$error.minlength || FormDoc.documentName.$error.pattern">Document Name is required.</span>
</div>
<div class="col-md-4 form-group">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.role.$dirty && Form.role.$invalid, 'has-success':Form.role.$valid}">
<label>
Role <span class="symbol required"></span>
Attach File <span
class="symbol required"></span>
</label>
<select class="form-control" name="role" ng-model="p.ListCode" class="cs-select cs-skin-elastic" required>
<option value="" disabled selected>Select Role</option>
<option ng-repeat="item in roleDetails" value="{{item.ListCode}}" ng-selected="p.ListCode == item.ListCode">{{item.ListName}}</option>
</select>
<span class="error text-small block" ng-if="Form.role.$dirty && Form.role.$error.required">Role is required</span>
</div>
</div>
<div class="row">
<div class="col-md-4">
<label>
Active/De-Active
</label>
<div ng-switch="p.IsActive">
<div ng-switch-when="true">
<switch ng-model="p.IsActive" ng-init="p.IsActive = true" class="green"></switch>
</div>
<div ng-switch-when="false">
<switch ng-model="p.IsActive" ng-init="p.IsActive = false" class="green"></switch>
</div>
<div ng-switch-default>
<switch ng-model="p.IsActive" ng-init="p.IsActive = true" class="green"></switch>
</div>
</div>
</div>
</div>
<pre>{{ p | json}}</pre>
<div class="row">
<div class="col-md-12">
<div class="pull-right">
<button type="button" ladda="ldloading1.zoom_in" class="btn btn-wide btn-success" data-style="zoom-in" ng-click="updateEmpDetails(Form, p)">
Submit
<span>
<input type="file" accept="/*" file-upload-document />
</span>
<!--<span class="d-inline-block">
<button tooltip="Reset" class="btn btn-warning btn-xs pull-right" tabindex="6" ng-click="studentEntrollDocFORM.reset(FormDoc)">
<i class="ti-reload"></i>
</button>
<button type="reset" class="btn btn-warning btn-wide" tabindex="9" ng-click="branchForm.reset(Form)">
Reset
</span>-->
</div>
<div class="col-md-2">
<label>
</label>
<div>
<button tooltip="Upload" type="submit" ng-disabled="disableButton" tabindex="5" class="btn btn-xs btn-success">
<i class="ti-upload"></i>
</button>
<button tooltip="Reset" class="btn btn-warning btn-xs" tabindex="6" ng-click="studentEntrollDocFORM.reset(FormDoc)">
<i class="ti-reload"></i>
</button>
</div>
</div>
</div>
</fieldset>-->
</form>
</div>
</fieldset>
<div id="documentDetalils">
<div class="table-responsive">
<table class="table table-hover" ng-controller="studentModalDemoCtrl">
<thead>
<tr>
<th>Document Name</th>
<th>Status</th>
<th class="center">Download/Delete</th>
</tr>
</thead>
<tbody ng-repeat="doc in studentDocumentsList">
<tr>
<td>{{doc.DocumentName}}</td>
<td>{{doc.DocumentStorePath}}</td>
<td class="center"><button tooltip="Download" class="btn btn-xs btn-primary"><i class="ti-download">
<a ng-href="http://localhost/apollo_New_Update_03-01/apollodec/Apollo/images/{{doc.DocumentStorePath}}" target="_blank"></a> </i></button>
<button tooltip="Delete" class="btn btn-xs btn-danger" ng-click="deleteDocDetails(doc.ID, p.StudentID)"><i class="ti-trash">
</i></button>
<!--<a ng-src="images/{{doc.DocumentStorePath}}" target="_blank">here!</a>-->
</td>
</tr>
</tbody>
</table>
<div ng-if="docNotFound">
<span style="color:tomato;"> No document details found **</span>
</div>
</div>
<!--<div class="col-md-12">
<div class="pull-right">
<input type="button" class="btn btn-warning btn-wide" tabindex="9" value="Cancel"
ng-click="cancel();">
</input>
</div>
</div>-->
<!--</fieldset>-->
</div>
</div>
</form>
</tab>
</tabset>
<!-- class="editRowTd" -->

View File

@ -96,7 +96,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}<span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -650,7 +650,7 @@
<select class="form-control" tabindex="26" name="course" ng-model="myModelCourseAdd.course" class="cs-select cs-skin-elastic"
required>
<option value="" disabled selected>Select Course</option>
<option ng-repeat="item in courseDataAdd" value="{{item.CourseID}}">{{item.CourseName}}</option>
<option ng-repeat="item in courseDataAdd" value="{{item.CourseID}}">{{item.CourseName}}<span ng-show="item.CourseCode != ''">(<b>{{item.CourseCode}}</b>)</span></option>
</select>
</div>
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>

View File

@ -126,7 +126,7 @@
<select class="form-control" tabindex="2" class="cs-select cs-skin-elastic" name="course" ng-model="searchData.Course" ng-change="getValueChange()">
<option value="" selected>Select Course</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}</option>
<option ng-repeat="itemCourse in courseData" value="{{itemCourse.CourseID}}">{{itemCourse.CourseName}}<span ng-show="itemCourse.CourseCode != ''">(<strong>{{itemCourse.CourseCode}}</strong>)</span></option>
</select>
</div>
@ -674,7 +674,7 @@
<select class="form-control" tabindex="28" name="course" ng-model="myModelCourseAdd.course" class="cs-select cs-skin-elastic"
required>
<option value="" disabled selected>Select Course</option>
<option ng-repeat="item in courseDataAdd" value="{{item.CourseID}}">{{item.CourseName}}</option>
<option ng-repeat="item in courseDataAdd" value="{{item.CourseID}}">{{item.CourseName}}<span ng-show="item.CourseCode != ''">(<b>{{item.CourseCode}}</b>)</span></option>
</select>
</div>
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>