This commit is contained in:
gandhimathi 2018-08-28 18:47:55 +05:30
commit 6c259bf0fb
9 changed files with 142 additions and 34 deletions

View File

@ -344,3 +344,4 @@ $route['getApplicationFormStatusList'] = 'StatusUpdation_Controller/getApplicati
// update university enrolment and fees details received
$route['receiveEnrolmentFromUniv'] = 'Receive_Enrolment_Fees_Univ_Controller/receiveEnrolmentFromUniv';
$route['insertFormIdUnivFeeDetails'] = 'Receive_Enrolment_Fees_Univ_Controller/insertFormIdUnivFeeDetails';

View File

@ -65,5 +65,25 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller {
}
public function insertFormIdUnivFeeDetails_post(){
$formIdDetails = $this->post('details');
$localDetails = $this->post('localDetails');
$updatedDetails = $this->receive_model->formIdFeeDetails($formIdDetails,$localDetails);// Check if the users data store contains users (in case the database result returns NULL)
if ($updatedDetails)
{
$updatedDetails['status'] = REST_Controller::HTTP_OK;
// Set the response and exit
$this->response($updatedDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code
}
else
{
// Set the response and exit
$this->response([
'message' => 'Something went wrong.please try again!',
'status' => REST_Controller::HTTP_NOT_FOUND
], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code
}
}
}

View File

@ -272,6 +272,60 @@ class Receive_Enrolment_Fees_Univ_model extends CI_Model {
return false;
}
public function formIdFeeDetails($formFeeDetails=null,$local=null){
// print_r($formFeeDetails);exit();
foreach ($formFeeDetails as $formIdDetails){
// echo $formIdDetails['FormId'];
$this->db->select('*');
$this->db->from('T_Enrolment_Received_From_University');
$this->db->where('FormID', $formIdDetails['FormId']);
$detailsList = $this->db->get();
if($detailsList->result() == 1){
// $this->db->select('*');
// $this->db->from('T_FormId_FeeDetails_Received_From_University');
// $this->db->where('FormID', $formIdDetails['FormId']);
// $FormIDdetailsList = $this->db->get();
// $dbDetailsArr = array();
// $dbDetailsArr['FormID'] = $formIdDetails['FormId'];
// $dbDetailsArr['FormType'] = $formIdDetails['Form Type'];
// $dbDetailsArr['CentreCode'] = $formIdDetails['CentreCode'];
// $dbDetailsArr['CourseCode'] = $formIdDetails['Course_Code'];
// $dbDetailsArr['ActualCourseFee'] = $formIdDetails['Actual_Course_Fee'];
// $dbDetailsArr['CourseFee'] = $formIdDetails['Course_Fee'];
// $dbDetailsArr['ExamFee'] = $formIdDetails['Exam_Fee'];
// $dbDetailsArr['EnrollmentFee'] = $formIdDetails['Enrollment_Fee'];
// $dbDetailsArr['ProspectusFee'] = $formIdDetails['Prospectus_Fee'];
// $dbDetailsArr['ReRegFee'] = $formIdDetails['Re_Reg_Fee'];
// $dbDetailsArr['CreditTransferFee'] = $formIdDetails['Credit_Transfer_Fee'];
// $dbDetailsArr['LateralEntryFee'] = $formIdDetails['Lateral_Entry_Fee'];
// $dbDetailsArr['DualSpclFee'] = $formIdDetails['Dual_Spcl_Fee'];
// $dbDetailsArr['OtherFee'] = $formIdDetails['Other_Fee'];
// $dbDetailsArr['NRIFEE'] = $formIdDetails['NRI_FEE'];
// $dbDetailsArr['ProvisionalFee'] = $formIdDetails['Provisional_Fee'];
// $dbDetailsArr['MigrationFee'] = $formIdDetails['Migration_Fee'];
// $dbDetailsArr['UrgentResultDMCFee'] = $formIdDetails['Urgent_Result_DMC_Fee'];
// $dbDetailsArr['AdditionalFee'] = $formIdDetails['Additional_Fee'];
// $dbDetailsArr['Amount'] = $formIdDetails['Amount'];
// // $dbDetailsArr['BranchCode'] = $formIdDetails['FormId'];
// if($FormIDdetailsList->result()){
// $ids = $FormIDdetailsList->result();
// $this->db->where('ID', $ids['ID']);
// $this->db->update('T_FormId_FeeDetails_Received_From_University', $dbDetailsArr);
// } else {
// print_r($dbDetailsArr);exit();
// $this->db->insert('T_FormId_FeeDetails_Received_From_University', $dbDetailsArr);
// $this->db->affected_rows();
// }
} else{
}
}
return 'true';
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

View File

@ -2324,28 +2324,14 @@ app.controller('FeesModalInstanceCtrl', ["$scope", "$modalInstance", "$timeout",
$scope.printPdf = function (print) {
var innerContents = document.getElementById(print).innerHTML;
var popupWinindow = window.open('', '_blank', 'width=1200,height=700,scrollbars=no,menubar=no,toolbar=no,location=no,status=no,titlebar=no');
popupWinindow.document.open();
popupWinindow.document.write('<html>');
popupWinindow.document.write('<style type="text/css" media="print">');
popupWinindow.document.write('@page { size: portrait; }');
//popupWinindow.document.write('.title{border:3px solid black;}');
popupWinindow.document.write('</style>');
popupWinindow.document.write(innerContents);
popupWinindow.document.write('</br>');
popupWinindow.document.write('</br>');
popupWinindow.document.write('</br>');
popupWinindow.document.write('</br>');
popupWinindow.document.write(innerContents);
popupWinindow.document.write('</html>');
popupWinindow.document.close();
popupWinindow.focus();
popupWinindow.print();
popupWinindow.close();
var printHtml = document.getElementById(print).outerHTML;
//var currentPage = document.body.innerHTML;
var elementPage = '<html><head><style type="text/css" media="print">@media print {#Header, #Footer { display:none !important; }}</style></head><body>' + printHtml + '<br><br>' + printHtml + '</body>';
document.body.innerHTML = elementPage;
window.print();
document.body.innerHTML = elementPage;
window.location.reload();
document.close();
}
// $scope.mouseLeave = function(){

View File

@ -189,4 +189,46 @@ app.controller('student_university_fee_compareCtrl', ["$scope", "toaster", "$fil
}
// end
$scope.readXlsxFormDetails = function (workbook) {
$scope.extractFormIDDetails="";
/* 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.extractFormIDDetails=jsonData;
}
}
$scope.error = function (e) {
/* DO SOMETHING WHEN ERROR IS THROWN */
//console.log(e);
}
}
$scope.receiveFormIdFeeDetails = function(details) {
console.log(details);
var updateUniversityEnrolment = {
method: 'POST',
url: apiPoint.url + 'insertFormIdUnivFeeDetails/',
headers: {
'Content-Type': 'application/json'
},
data: {
localDetails: localDetail,
details: details
}
};
$http(updateUniversityEnrolment).then(function (response) {
if (response.data.branchListStatus == true) {
swal("", "Updated Successfully", "success");
} else {
swal("", "Failed", "error");
}
});
}
}]);

View File

@ -1182,12 +1182,12 @@
</a>
</li>
<!--
<li ui-sref-active="active" ng-if="is_active_DayBookAprlAccess == '1'">
<a ui-sref="app.daybooksuperadmin.datacorrection" ng-click="checkStaff()">
<span class="title" translate="sidebar.nav.daybook.DATACORRECTION"> DATA CORRECTION</span>
</a>
</li>
</li> -->

View File

@ -448,32 +448,32 @@
</table>
<div id="print" after-render="printPdf">
<div id="print" pdf-save-content="{{billNo}}" after-render="printPdf">
<div ng-if="myPdfView">
<table style="border-collapse: collapse; color: black;" border="0" width="100%">
<tbody class="title" style="border:3px solid black;">
<tr style="height: 23px;">
<td ng-if="BranchLogo=='' || BranchLogo==null" style="width: 136px; height: 82px; color: white; font-size: 22px; text-align: center;" rowspan="3">
<tr class="title-row" style="height: 15px;">
<td class="title-branch" ng-if="BranchLogo=='' || BranchLogo==null" style="width: 136px; height: 82px; color: white; font-size: 22px; text-align: center;" rowspan="3">
<div class="user-image">
<img class="pull-center" ng-src="assets/images/logo.png" alt="APP">
<img class="pull-center" ng-src="assets/images/logo1.png" alt="APP">
<!-- <img ng-src="{{userInfo.avatar}}" alt="" ng-if="!obj.flow.files.length && !noImage">
<img flow-img="obj.flow.files[0]" ng-if="obj.flow.files.length">-->
</div>
</td>
<td ng-if="BranchLogo!='' && BranchLogo!=null" style="width: 136px; height: 82px; color: white; font-size: 22px; text-align: center;" rowspan="3">
<td class="title-branch" ng-if="BranchLogo!='' && BranchLogo!=null" style="width: 136px; height: 82px; color: white; font-size: 22px; text-align: center;" rowspan="3">
<div class="user-image">
<img class="pull-center" ng-src="images/{{BranchLogo}}" alt="APP">
<!-- <img ng-src="{{userInfo.avatar}}" alt="" ng-if="!obj.flow.files.length && !noImage">
<img flow-img="obj.flow.files[0]" ng-if="obj.flow.files.length">-->
</div>
</td>
<div>
<td style="width: 136px; height: 23px; text-align: center; color: black; font-size: 20px;" colspan="3"><strong><!--APOLLO DISTANCE EDUCATION COLLEGE-->{{FeesReceiptTitle}}</strong>
</div>
<td class="title-addr" style="width: 500px; height: 23px; text-align: center; color: black; font-size: 20px;" colspan="3" ><strong><!--APOLLO DISTANCE EDUCATION COLLEGE-->{{FeesReceiptTitle || "APOLLO DISTANCE EDUCATION COLLEGE"}}</strong>
</br>
<!--<span style="font-size: 16px;">(A Group of SVE Trust)</span>
</br>-->
<span style="white-space:pre-wrap;font-size: 16px;">{{BranchAddr}}</span>
<span style="font-size: 16px;text-align:left;">{{BranchAddr}}</span>
</td>
</tr>
@ -524,7 +524,7 @@
<td style="width: 137px; height: 110px;"><strong style="font-size: 12px;">For APOLLO DISTANCE EDUCATION COLLEGE</strong></td>
</tr>
<tr class="title" style="border:3px solid black;height: 42px;">
<td style="width: 136px; height: 42px; color: black; font-size: 14px;text-align: center;" colspan="4">Note: Terms & Conditions will be applicable as per University norms Fees once paid will not be refunded at any reasons</td>
<td style="width: 136px; height: 42px; color: black; font-size: 12px;text-align: center;" colspan="4">Note: Terms & Conditions will be applicable as per University norms Fees once paid will not be refunded at any reasons</td>
</tr>
</tbody>

View File

@ -100,6 +100,11 @@
</div>
<div class="container-fluid">
<js-xls onread="readXlsxFormDetails" onerror="error"></js-xls>
<button type="button" class="btn btn-success btn-o" ng-click="receiveFormIdFeeDetails(extractFormIDDetails)"> Submit</button>
</div>
</tab>
</tabset>
</div>