275 lines
18 KiB
HTML
Executable File
275 lines
18 KiB
HTML
Executable File
<div class="row">
|
|
<div class="col-md-12">
|
|
<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>Batch
|
|
</th>
|
|
<th>Date of Joining
|
|
</th>
|
|
<th>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody ng-repeat="s in studentCourseList">
|
|
<tr>
|
|
<td>{{s.UniversityName}}</td>
|
|
<td>{{s.CourseName}}</td>
|
|
<td>{{s.BatchName}}</td>
|
|
<td>{{s.DOJ}}</td>
|
|
<td ng-click="getStudentCourseDetails(s.ID)"><i class="fa fa-edit"></i></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="pull-right">
|
|
<button type="reset" class="btn btn-into btn-wide" tabindex="9" ng-click="addStudentCourse()">
|
|
Add Course
|
|
</button>
|
|
<button type="reset" class="btn btn-warning btn-wide" tabindex="9" 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)" class="form-control" name="univ" ng-model="stucour.UniversityID"
|
|
class="cs-select cs-skin-elastic" ng-change="onChangeSlecetUnivEdit(stucour.UniversityID)"
|
|
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 form-group" 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}}</option>
|
|
</select>
|
|
</div>
|
|
<span class="error text-small block" ng-if="Form.course.$dirty && Form.course.$error.required">Course is required</span>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':Form.batch.$dirty && Form.batch.$invalid, 'has-success':Form.batch.$valid}">
|
|
<label>
|
|
Batch <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" name="batch" ng-model="stucour.BatchCode" class="cs-select cs-skin-elastic" required>
|
|
|
|
<option value="" disabled selected>Select Batch</option>
|
|
<option ng-repeat="items in batchData" value="{{items.BatchCode}}" ng-selected="stucour.BatchCode == items.BatchCode">{{items.BatchName}}</option>
|
|
</select>
|
|
</div>
|
|
<span class="error text-small block" ng-if="Form.batch.$dirty && Form.batch.$error.required">Batch 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"
|
|
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 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 required</span>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<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">Comments Should be Less than 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>
|
|
|
|
|
|
<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 form-group" 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}}</option>
|
|
</select>
|
|
</div>
|
|
<span class="error text-small block" ng-if="FormAdd.course.$dirty && FormAdd.course.$error.required">Course is required</span>
|
|
|
|
</div>
|
|
|
|
<div class="col-md-4 form-group" ng-class="{'has-error':FormAdd.batch.$dirty && FormAdd.batch.$invalid, 'has-success':FormAdd.batch.$valid}">
|
|
|
|
<label>
|
|
Batch <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 Batch</option>
|
|
<option ng-repeat="item in batchData" value="{{item.BatchCode}}">{{item.BatchName}}</option>
|
|
</select>
|
|
</div>
|
|
<span class="error text-small block" ng-if="FormAdd.batch.$dirty && FormAdd.batch.$error.required">Batch is required</span>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<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="27" 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 required</span>
|
|
</div>
|
|
|
|
<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"/>
|
|
|
|
<span class="error text-small block" ng-if="FormAdd.dateofjoining.$dirty && FormAdd.dateofjoining.$error.required">Date of Joining required</span>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="pull-right">
|
|
<button type="submit" tabindex="30" ladda="ldloading1.zoom_in" class="btn btn-wide btn-success" data-style="zoom-in">
|
|
Submit
|
|
</button>
|
|
<button type="reset" tabindex="31" 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" --> |