course details changes done
This commit is contained in:
parent
0d7bbac5b4
commit
cd8ece637e
@ -85,6 +85,17 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
// get exist subject details
|
||||||
|
$scope.editSubject = [];
|
||||||
|
angular.forEach(p.existSubjects, function (values, keys) {
|
||||||
|
|
||||||
|
$scope.editSubject.push(values.SubjectID);
|
||||||
|
})
|
||||||
|
$scope.viewSubject = {
|
||||||
|
list: $scope.editSubject,
|
||||||
|
}
|
||||||
|
|
||||||
$scope.editId = pid;
|
$scope.editId = pid;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -173,7 +184,8 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
semFeesAmounts:$scope.addMoreItems,
|
semFeesAmounts:$scope.addMoreItems,
|
||||||
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
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(addCourse).then(function (response) {
|
$http(addCourse).then(function (response) {
|
||||||
@ -206,7 +218,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
* update the course details
|
* update the course details
|
||||||
* created by kms
|
* created by kms
|
||||||
* */
|
* */
|
||||||
$scope.updateCourse = function (myModel, form,regular,lateral,semYear, loading) {
|
$scope.updateCourse = function (myModel, form,regular,lateral,semYear, loading,subjects) {
|
||||||
var firstError = null;
|
var firstError = null;
|
||||||
if (form.$invalid) {
|
if (form.$invalid) {
|
||||||
var field = null, firstError = null;
|
var field = null, firstError = null;
|
||||||
@ -246,6 +258,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
courseID: myModel.CourseID,
|
courseID: myModel.CourseID,
|
||||||
|
universityID: myModel.UniversityID,
|
||||||
courseCode: myModel.CourseCode,
|
courseCode: myModel.CourseCode,
|
||||||
courseName: myModel.CourseName,
|
courseName: myModel.CourseName,
|
||||||
provFess:myModel.PC,
|
provFess:myModel.PC,
|
||||||
@ -261,7 +274,8 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
updatedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
updatedBy: JSON.parse(localStorage.getItem('localObj')).localUserID,
|
||||||
specilization1:myModel.Specilization1,
|
specilization1:myModel.Specilization1,
|
||||||
specilization2:myModel.Specilization2,
|
specilization2:myModel.Specilization2,
|
||||||
existCourseID:myModel.CourseID
|
existCourseID:myModel.CourseID,
|
||||||
|
subjects:subjects.list
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
$http(update).then(function (response) {
|
$http(update).then(function (response) {
|
||||||
@ -374,6 +388,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
};
|
};
|
||||||
|
|
||||||
function getUniversity_FeesDetails() {
|
function getUniversity_FeesDetails() {
|
||||||
|
$scope.subjectDetails=[];
|
||||||
var getCourseUnivFee = {
|
var getCourseUnivFee = {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
url: apiPoint.url + 'getCourseUnivFeesDetails/',
|
url: apiPoint.url + 'getCourseUnivFeesDetails/',
|
||||||
@ -388,11 +403,19 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
|||||||
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.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;
|
||||||
|
|
||||||
|
angular.forEach(response.data.subjectetails, function (values, keys) {
|
||||||
|
$scope.subData = {
|
||||||
|
SubjectID: values.SubjectID,
|
||||||
|
SubjectName: values.SubjectCode +'-'+values.SubjectName
|
||||||
|
};
|
||||||
|
$scope.subjectDetails.push($scope.subData);
|
||||||
|
})
|
||||||
// single sitting regular course details in model
|
// single sitting regular course details in model
|
||||||
|
|
||||||
$scope.myModelRegular = {
|
$scope.myModelRegular = {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user