form id changes details : kdk
This commit is contained in:
parent
8bfd4823b2
commit
bc8834dacf
@ -196,68 +196,17 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter
|
|||||||
/*
|
/*
|
||||||
watch upload model for enable upload options
|
watch upload model for enable upload options
|
||||||
*/
|
*/
|
||||||
$scope.showFile="0";
|
|
||||||
$scope.$watchCollection('uploadModel', function (newValue,oldValue) {
|
|
||||||
|
|
||||||
if(newValue.university!='' && newValue.university!=null && newValue.uploadFor!='' && newValue.uploadFor=='1'){
|
|
||||||
$scope.showFile = "1";
|
$scope.showFile = "1";
|
||||||
|
// $scope.$watchCollection('uploadModel', function (newValue, oldValue) {
|
||||||
|
|
||||||
}
|
// if (newValue.university != '' && newValue.university != null) {
|
||||||
else if(newValue.university!='' && newValue.university!=null && newValue.uploadFor!='' && newValue.uploadFor=='2'){
|
// $scope.showFile = "1";
|
||||||
$scope.showFile="2";
|
// }
|
||||||
}
|
// else {
|
||||||
else{
|
// $scope.showFile = "0";
|
||||||
$scope.showFile="0";
|
// }
|
||||||
}
|
|
||||||
|
|
||||||
});
|
// });
|
||||||
|
|
||||||
/* update received enrolment from university
|
|
||||||
* created by kms
|
|
||||||
* */
|
|
||||||
$scope.extractDetails="";
|
|
||||||
$scope.readXlsxDetails = function (workbook) {
|
|
||||||
/* DO SOMETHING WITH workbook HERE */
|
|
||||||
for (var sheetName in workbook.Sheets) {
|
|
||||||
var jsonData = XLSX.utils.sheet_to_json(workbook.Sheets[sheetName]);
|
|
||||||
if(jsonData.length!=0){
|
|
||||||
$scope.extractDetails=jsonData;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
$scope.error = function (e) {
|
|
||||||
/* DO SOMETHING WHEN ERROR IS THROWN */
|
|
||||||
//console.log(e);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
$scope.receiveEnrolmentDetails = function (details,uploadForDetails) {
|
|
||||||
var updateUniversityEnrolment = {
|
|
||||||
method: 'POST',
|
|
||||||
url: apiPoint.url + 'receiveEnrolmentFromUniv/',
|
|
||||||
headers: {
|
|
||||||
'Content-Type': 'application/json'
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
localDetails: localDetail,
|
|
||||||
details: details,
|
|
||||||
universityID: angular.fromJson(uploadForDetails.university).UniversityID,
|
|
||||||
universityName: angular.fromJson(uploadForDetails.university).UniversityName,
|
|
||||||
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
$http(updateUniversityEnrolment).then(function (response) {
|
|
||||||
if (response.data.status == true) {
|
|
||||||
swal("", "Updated Successfully", "success");
|
|
||||||
$state.go($state.current, {}, {reload: true});
|
|
||||||
} else {
|
|
||||||
swal("", "Failed", "error");
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
// end
|
|
||||||
|
|
||||||
$scope.extractFormIDDetails = "";
|
$scope.extractFormIDDetails = "";
|
||||||
$scope.readXlsxFormDetails = function (workbook) {
|
$scope.readXlsxFormDetails = function (workbook) {
|
||||||
@ -371,4 +320,43 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// get subtab details for the formid fee details get form the university
|
||||||
|
|
||||||
|
$scope.subTabActive= function(tab){
|
||||||
|
if( tab == 'subTabactive2'){
|
||||||
|
getDraftFormIdDetails();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// get draft form id details
|
||||||
|
function getDraftFormIdDetails(){
|
||||||
|
// $scope.unMatchedRecordDetails = '';
|
||||||
|
// $scope.unMatchedNoRecordFound = false;
|
||||||
|
// $scope.unMatchedLoadingStatus = true;
|
||||||
|
// var getDetailsFor = ss == 1 ? 'EnrolmentIDFile' : 'FormIDFile';
|
||||||
|
// var getFeeCompareDetailsList = {
|
||||||
|
// method: 'POST',
|
||||||
|
// url: apiPoint.url + 'getUnmatchedRecordDetails/',
|
||||||
|
// headers: {
|
||||||
|
// 'Content-Type': 'application/json'
|
||||||
|
// },
|
||||||
|
// data: {
|
||||||
|
// localDetails: localDetail,
|
||||||
|
// getDetailsFor: getDetailsFor
|
||||||
|
// }
|
||||||
|
// };
|
||||||
|
// $http(getFeeCompareDetailsList).then(function (response) {
|
||||||
|
// if (response.data.unMatchedRecordStatus == true) {
|
||||||
|
// $scope.unMatchedLoadingStatus = false;
|
||||||
|
// $scope.unMatchedNoRecordFound = false;
|
||||||
|
// $scope.unMatchedRecordDetails = response.data.unMatchedRecordDetails;
|
||||||
|
// $scope.unMatchedRecordDetailsType = response.data.unMatchedRecordFor;
|
||||||
|
// } else {
|
||||||
|
// $scope.unMatchedLoadingStatus = false;
|
||||||
|
// $scope.unMatchedNoRecordFound = true;
|
||||||
|
// $scope.unMatchedRecordDetails = response.data.unMatchedRecordDetails;
|
||||||
|
// }
|
||||||
|
// });
|
||||||
|
}
|
||||||
|
|
||||||
}]);
|
}]);
|
||||||
|
|||||||
@ -16,7 +16,6 @@
|
|||||||
$("#selectBranch").focus();
|
$("#selectBranch").focus();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
#containersPara {
|
#containersPara {
|
||||||
width: 180px;
|
width: 180px;
|
||||||
@ -40,7 +39,6 @@
|
|||||||
</style>
|
</style>
|
||||||
<div>
|
<div>
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
<div class="row" ng-init="init()">
|
<div class="row" ng-init="init()">
|
||||||
<tabset id="here" class="tabbable">
|
<tabset id="here" class="tabbable">
|
||||||
<tab tabindex="1" active="tabactive1" ng-click="tabActive('tabactive1')" heading="View Details" id="viewDetails">
|
<tab tabindex="1" active="tabactive1" ng-click="tabActive('tabactive1')" heading="View Details" id="viewDetails">
|
||||||
@ -51,7 +49,6 @@
|
|||||||
$("#searchIn").focus();
|
$("#searchIn").focus();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="container-fluid container-fullw">
|
<div class="container-fluid container-fullw">
|
||||||
<form name="Form" id="form" novalidate ng-submit="onSubmit()" method="post">
|
<form name="Form" id="form" novalidate ng-submit="onSubmit()" method="post">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@ -59,43 +56,38 @@
|
|||||||
<label for="form-field-select-2">
|
<label for="form-field-select-2">
|
||||||
University
|
University
|
||||||
</label>
|
</label>
|
||||||
|
|
||||||
<select class="form-control" tabindex="3" class="cs-select cs-skin-elastic" name="university" ng-model="myUnivSearch" ng-change="getUniveId(myUnivSearch)">
|
<select class="form-control" tabindex="3" class="cs-select cs-skin-elastic" name="university" ng-model="myUnivSearch" ng-change="getUniveId(myUnivSearch)">
|
||||||
<option value="" disabled selected>Select University</option>
|
<option value="" disabled selected>Select University</option>
|
||||||
<option ng-repeat="item in universitySearchData" value="{{item}}">{{item.UniversityName}}</option>
|
<option ng-repeat="item in universitySearchData" value="{{item}}">{{item.UniversityName}}</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
<label for="form-field-select-2">
|
<label for="form-field-select-2">
|
||||||
Session
|
Session
|
||||||
</label>
|
</label>
|
||||||
|
|
||||||
<select ui-select2 class="form-control" tabindex="4" class="cs-select cs-skin-elastic" name="session" ng-model="searchData.Session">
|
<select ui-select2 class="form-control" tabindex="4" class="cs-select cs-skin-elastic" name="session" ng-model="searchData.Session">
|
||||||
<option value="" selected>Select Session</option>
|
<option value="" selected>Select Session</option>
|
||||||
<option ng-repeat="itemSession in sessionData" value="{{itemSession.SessionID}}">{{itemSession.SessionName}}</option>
|
<option ng-repeat="itemSession in sessionData" value="{{itemSession.SessionID}}">{{itemSession.SessionName}}</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-md-2" style="padding-top: 2.3%;">
|
<div class="col-md-2" style="padding-top: 2.3%;">
|
||||||
<div class="pull-right">
|
<div class="pull-right">
|
||||||
|
|
||||||
<button ng-disabled="searchData.Session == '' || searchData.University == ''" type="submit" class="btn btn-success btn-o" tabindex="8">
|
<button ng-disabled="searchData.Session == '' || searchData.University == ''" type="submit" class="btn btn-success btn-o"
|
||||||
|
tabindex="8">
|
||||||
Submit
|
Submit
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<!--{{data | json}}-->
|
<!--{{data | json}}-->
|
||||||
<div ng-if="Searchloader">
|
<div ng-if="Searchloader">
|
||||||
<div align="center">
|
<div align="center">
|
||||||
<h3 style="color: blue;">Loading...</h3></div>
|
<h3 style="color: blue;">Loading...</h3>
|
||||||
|
</div>
|
||||||
<h2> {{statusMessage}} </h2>
|
<h2> {{statusMessage}} </h2>
|
||||||
</div>
|
</div>
|
||||||
<div class="table-responsive" ng-if="studentData">
|
<div class="table-responsive" ng-if="studentData">
|
||||||
@ -183,10 +175,12 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</tab>
|
</tab>
|
||||||
<tab tabindex="2" active="tabactive2" ng-click="tabActive('tabactive2')" heading="Upload Files" id="uploadFiles">
|
<tab tabindex="2" active="tabactive2" ng-click="tabActive('tabactive2')" heading="Upload Details" id="uploadFiles">
|
||||||
|
<tabset id="uploadDetails" class="tabbable">
|
||||||
|
<tab tabindex="1" active="subTabactive1" ng-click="subTabActive('subTabactive1')" heading="Upload File" id="uploadFiles">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-4 form-group">
|
<!--<div class="col-md-4 form-group">
|
||||||
<label>
|
<label>
|
||||||
University <span class="symbol required"></span>
|
University <span class="symbol required"></span>
|
||||||
</label>
|
</label>
|
||||||
@ -194,28 +188,8 @@
|
|||||||
<option value="" selected>Select University</option>
|
<option value="" selected>Select University</option>
|
||||||
<option ng-repeat="univ in universitySearchData" value="{{univ}}">{{univ.UniversityName}}</option>
|
<option ng-repeat="univ in universitySearchData" value="{{univ}}">{{univ.UniversityName}}</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>-->
|
||||||
<div class="col-md-4 form-group">
|
<div class="col-md-6 form-group" ng-if="showFile=='1'">
|
||||||
<label>
|
|
||||||
Upload For <span class="symbol required"></span>
|
|
||||||
</label>
|
|
||||||
<select class="form-control" name="uploadFor" tabindex="2" id="uploadFor"
|
|
||||||
ng-model="uploadModel.uploadFor"
|
|
||||||
ng-options="upload.id as upload.name for upload in uploadOptions"
|
|
||||||
required>
|
|
||||||
<option value=""> Select</option>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div class="col-md-3 form-group" ng-if="showFile=='1'">
|
|
||||||
<fieldset>
|
|
||||||
<js-xls onread="readXlsxDetails" onerror="error"></js-xls>
|
|
||||||
<button type="button" class="btn btn-success btn-o" style="float: right" ng-click="receiveEnrolmentDetails(extractDetails,uploadModel)"> Submit</button>
|
|
||||||
|
|
||||||
</fieldset>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-3 form-group" ng-if="showFile=='2'">
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<js-xls onread="readXlsxFormDetails" onerror="error"></js-xls>
|
<js-xls onread="readXlsxFormDetails" onerror="error"></js-xls>
|
||||||
<button type="button" class="btn btn-success btn-o" style="float: right" ng-click="receiveFormIdFeeDetails(extractFormIDDetails)"> Submit</button>
|
<button type="button" class="btn btn-success btn-o" style="float: right" ng-click="receiveFormIdFeeDetails(extractFormIDDetails)"> Submit</button>
|
||||||
@ -226,6 +200,23 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</tab>
|
</tab>
|
||||||
|
<tab tabindex="2" active="subTabactive2" ng-click="subTabActive('subTabactive2')" heading="Upload Data Manualy" id="uploadDataManualy">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<!--<div class="row">
|
||||||
|
<div class="col-md-4 form-group">
|
||||||
|
<label>
|
||||||
|
University <span class="symbol required"></span>
|
||||||
|
</label>
|
||||||
|
<select class="form-control" tabindex="1" name="formUniversity" ng-model="uploadModel.university" required>
|
||||||
|
<option value="" selected>Select University</option>
|
||||||
|
<option ng-repeat="univ in universitySearchData" value="{{univ}}">{{univ.UniversityName}}</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>-->
|
||||||
|
</div>
|
||||||
|
</tab>
|
||||||
|
</tabset>
|
||||||
|
</tab>
|
||||||
<tab tabindex="3" active="tabactive3" ng-click="tabActive('tabactive3')" heading="Unmatched Records" id="unmatchedRecord">
|
<tab tabindex="3" active="tabactive3" ng-click="tabActive('tabactive3')" heading="Unmatched Records" id="unmatchedRecord">
|
||||||
|
|
||||||
<div class="container">
|
<div class="container">
|
||||||
@ -234,9 +225,7 @@
|
|||||||
<label>
|
<label>
|
||||||
Upload For <span class="symbol required"></span>
|
Upload For <span class="symbol required"></span>
|
||||||
</label>
|
</label>
|
||||||
<select class="form-control" name="uploadFor" tabindex="2" id="uploadFor"
|
<select class="form-control" name="uploadFor" tabindex="2" id="uploadFor" ng-model="getUnmatchedDetailsFor" ng-options="upload.id as upload.name for upload in uploadOptions"
|
||||||
ng-model="getUnmatchedDetailsFor"
|
|
||||||
ng-options="upload.id as upload.name for upload in uploadOptions"
|
|
||||||
required>
|
required>
|
||||||
<option value=""> Select</option>
|
<option value=""> Select</option>
|
||||||
</select>
|
</select>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user