course changes done
This commit is contained in:
parent
f872dd2038
commit
ba275fa9d3
@ -34,8 +34,8 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
$rootScope.updateMoreItems = [];
|
$rootScope.updateMoreItems = [];
|
||||||
$scope.editId = -1;
|
$scope.editId = -1;
|
||||||
$scope.setEditId = function (pid,p) {
|
$scope.setEditId = function (pid,p) {
|
||||||
$scope.localSubjectDetails="";
|
// $scope.localSubjectDetails="";
|
||||||
$scope.localSubjectDetails = JSON.parse(localStorage.getItem('localSubjectDetails'));
|
// $scope.localSubjectDetails = JSON.parse(localStorage.getItem('localSubjectDetails'));
|
||||||
$scope.localUniversityDetails="";
|
$scope.localUniversityDetails="";
|
||||||
$scope.localUniversityDetails = JSON.parse(localStorage.getItem('localUniversityDetails'));
|
$scope.localUniversityDetails = JSON.parse(localStorage.getItem('localUniversityDetails'));
|
||||||
|
|
||||||
@ -106,7 +106,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
|
|
||||||
|
|
||||||
// get exist subject details
|
// get exist subject details
|
||||||
$scope.editSubject = [];
|
/* $scope.editSubject = [];
|
||||||
|
|
||||||
angular.forEach(p.existSubjects, function (values, keys) {
|
angular.forEach(p.existSubjects, function (values, keys) {
|
||||||
$scope.getDeactiveSub = {
|
$scope.getDeactiveSub = {
|
||||||
@ -123,7 +123,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
|
|
||||||
$scope.viewSubject = {
|
$scope.viewSubject = {
|
||||||
list: $scope.editSubject,
|
list: $scope.editSubject,
|
||||||
}
|
}*/
|
||||||
|
|
||||||
$scope.editId = pid;
|
$scope.editId = pid;
|
||||||
};
|
};
|
||||||
@ -214,7 +214,8 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
createdBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
createdBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
||||||
specilization1:myModel.specilization1,
|
specilization1:myModel.specilization1,
|
||||||
specilization2:myModel.specilization2,
|
specilization2:myModel.specilization2,
|
||||||
subjects:myModel.subject
|
// subjects:myModel.subject,
|
||||||
|
branchCode:JSON.parse(localStorage.getItem('localObj')).localBranchID
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(addCourse).then(function (response) {
|
$http(addCourse).then(function (response) {
|
||||||
@ -304,7 +305,9 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
specilization1:myModel.Specilization1,
|
specilization1:myModel.Specilization1,
|
||||||
specilization2:myModel.Specilization2,
|
specilization2:myModel.Specilization2,
|
||||||
existCourseID:myModel.CourseID,
|
existCourseID:myModel.CourseID,
|
||||||
subjects:subjects.list
|
// subjects:subjects.list,
|
||||||
|
branchCode:JSON.parse(localStorage.getItem('localObj')).localBranchID
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(update).then(function (response) {
|
$http(update).then(function (response) {
|
||||||
@ -344,7 +347,9 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
'Content-Type': 'application/json'
|
'Content-Type': 'application/json'
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID
|
requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
||||||
|
branchCode:JSON.parse(localStorage.getItem('localObj')).localBranchID
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(getCourse).then(function (response) {
|
$http(getCourse).then(function (response) {
|
||||||
@ -354,70 +359,17 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
|
|
||||||
$scope.data = response.data.details;
|
$scope.data = response.data.details;
|
||||||
|
|
||||||
// $scope.university=response.data.universityDetails;
|
|
||||||
// $scope.feesDetails=response.data.feesDetails;
|
|
||||||
// $scope.myModel.ListName=$scope.feesDetails[0];
|
|
||||||
|
|
||||||
// $scope.myModel.programListName=$scope.myModel.ListName.programType[0].ListCode;
|
|
||||||
|
|
||||||
// // single sitting regular course details in model
|
|
||||||
|
|
||||||
// $scope.myModelRegular = {
|
|
||||||
// "FeesType":$scope.feesDetails[0].ListCode,
|
|
||||||
// "FeesName":$scope.feesDetails[0].ListName,
|
|
||||||
// "program":$scope.feesDetails[0].programType[0].ListCode,
|
|
||||||
// "programName":$scope.feesDetails[0].programType[0].ListName,
|
|
||||||
// "FeesAmount":"",
|
|
||||||
|
|
||||||
// };
|
|
||||||
|
|
||||||
// // single sitting lateral course details in model
|
|
||||||
|
|
||||||
// $scope.myModelLateral = {
|
|
||||||
// "FeesType":$scope.feesDetails[0].ListCode,
|
|
||||||
// "FeesName":$scope.feesDetails[0].ListName,
|
|
||||||
// "program":$scope.feesDetails[0].programType[1].ListCode,
|
|
||||||
// "programName":$scope.feesDetails[0].programType[1].ListName,
|
|
||||||
// "FeesAmount":"",
|
|
||||||
|
|
||||||
// };
|
|
||||||
|
|
||||||
// // single sitting Sem_Year course details in model
|
|
||||||
|
|
||||||
// $scope.myModelSemYear = {
|
|
||||||
// "FeesType":$scope.feesDetails[1].ListCode,
|
|
||||||
// "FeesName":$scope.feesDetails[1].ListName,
|
|
||||||
// "program":$scope.feesDetails[1].programType[0].ListCode,
|
|
||||||
// "programName":"",
|
|
||||||
// "FeesAmount":"",
|
|
||||||
|
|
||||||
// };
|
|
||||||
// $rootScope.myModelSemYear1 = {
|
|
||||||
// "FeesType":$scope.feesDetails[1].ListCode,
|
|
||||||
// "FeesName":$scope.feesDetails[1].ListName,
|
|
||||||
// "program":$scope.feesDetails[1].programType[0].ListCode,
|
|
||||||
// "programName":"",
|
|
||||||
// "FeesAmount":"",
|
|
||||||
|
|
||||||
// };
|
|
||||||
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
$scope.emptyData=false;
|
$scope.emptyData=false;
|
||||||
$scope.loader=true;
|
$scope.loader=true;
|
||||||
// getUniversity_FeesDetails();
|
|
||||||
// $scope.university=response.data.universityDetails;
|
|
||||||
// $scope.feesDetails=response.data.feesDetails;
|
|
||||||
// $scope.myModel.ListName=$scope.feesDetails[0];
|
|
||||||
// $scope.myModel.programListName=$scope.myModel.ListName.programType[0].ListCode;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
function getUniversity_FeesDetails() {
|
function getUniversity_FeesDetails() {
|
||||||
localStorage.setItem('localSubjectDetails', '');
|
// localStorage.setItem('localSubjectDetails', '');
|
||||||
localStorage.setItem('localUniversityDetails', '');
|
localStorage.setItem('localUniversityDetails', '');
|
||||||
|
|
||||||
$scope.subjectDetails=[];
|
$scope.subjectDetails=[];
|
||||||
@ -428,26 +380,29 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
'Content-Type': 'application/json'
|
'Content-Type': 'application/json'
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID
|
requestedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
||||||
|
branchCode:JSON.parse(localStorage.getItem('localObj')).localBranchID
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(getCourseUnivFee).then(function (response) {
|
$http(getCourseUnivFee).then(function (response) {
|
||||||
if (response.data.status==200 && response.data.courseStatus) {
|
if (response.data.status==200 && response.data.courseStatus) {
|
||||||
|
|
||||||
$scope.university=response.data.universityDetails;
|
$scope.university=response.data.universityDetails;
|
||||||
$scope.subjectDetails=[];
|
// $scope.subjectDetails=[];
|
||||||
$scope.feesDetails=response.data.feesDetails;
|
$scope.feesDetails=response.data.feesDetails;
|
||||||
$scope.myModel.ListName=$scope.feesDetails[0];
|
$scope.myModel.ListName=$scope.feesDetails[0];
|
||||||
|
|
||||||
$scope.myModel.programListName=$scope.myModel.ListName.programType[0].ListCode;
|
$scope.myModel.programListName=$scope.myModel.ListName.programType[0].ListCode;
|
||||||
|
//hide subject details
|
||||||
|
|
||||||
angular.forEach(response.data.subjectetails, function (values, keys) {
|
/* angular.forEach(response.data.subjectetails, function (values, keys) {
|
||||||
$scope.subData = {
|
$scope.subData = {
|
||||||
SubjectID: values.SubjectID,
|
SubjectID: values.SubjectID,
|
||||||
SubjectName: values.SubjectCode +'-'+values.SubjectName
|
SubjectName: values.SubjectCode +'-'+values.SubjectName
|
||||||
};
|
};
|
||||||
$scope.subjectDetails.push($scope.subData);
|
$scope.subjectDetails.push($scope.subData);
|
||||||
});
|
});*/
|
||||||
|
|
||||||
// single sitting regular course details in model
|
// single sitting regular course details in model
|
||||||
|
|
||||||
@ -501,7 +456,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
}
|
}
|
||||||
localStorage.setItem('localUniversityDetails', JSON.stringify($scope.university));
|
localStorage.setItem('localUniversityDetails', JSON.stringify($scope.university));
|
||||||
|
|
||||||
localStorage.setItem('localSubjectDetails', JSON.stringify($scope.subjectDetails));
|
// localStorage.setItem('localSubjectDetails', JSON.stringify($scope.subjectDetails));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user