methods['receiveEnrolmentFromUniv_post']['limit'] = 500; // 500 requests per hour per user/key $this->methods['formIDFeeCompareDetails_post']['limit'] = 500; $this->methods['getUniversitySessionDetails_post']['limit'] = 500; $this->methods['getExistStudentEnrolmentDetails_post']['limit'] = 1000; $this->methods['addManualEnrolmentDetails_post']['limit'] = 1000; $this->methods['addUniversityPaymentDetails_post']['limit'] = 1000; $this->methods['updateUniversityPaymentDetails_post']['limit'] = 1000; // load the model $this->load->model('Receive_Enrolment_Fees_Univ_model', 'receive_model'); } /* * This method used to add received enrolment details * created by kms * */ public function receiveEnrolmentFromUniv_post() { $now = new DateTime(); $now->setTimezone(new DateTimezone('Asia/Kolkata')); $enrolmentDetails = $this->post('details'); $localDetails = $this->post('localDetails'); $fromDetails['CreatedOn'] = $now->format('Y-m-d H:i:s'); $fromDetails['CreatedBy'] = $localDetails['localUserID']; $fromDetails['UniversityCode']=$this->post('universityID'); $fromDetails['UniversityName']=$this->post('universityName'); $fromDetails['BranchCode']=$localDetails['localBranchID']; $updatedDetails = $this->receive_model->updateEnrolmentDetails($enrolmentDetails,$fromDetails);// Check if the users data store contains users (in case the database result returns NULL) if ($updatedDetails['status']) { // Set the response and exit $this->response($updatedDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($updatedDetails['status']==false){ // 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 } } /* * This method used to add formid related student fee details form university * created by kdk * */ public function insertFormIdUnivFeeDetails_post(){ $formIdDetails = $this->post('details'); $localDetails = $this->post('localDetails'); $univDetails = $this->post('univ'); $updatedDetails = $this->receive_model->formIdFeeDetails($formIdDetails,$localDetails, $univDetails);// 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 } } public function getStudentUnivFeeCompareDetails_post(){ $searchData = $this->post('search'); $UniversityID = $this->post('University'); $getUnivStudentFeeCompare = $this->receive_model->getStudentUnivFeeCompareDetails($searchData,$UniversityID);// Check if the users data store contains users (in case the database result returns NULL) if ($getUnivStudentFeeCompare) { $getUnivStudentFeeCompare['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getUnivStudentFeeCompare, 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 } } /* * get form id bases get fees comparsion details * created by kms * */ public function formIDFeeCompareDetails_post(){ $formData['FormID'] = $this->post('formId'); $formData['EnrolmentNo'] = $this->post('enrolmentId');; $getDetails = $this->receive_model->getFormIDFeeDetails($formData); if ($getDetails['formTypeStatus']=true) { // Set the response and exit $this->response($getDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($getDetails['formTypeStatus']=false){ $this->response([ 'message' => $getDetails['Message'], ], REST_Controller::HTTP_OK); // NOT_FOUND (404) being the HTTP response code } else { // Set the response and exit $this->response([ 'message' => 'Something went wrong.please try again!', 'formTypeStatus' => false ], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } public function getUnmatchedRecordDetails_post(){ $getDetailsFor = $this->post('getDetailsFor'); $getUnmatchedFormDetails = $this->receive_model->getUnmatchedFormDetails($getDetailsFor);// Check if the users data store contains users (in case the database result returns NULL) if ($getUnmatchedFormDetails['unMatchedRecordStatus']) { // Set the response and exit $this->response($getUnmatchedFormDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if ($getUnmatchedFormDetails['unMatchedRecordStatus']==false) { // Set the response and exit $this->response($getUnmatchedFormDetails, 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!', 'formTypeStatus' => false ], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } public function getUniversitySessionDetails_post(){ $reqData = $this->post('data'); $loginUserId = $reqData['localUserID']; $loginUserBranchId = $reqData['localBranchID']; $loginUserType = $reqData['localType']; $getUniversityListDetails = $this->receive_model->getUniversitySessionList($loginUserBranchId); // Check if the employee exist if ($getUniversityListDetails['status']) { // $getUniversityListDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getUniversityListDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($getUniversityListDetails['status']==false){ $this->response(['message' => 'No list were found', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } /* * get exist enrolment student details * created by kms * */ public function getExistStudentEnrolmentDetails_post(){ $localData = $this->post('localDetails'); $enrolmentID=$this->post('enrolmentID'); $getEnrolmentDetails=$this->receive_model->getExistStudentEnrolmentDetails($enrolmentID,$localData); if($getEnrolmentDetails['status']==true){ $this->response($getEnrolmentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($getEnrolmentDetails['status']==false){ $this->response($getEnrolmentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else{ $this->response(['message' => 'No list were found', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } /* * add manual enrolment details * cretaed by kms * */ public function addManualEnrolmentDetails_post(){ $now = new DateTime(); $now->setTimezone(new DateTimezone('Asia/Kolkata')); $localData = $this->post('localDetails'); $studentInfo=$this->post('studentInfo'); $semDetails=$this->post('sem'); $studentInfo['CreatedOn'] = $now->format('Y-m-d H:i:s'); $studentInfo['FormID'] = $this->post('formID'); $studentInfo['SemesterYear'] = $semDetails['sem']; $studentInfo['FormType'] = $semDetails['FormType']; $studentInfo['SessionName'] = $semDetails['SessionName']; $studentInfo['EnrolmentNo'] = $this->post('enrolmentID'); $studentInfo['CreatedBy'] = $localData['localUserID']; $studentInfo['BranchCode'] = $localData['localBranchID']; $studentInfo['ManualEntry'] = 1; $addEnrolmentDetails=$this->receive_model->addManualEnrolmentDetails($studentInfo); if($addEnrolmentDetails['status']==true){ $this->response($addEnrolmentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($addEnrolmentDetails['status']==false){ $this->response($addEnrolmentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else{ $this->response(['message' => 'No list were found', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } public function getUnivCourseFromFileDetails_post(){ $reqData = $this->post('data'); $reqBranch = $this->post('reqBranch'); //echo $reqData['localBranchID'];die(); $getUnivCourseFromFileDetails = $this->receive_model->getUnivCourseFromFileDetails($reqData); // Check if the employee exist if ($getUnivCourseFromFileDetails) { $getUnivCourseFromFileDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getUnivCourseFromFileDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // get formid draft mode list details // kdk public function getForFormIdDraftDetails_post(){ $reqBranch = $this->post('localDetails'); $getDetailsFor = $this->post('getDetailsFor'); $getForFormIdDraftDetails = $this->receive_model->getForFormIdDraftDetails($getDetailsFor); // Check if the employee exist if ($getForFormIdDraftDetails) { $getForFormIdDraftDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getForFormIdDraftDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // add formid manual details form the university and draftmode // kdk public function addForFormIdDraftDetails_post(){ $reqBranch = $this->post('localDetails'); $details = $this->post('details'); $univDetails = $this->post('univ'); $addForFormIdDraftDetails = $this->receive_model->addForFormIdDraftDetails($details, $reqBranch, $univDetails); // Check if the employee exist if ($addForFormIdDraftDetails) { $addForFormIdDraftDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($addForFormIdDraftDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // manual formid entry draft details move to the list details // kdk public function draftMovetoList_post(){ $reqBranch = $this->post('localDetails'); $details = $this->post('details'); $draftMovetoList = $this->receive_model->draftMovetoList($details, $reqBranch); // Check if the employee exist if ($draftMovetoList) { $draftMovetoList['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($draftMovetoList, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // edit draft mode formid manul entry details // kdk public function editDraftFormIdFeesDetails_post(){ $reqBranch = $this->post('localDetails'); $details = $this->post('details'); $detailsID = $this->post('detailsID'); $details = $this->post('details'); $editDraftFormIdFeesDetails = $this->receive_model->editDraftFormIdFeesDetails($reqBranch, $details, $detailsID); // Check if the employee exist if ($editDraftFormIdFeesDetails) { $editDraftFormIdFeesDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($editDraftFormIdFeesDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // get formid , fee details form the file upload for the university , course, student // kdk public function getStudentUnivFormIdFeeDatailsList_post(){ $reqBranchData = $this->post('data'); $searchDetails = $this->post('search'); $getStudentUnivFormIdFeeDatailsList = $this->receive_model->getStudentUnivFormIdFeeDatailsList($reqBranchData, $searchDetails); // Check if the employee exist if ($getStudentUnivFormIdFeeDatailsList) { $getStudentUnivFormIdFeeDatailsList['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getStudentUnivFormIdFeeDatailsList, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // get formid status list for that particular record // kdk public function getFormIdDetailsStatusUpdateList_post(){ $reqBranchData = $this->post('localDetails'); $statusDetailsId = $this->post('detailsID'); $getFormIdDetailsStatusUpdateList = $this->receive_model->getFormIdDetailsStatusUpdateList($reqBranchData, $statusDetailsId); // Check if the employee exist if ($getFormIdDetailsStatusUpdateList) { $getFormIdDetailsStatusUpdateList['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getFormIdDetailsStatusUpdateList, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // add formid list file status list for that record // kdk public function insertStatusUpdateDetails_post(){ $reqBranchData = $this->post('localDetails'); $statusDetails = $this->post('details'); $id = $this->post('id'); $formId = $this->post('formId'); $insertStatusUpdateDetails = $this->receive_model->insertStatusUpdateDetails($reqBranchData, $statusDetails, $id, $formId ); // Check if the employee exist if ($insertStatusUpdateDetails) { $insertStatusUpdateDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($insertStatusUpdateDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } public function getUniversityCodeForFormDetailsGet_post(){ $reqData = $this->post('data'); $loginUserId = $reqData['localUserID']; $loginUserBranchId = $reqData['localBranchID']; $loginUserType = $reqData['localType']; $getUniversityListDetails = $this->receive_model->get_university_list($loginUserBranchId); // Check if the employee exist if ($getUniversityListDetails) { $getUniversityListDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getUniversityListDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // get unmatched records of the formid file details , compare with file 1 // kdk public function getUnmatchedFormIdFeesDetails_post(){ $localDetails = $this->post('localDetails'); $getDetailsFor = $this->post('getDetailsFor'); $getUnmatchedFormIdFeesDetails = $this->receive_model->getUnmatchedFormIdFeesDetails($localDetails, $getDetailsFor); // Check if the employee exist if ($getUnmatchedFormIdFeesDetails) { $getUnmatchedFormIdFeesDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($getUnmatchedFormIdFeesDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } // add fromid university amount details to account state // kdk public function addToAccountStateList_post(){ $localDetails = $this->post('localDetails'); $getDetailsFor = $this->post('details'); $addFormIdListToAccountState = $this->receive_model->addFormIdListToAccountState($localDetails, $getDetailsFor); // Check if the employee exist if ($addFormIdListToAccountState) { $addFormIdListToAccountState['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($addFormIdListToAccountState, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response(['message' => 'No list were found', 'status' => REST_Controller::HTTP_NOT_FOUND], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } /* * get payment verfication details * created by kms * */ public function paymentVerficationDetails_post(){ $fromDetails['UniversityCode']=$this->post('universityID'); $fromDetails['UniversityName']=$this->post('universityName'); $getVerificationDetails=$this->receive_model->getPaymentVerificationDetails($fromDetails); if($getVerificationDetails['status']==true){ $this->response($getVerificationDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($getVerificationDetails['status']==false){ $this->response($getVerificationDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else{ $this->response(['details' => 'No list were found', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } /* * add university payment details * created by kms * */ public function addUniversityPaymentDetails_post(){ $now = new DateTime(); $now->setTimezone(new DateTimezone('Asia/Kolkata')); $details=$this->post('details'); $localData=$this->post('localDetails'); $fromDetails['BillNo']=$details['billNo']; $fromDetails['ReceiptNo']=$details['receiptNo']; $fromDetails['Amount']=$details['billAmount']; $fromDetails['ApprovedDate']=$details['date']; $fromDetails['UniversityCode']=$details['universityCode']; $fromDetails['UniversityName']=$details['universityName']; $fromDetails['Remarks']=$details['comments']; $fromDetails['BranchCode']=$localData['localBranchID']; $fromDetails['CreatedBy']=$localData['localUserID']; $fromDetails['CreatedOn']=$now->format('Y-m-d H:i:s'); $addPaymentDetails=$this->receive_model->addPaymentDetails($fromDetails); if($addPaymentDetails['status']==true){ $this->response($addPaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($addPaymentDetails['status']==false){ $this->response($addPaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else{ $this->response(['message' => 'Try again', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } /* * update university payment details*/ public function updateUniversityPaymentDetails_post(){ $now = new DateTime(); $now->setTimezone(new DateTimezone('Asia/Kolkata')); $details=$this->post('details'); $localData=$this->post('localDetails'); $update['ID']=$details['ID']; $update['PaymentID']=$details['paymentID']; $payment['BillNo']=$details['billNo']; $payment['ReceiptNo']=$details['receiptNo']; $payment['Amount']=$details['billAmount']; $payment['ApprovedDate']=$details['date']; $payment['Remarks']=$details['comments']; $payment['BranchCode']=$localData['localBranchID']; $payment['updatedBy']=$localData['localUserID']; $payment['updatedOn']=$now->format('Y-m-d H:i:s'); // debit array $debit['DebitAmount']=$details['billAmount']; $debit['ApprovedDate']=$details['date']; $debit['BranchCode']=$localData['localBranchID']; $debit['updatedBy']=$localData['localUserID']; $debit['updatedOn']=$now->format('Y-m-d H:i:s'); $updatePaymentDetails=$this->receive_model->updatePaymentDetails($update,$payment,$debit); if($updatePaymentDetails['status']==true){ $this->response($updatePaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else if($updatePaymentDetails['status']==false){ $this->response($updatePaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else{ $this->response(['message' => 'Try again', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } }