368 lines
25 KiB
HTML
Executable File
368 lines
25 KiB
HTML
Executable File
<div class="row">
|
|
<div class="col-md-12">
|
|
<script>
|
|
$(document).ready(function(){
|
|
$("#addCourseBtn").focus();
|
|
})
|
|
</script>
|
|
<div ng-if="courseEditLoading == true" class="text-center">
|
|
<!--<img src="assets/images/ajax_loader_blue.gif" style="width: 5%; height: 30%">-->
|
|
<h3>Fetching ...</h3>
|
|
</div>
|
|
<div class="col-md-12">
|
|
|
|
<fieldset ng-if="courseEditLoading == false">
|
|
<legend>
|
|
Course Details
|
|
</legend>
|
|
<!--list of course details : start-->
|
|
<div ng-if='list === true'>
|
|
<table class="table">
|
|
<thead>
|
|
<tr>
|
|
<th>University
|
|
</th>
|
|
<th>Course
|
|
</th>
|
|
<th>Specilization 1
|
|
</th>
|
|
<th>Specilization 2
|
|
</th>
|
|
<!--<th>Session
|
|
</th>-->
|
|
<th>Date of Joining
|
|
</th>
|
|
<th>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody ng-repeat="s in studentCourseList">
|
|
<tr>
|
|
<td>{{s.UniversityName}}</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.SessionName}}</td>-->
|
|
<td>{{s.DOJ}}</td>
|
|
<td ng-click="getStudentCourseDetails(s.ID)"><i class="fa fa-edit"></i></td>
|
|
<!--ng-hide="s.Fee_paid_exist == 1 && localUserType == 'R002'"-->
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="pull-right">
|
|
<button type="reset" id="addCourseBtn" class="btn btn-into btn-wide" tabindex="100" ng-click="addStudentCourse()">
|
|
Add Course
|
|
</button>
|
|
<button type="reset" class="btn btn-warning btn-wide" tabindex="101" ng-click="cancel()">
|
|
Cancel
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!--list of course details : end-->
|
|
<!--<pre> {{studentCourse | json }} </pre>-->
|
|
<!--Edit course details : Start-->
|
|
<div ng-if='courseEdit === true'>
|
|
<form name="Form" id="form" novalidate>
|
|
<div class="row">
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.univ.$dirty && Form.univ.$invalid, 'has-success':Form.univ.$valid}">
|
|
<label>
|
|
University <span class="symbol required"></span>
|
|
</label>
|
|
<select ng-init="onSlecetUnivEdit(stucour.UniversityID, stucour.CourseID)" class="form-control" name="univ" ng-model="stucour.UniversityID"
|
|
class="cs-select cs-skin-elastic" ng-change="onChangeSlecetUnivEdit(stucour.UniversityID)"
|
|
ng-disabled="stucour.Fee_paid_exist == 1 && localUserType == 'R002'" required>
|
|
|
|
<option value="" disabled selected>Select University</option>
|
|
<option ng-repeat="items in universityData" value="{{items.UniversityID}}" ng-selected="stucour.UniversityID == items.UniversityID">{{items.UniversityName}}</option>
|
|
</select>
|
|
<span class="error text-small block" ng-if="Form.univ.$dirty && Form.univ.$error.required">University is required</span>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-4" ng-class="{'has-error':Form.course.$dirty && Form.course.$invalid, 'has-success':Form.course.$valid}">
|
|
<!--<label>
|
|
Course <span class="symbol required"></span>
|
|
</label>
|
|
<div ng-if="courseLoading == true">
|
|
<span style="padding: auto 0; color: #007AFF; font-weight: bold;">fetching...</span>
|
|
</div>
|
|
<div ng-if="courseLoading == false">
|
|
<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}}<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>-->
|
|
|
|
<div class=" form-group">
|
|
<label>
|
|
Course<span class="symbol required"></span>
|
|
</label>
|
|
<ui-select ng-model="stuCourseEditDetailsObj.selected" name="course" ng-disabled="stucour.Fee_paid_exist == 1 && localUserType == 'R002'" theme="bootstrap" ng-required="true" ng-change="editStudentCourseDetailsChanges(stuCourseEditDetailsObj)">
|
|
<ui-select-match placeholder="Select Course" >
|
|
{{$select.selected.CourseName}}
|
|
</ui-select-match>
|
|
<ui-select-choices value repeat="item in courseDataEditScrn | filter: $select.search">
|
|
<div ng-bind-html="item.CourseName | highlight: $select.search"></div>
|
|
<small ng-bind-html="item.CourseCode | highlight: $select.search"></small>
|
|
</ui-select-choices>
|
|
</ui-select>
|
|
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>
|
|
</div>
|
|
<!--<pre>{{stuCourseEditDetailsObj}}</pre>-->
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="row">
|
|
<div class="col-md-4 form-group"
|
|
ng-class="{'has-error':Form.specilization1.$dirty && Form.specilization1.$invalid}">
|
|
<label>
|
|
Specilization 1
|
|
</label>
|
|
|
|
<input type="text" placeholder="Enter Specilization 1"
|
|
tabindex="30" class="form-control" name="specilization1"
|
|
ng-disabled="stucour.Fee_paid_exist == 1 && localUserType == 'R002'" ng-model="stucour.Specilization1" ng-pattern="/^[a-zA-Z0-9-./\s]*$/" />
|
|
<span class="error text-small block"
|
|
ng-if="Form.specilization1.$dirty && Form.specilization1.$error.pattern">Invalid Specilization 1 </span>
|
|
</div>
|
|
<div class="col-md-4 form-group"
|
|
ng-class="{'has-error':Form.specilization2.$dirty && Form.specilization2.$invalid}">
|
|
<label>
|
|
Specilization 2
|
|
</label>
|
|
|
|
<input type="text" placeholder="Enter Specilization 2"
|
|
tabindex="31" class="form-control" name="specilization2"
|
|
ng-disabled="stucour.Fee_paid_exist == 1 && localUserType == 'R002'" ng-model="stucour.Specilization2" ng-pattern="/^[a-zA-Z0-9-./\s]*$/" />
|
|
<span class="error text-small block"
|
|
ng-if="Form.specilization2.$dirty && Form.specilization2.$error.pattern">Invalid Specilization 2 </span>
|
|
</div>
|
|
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.enrollmentid.$dirty && Form.enrollmentid.$invalid}">
|
|
<label>
|
|
Enrollment ID
|
|
</label>
|
|
<input type="text" name="enrollmentid" tabindex="27" placeholder="Enter Entollment ID" class="form-control" ng-model="stucour.EnrollmentID"
|
|
/>
|
|
<span class="error text-small block" ng-if="Form.enrollmentid.$dirty && Form.enrollmentid.$error.required">Enrollment ID is required</span>
|
|
</div>
|
|
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.dateofjoining.$dirty && Form.dateofjoining.$invalid, 'has-success':Form.dateofjoining.$valid}">
|
|
<label>
|
|
Date of Joining <span class="symbol required"></span>
|
|
</label>
|
|
<input type="text" tabindex="8" class="form-control " ng-click="startOpen = !startOpen" datepicker-popup="dd-MM-yyyy" ng-model="stucour.DOJ"
|
|
is-open="startOpen" ng-init="startOpen = false" name="dateofjoining" datepicker-options="dateOptions"
|
|
ng-disabled="stucour.Fee_paid_exist == 1 && localUserType == 'R002'" placeholder="Select Date of Joining" close-text="Close" required="required" max-date="todayDate"/>
|
|
|
|
<span class="error text-small block" ng-if="Form.dateofjoining.$dirty && Form.dateofjoining.$error.required">Date of Joining is required</span>
|
|
</div>
|
|
<div ng-hide="stucour.Fee_paid_exist == 1 && localUserType == 'R002'">
|
|
<div class="col-md-4" >
|
|
<label>
|
|
Active/De-Active
|
|
</label>
|
|
<div ng-if="stucour.IsActive==true">
|
|
<switch ng-model="stucour.IsActive" ng-init="stucour.IsActive = true" class="green"></switch>
|
|
</div>
|
|
<div ng-if="stucour.IsActive==false">
|
|
<switch ng-model="stucour.IsActive" ng-init="stucour.IsActive = false" class="green"></switch>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-4" ng-if="stucour.IsActive == false" ng-class="{'has-error':Form.DeactiveComments.$dirty && Form.DeactiveComments.$invalid, 'has-success':Form.DeactiveComments.$valid}">
|
|
<label>
|
|
Reason for Deactivating <span class="symbol required"></span>
|
|
</label>
|
|
<textarea maxlength="100" placeholder="Reason for Deactivating" tabindex="25" class="form-control textdsc" name="DeactiveComments" ng-model="stucour.DeactiveComments" required></textarea>
|
|
<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 ng-show="stucour.Fee_paid_exist == 1 && localUserType == 'R002'">
|
|
<div class="col-md-4" >
|
|
<label>
|
|
Active/De-Active
|
|
</label>
|
|
<div ng-if="stucour.IsActive==true">
|
|
<label ng-init="stucour.IsActive = true"> Active </label>
|
|
<!--<switch ng-model="stucour.IsActive" ng-init="stucour.IsActive = true" class="green"></switch>-->
|
|
</div>
|
|
<div ng-if="stucour.IsActive==false">
|
|
<label ng-init="stucour.IsActive = false"> In-Active </label>
|
|
<!--<switch ng-model="stucour.IsActive" ng-init="stucour.IsActive = false" class="green"></switch>-->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<input type="hidden" ng-init="hidden_DOJ=stucour.DOJ" ng-model="hidden_DOJ">
|
|
<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="updateStudentCourseDetails(Form, stucour, hidden_DOJ)">
|
|
Update
|
|
</button>
|
|
<button type="reset" class="btn btn-warning btn-wide" tabindex="9" ng-click="cancelCourseDetails()">
|
|
Cancel
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
<!--Edit course details : Start-->
|
|
|
|
|
|
|
|
<div ng-if='courseAdd === true'>
|
|
<!--Add course details : Start -->
|
|
<form name="FormAdd" id="formAdd" novalidate ng-submit="addCourseFORM.submit(FormAdd, myModelCourse, p)" method="post">
|
|
<div class="row">
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':FormAdd.university.$dirty && FormAdd.university.$invalid, 'has-success':FormAdd.university.$valid}">
|
|
<label for="form-field-select-2">
|
|
University <span class="symbol required"></span>
|
|
</label>
|
|
|
|
<select class="form-control" tabindex="25" class="cs-select cs-skin-elastic" name="university" ng-model="myModelCourse.university"
|
|
ng-change="onSlecetUniv()" required>
|
|
<option value="" disabled selected>Select University</option>
|
|
<option ng-repeat="item in universityData" value="{{item.UniversityID}}">{{item.UniversityName}}</option>
|
|
</select>
|
|
<span class="error text-small block" ng-if="FormAdd.university.$dirty && FormAdd.university.$error.required">University is Required</span>
|
|
</div>
|
|
|
|
<div class="col-md-4" ng-class="{'has-error':FormAdd.course.$dirty && FormAdd.course.$invalid, 'has-success':FormAdd.course.$valid}">
|
|
|
|
<!--<label>
|
|
Course <span class="symbol required"></span>
|
|
</label>
|
|
<div ng-if="courseLoading == true">
|
|
<span style="padding: auto 0; color: #007AFF; font-weight: bold;">fetching...</span>
|
|
</div>
|
|
<div ng-if="courseLoading == false">
|
|
<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}}<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>
|
|
|
|
-->
|
|
|
|
<div class=" form-group">
|
|
<label>
|
|
Course<span class="symbol required"></span>
|
|
</label>
|
|
<ui-select ng-model="myModelCourseObjStu.selected" name="course" theme="bootstrap" ng-required="true" ng-change="addStudentCourseDetailsChanges(myModelCourseObjStu)">
|
|
<ui-select-match placeholder="Select Course">
|
|
{{$select.selected.CourseName}}
|
|
</ui-select-match>
|
|
<ui-select-choices value repeat="item in courseData | filter: $select.search">
|
|
<div ng-bind-html="item.CourseName | highlight: $select.search"></div>
|
|
<small ng-bind-html="item.CourseCode | highlight: $select.search"></small>
|
|
</ui-select-choices>
|
|
</ui-select>
|
|
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>
|
|
</div>
|
|
</div>
|
|
|
|
<!--<div class="col-md-4 form-group" ng-class="{'has-error':FormAdd.batch.$dirty && FormAdd.batch.$invalid, 'has-success':FormAdd.batch.$valid}">
|
|
|
|
<label>
|
|
Session <span class="symbol required"></span>
|
|
</label>
|
|
<div ng-if="courseLoading == true">
|
|
<span style="padding: auto 0; color: #007AFF; font-weight: bold;">fetching...</span>
|
|
</div>
|
|
<div ng-if="courseLoading == false">
|
|
<select class="form-control" tabindex="26" name="batch" ng-model="myModelCourse.batch" class="cs-select cs-skin-elastic"
|
|
required>
|
|
<option value="" disabled selected>Select Session</option>
|
|
<option ng-repeat="item in batchData" value="{{item.SessionID}}">{{item.SessionName}}</option>
|
|
</select>
|
|
</div>
|
|
<span class="error text-small block" ng-if="FormAdd.batch.$dirty && FormAdd.batch.$error.required">Session is required</span>
|
|
|
|
</div>-->
|
|
</div>
|
|
|
|
<div class="row">
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.specilization1.$dirty && Form.specilization1.$invalid}">
|
|
<label>
|
|
Specilization 1
|
|
</label>
|
|
<input type="text" placeholder="Enter Specilization 1" tabindex="27" class="form-control" name="specilization1" ng-model="myModelCourse.specilization1"
|
|
ng-pattern="/^[a-zA-Z0-9-./\s]*$/" />
|
|
<span class="error text-small block" ng-if="Form.specilization1.$dirty && Form.specilization1.$error.pattern">Invalid Specilization 1 </span>
|
|
</div>
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.specilization2.$dirty && Form.specilization2.$invalid}">
|
|
<label>
|
|
Specilization 2
|
|
</label>
|
|
<input type="text" placeholder="Enter Specilization 2" tabindex="28" class="form-control" name="specilization2" ng-model="myModelCourse.specilization2"
|
|
ng-pattern="/^[a-zA-Z0-9-./\s]*$/" />
|
|
<span class="error text-small block" ng-if="Form.specilization2.$dirty && Form.specilization2.$error.pattern">Invalid Specilization 2 </span>
|
|
</div>
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':FormAdd.enrollmentid.$dirty && FormAdd.enrollmentid.$invalid}">
|
|
<label>
|
|
Enrollment ID
|
|
</label>
|
|
<input type="text" name="enrollmentid" tabindex="31" placeholder="Enter Entollment ID" class="form-control" ng-model="myModelCourse.enrollmentid"
|
|
/>
|
|
<span class="error text-small block" ng-if="FormAdd.enrollmentid.$dirty && FormAdd.enrollmentid.$error.required">Enrollment ID is required</span>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
|
|
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':FormAdd.dateofjoining.$dirty && FormAdd.dateofjoining.$invalid, 'has-success':FormAdd.dateofjoining.$valid}">
|
|
<label>
|
|
Date of Joining <span class="symbol required"></span>
|
|
</label>
|
|
<style>
|
|
.dropdown-menu {
|
|
position: relative;
|
|
/*top: -225px !important;*/
|
|
}
|
|
</style>
|
|
<input type="text" tabindex="28" class="form-control" ng-click="startOpen = !startOpen" datepicker-popup="dd-MM-yyyy" ng-model="myModelCourse.dateofjoining"
|
|
is-open="startOpen" ng-init="startOpen = false" name="dateofjoining" datepicker-options="dateOptions"
|
|
placeholder="Select Date of Joining" close-text="Close" required="required" datepicker-position="top"
|
|
max-date="todayDate" ng-change="stuAddNewCourseDateChange()"/>
|
|
|
|
<span class="error text-small block" ng-if="FormAdd.dateofjoining.$dirty && FormAdd.dateofjoining.$error.required">Date of Joining is required</span>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="pull-right">
|
|
<button type="submit" tabindex="32" ladda="ldloading1.zoom_in" class="btn btn-wide btn-success" data-style="zoom-in">
|
|
Submit
|
|
</button>
|
|
<button type="reset" tabindex="33" class="btn btn-warning btn-wide" tabindex="9" ng-click="cancelCourseDetails()">
|
|
Cancel
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
<!--Add course details : End -->
|
|
</div>
|
|
</fieldset>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!-- class="editRowTd" --> |