Merge branch 'master' of https://bitbucket.org/venbainformationtechnology/apollodec
This commit is contained in:
commit
9cb5bfff45
@ -49,8 +49,12 @@ class Course_Controller extends REST_Controller {
|
||||
$jsonLateralFeesData=$this->post('lateralFeesAmounts');
|
||||
$jsonSemFeesData=$this->post('semFeesAmounts');
|
||||
// push regular,lateral fees into same array
|
||||
array_push($jsonSemFeesData,$jsonRegularFeesData);
|
||||
array_push($jsonSemFeesData,$jsonLateralFeesData);
|
||||
if($jsonRegularFeesData['FeesAmount'] != 0 AND $jsonRegularFeesData['FeesAmount'] != '' AND $jsonRegularFeesData['FeesAmount'] != 'undefined'){
|
||||
array_push($jsonSemFeesData,$jsonRegularFeesData);
|
||||
}
|
||||
if($jsonLateralFeesData['FeesAmount'] != 0 AND $jsonLateralFeesData['FeesAmount'] != '' AND $jsonLateralFeesData['FeesAmount'] != 'undefined'){
|
||||
array_push($jsonSemFeesData,$jsonLateralFeesData);
|
||||
}
|
||||
$courseDetails = $this->course_model->addCourse($details,$jsonSemFeesData);// Check if the users data store contains users (in case the database result returns NULL)
|
||||
if ($courseDetails)
|
||||
{
|
||||
@ -117,8 +121,14 @@ class Course_Controller extends REST_Controller {
|
||||
$jsonLateralFeesData=$this->post('lateralFeesAmounts');
|
||||
$jsonSemFeesData=$this->post('semFeesAmounts');
|
||||
// push regular,lateral fees into same array
|
||||
array_push($jsonSemFeesData,$jsonRegularFeesData);
|
||||
array_push($jsonSemFeesData,$jsonLateralFeesData);
|
||||
if($jsonRegularFeesData != '' AND $jsonRegularFeesData != null AND $jsonRegularFeesData != 'undefined'){
|
||||
array_push($jsonSemFeesData,$jsonRegularFeesData);
|
||||
|
||||
}
|
||||
if($jsonLateralFeesData != '' AND $jsonLateralFeesData != null AND $jsonLateralFeesData != 'undefined'){
|
||||
array_push($jsonSemFeesData,$jsonLateralFeesData);
|
||||
|
||||
}
|
||||
|
||||
$updateDetails = $this->course_model->updateCourse($details,$jsonSemFeesData);// Check if the users data store contains users (in case the database result returns NULL)
|
||||
if ($updateDetails)
|
||||
|
||||
@ -31,6 +31,8 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
||||
$rootScope.updateMoreItems = [];
|
||||
$scope.editId = -1;
|
||||
$rootScope.setEditId = function (pid,p) {
|
||||
$rootScope.myModelRegular1="";
|
||||
$rootScope.myModelLateral1="";
|
||||
$rootScope.updateMoreItems=[];
|
||||
// find index for fees type drop down list
|
||||
|
||||
@ -272,6 +274,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
||||
$scope.emptyData='';
|
||||
|
||||
$rootScope.init = function () {
|
||||
|
||||
$scope.loader='';
|
||||
var getCourse = {
|
||||
method: 'POST',
|
||||
@ -305,6 +308,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
||||
"FeesAmount":"",
|
||||
|
||||
};
|
||||
|
||||
// single sitting lateral course details in model
|
||||
|
||||
$scope.myModelLateral = {
|
||||
@ -315,6 +319,7 @@ app.controller('courseCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTab
|
||||
"FeesAmount":"",
|
||||
|
||||
};
|
||||
|
||||
// single sitting Sem_Year course details in model
|
||||
|
||||
$scope.myModelSemYear = {
|
||||
|
||||
@ -158,7 +158,7 @@
|
||||
|
||||
<input type="text" placeholder="Enter Course ID"
|
||||
tabindex="2" class="form-control" name="coursecode" ng-maxlength="20"
|
||||
ng-model="myModel.courseCode" ng-pattern="/^[a-zA-Z0-9\s]*$/" required/>
|
||||
ng-model="myModel.courseCode" ng-pattern="/^[a-zA-Z0-9-\s]*$/" required/>
|
||||
<span class="error text-small block"
|
||||
ng-if="Form.coursecode.$dirty && Form.coursecode.$error.required">Course id is required</span>
|
||||
<span class="error text-small block"
|
||||
|
||||
@ -17,7 +17,7 @@
|
||||
|
||||
<input type="text" placeholder="Enter Course ID"
|
||||
tabindex="1" class="form-control" name="coursecode"
|
||||
ng-model="p.CourseID" ng-pattern="/^[a-zA-Z0-9\s]*$/" readonly required/>
|
||||
ng-model="p.CourseID" ng-pattern="/^[a-zA-Z0-9-\s]*$/" readonly required/>
|
||||
<span class="error text-small block"
|
||||
ng-if="Form.coursecode.$dirty && Form.coursecode.$error.required">Course id is required</span>
|
||||
<span class="error text-small block"
|
||||
@ -99,10 +99,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
|
||||
<fieldset> <legend> {{myModelRegular1.FeesName}} </legend>
|
||||
<fieldset> <legend> Single </legend>
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6 form-group" ng-class="{'has-error':Form.regularFees.$dirty && Form.regularFees.$invalid}">
|
||||
<div class="col-md-6 form-group" ng-class="{'has-error':Form.regularFees.$dirty && Form.regularFees.$invalid}" ng-if="myModelRegular1.program=='P001'">
|
||||
<label>
|
||||
{{myModelRegular1.programName}} Fees
|
||||
</label>
|
||||
@ -115,7 +115,7 @@
|
||||
ng-if="Form.regularFees.$error.maxlength || Form.regularFees.$error.pattern">Enter a valid amount</span>
|
||||
|
||||
</div>
|
||||
<div class="col-md-6 form-group" ng-class="{'has-error':Form.lateralFees.$dirty && Form.lateralFees.$invalid}">
|
||||
<div class="col-md-6 form-group" ng-class="{'has-error':Form.lateralFees.$dirty && Form.lateralFees.$invalid}" ng-if="myModelLateral1.program=='P002'">
|
||||
<label>
|
||||
{{myModelLateral1.programName}} Fees
|
||||
</label>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user