This commit is contained in:
resicovenba 2017-11-28 20:49:12 +05:30
commit ddc523d71d
3 changed files with 20 additions and 10 deletions

View File

@ -58,30 +58,35 @@ $route['translate_uri_dashes'] = TRUE;
| Sample REST API Routes | Sample REST API Routes
| ------------------------------------------------------------------------- | -------------------------------------------------------------------------
*/ */
$route['autenticadors'] = 'autenticador/index'; // Example 4
$route['login'] = 'Login_Controller/login'; $route['login'] = 'Login_Controller/login';
// branch
$route['getMasterBranchDetails'] = 'Employee_Controller/getMasterBranchDetails';
$route['addBranchDetails'] = 'Branch_Controller/addBranchDetails';
$route['getBranchDetails'] = 'Branch_Controller/getBranchDetails';
$route['updateBranchDetails'] = 'Branch_Controller/updateBranchDetails';
// staff
$route['employee'] = 'Employee_Controller/employee'; $route['employee'] = 'Employee_Controller/employee';
$route['getEmployeeList'] = 'Employee_Controller/getEmployeeList'; $route['getEmployeeList'] = 'Employee_Controller/getEmployeeList';
$route['getRoleDetails'] = 'Employee_Controller/getRoleDetails'; $route['getRoleDetails'] = 'Employee_Controller/getRoleDetails';
$route['getMasterBranchDetails'] = 'Employee_Controller/getMasterBranchDetails';
$route['chkEmpExistDetail'] = 'Employee_Controller/check_exist'; $route['chkEmpExistDetail'] = 'Employee_Controller/check_exist';
$route['insertEmployee'] = 'Employee_Controller/addEmployee'; $route['insertEmployee'] = 'Employee_Controller/addEmployee';
$route['chkUpdateEmpExistDetail'] = 'Employee_Controller/check_update_exist'; $route['chkUpdateEmpExistDetail'] = 'Employee_Controller/check_update_exist';
$route['updateEmpExistDetail'] = 'Employee_Controller/updateEmployee'; $route['updateEmpExistDetail'] = 'Employee_Controller/updateEmployee';
$route['getEmpBranchDetails'] = 'Employee_Controller/getEmpBranchDetails'; $route['getEmpBranchDetails'] = 'Employee_Controller/getEmpBranchDetails';
$route['updateEmpBranchDetail'] = 'Employee_Controller/updateEmpBranchDetail'; $route['updateEmpBranchDetail'] = 'Employee_Controller/updateEmpBranchDetail';
$route['autenticadors'] = 'autenticador/index'; // Example 4 // call tracking
$route['addBranchDetails'] = 'Branch_Controller/addBranchDetails';
$route['getBranchDetails'] = 'Branch_Controller/getBranchDetails';
$route['updateBranchDetails'] = 'Branch_Controller/updateBranchDetails';
$route['getTrackingLeadDetails'] = 'Call_Tracking_Controller/getTrackingLeadDetails'; $route['getTrackingLeadDetails'] = 'Call_Tracking_Controller/getTrackingLeadDetails';
$route['addLeadTrackingDetails'] = 'Call_Tracking_Controller/addLeadTrackingDetails'; $route['addLeadTrackingDetails'] = 'Call_Tracking_Controller/addLeadTrackingDetails';
$route['getTrackingDetails'] = 'Call_Tracking_Controller/getTrackingDetails'; $route['getTrackingDetails'] = 'Call_Tracking_Controller/getTrackingDetails';
$route['updateFollowupDetails'] = 'Call_Tracking_Controller/updateFollowupDetails'; $route['updateFollowupDetails'] = 'Call_Tracking_Controller/updateFollowupDetails';
$route['loadFollowupDetails'] = 'Call_Tracking_Controller/loadFollowupDetails'; $route['loadFollowupDetails'] = 'Call_Tracking_Controller/loadFollowupDetails';
// university
$route['insertUniversity'] = 'University_Controller/insertUniversity'; $route['insertUniversity'] = 'University_Controller/insertUniversity';
$route['getUniversity'] = 'University_Controller/getUniversity'; $route['getUniversity'] = 'University_Controller/getUniversity';
$route['chkUnivIdExistDetail'] = 'University_Controller/chkUnivIdExistDetail'; $route['chkUnivIdExistDetail'] = 'University_Controller/chkUnivIdExistDetail';
$route['updateUniversityDetail'] = 'University_Controller/updateUniversityDetail'; $route['updateUniversityDetail'] = 'University_Controller/updateUniversityDetail';
//course
$route['getCourseDetails'] = 'Course_Controller/getCourseDetails'; $route['getCourseDetails'] = 'Course_Controller/getCourseDetails';
$route['addCourseDetails'] = 'Course_Controller/addCourseDetails'; $route['addCourseDetails'] = 'Course_Controller/addCourseDetails';
$route['updateCourseDetails'] = 'Course_Controller/updateCourseDetails'; $route['updateCourseDetails'] = 'Course_Controller/updateCourseDetails';
@ -104,6 +109,11 @@ $route['getStudentCourseList'] = 'Student_Controller/getStudentCourseList';
$route['getStudentCourseDetails'] = 'Student_Controller/getStudentCourseDetails'; $route['getStudentCourseDetails'] = 'Student_Controller/getStudentCourseDetails';
$route['updateStudentCourseDetail'] = 'Student_Controller/updateStudentCourseDetail'; $route['updateStudentCourseDetail'] = 'Student_Controller/updateStudentCourseDetail';
//batch
$route['addBatchDetails'] = 'Batch_Controller/addBatchDetails';
$route['updateBatchDetails'] = 'Batch_Controller/updateBatchDetails';
$route['getBatchDetails'] = 'Batch_Controller/getBatchDetails';

View File

@ -20,11 +20,11 @@ class Batch_model extends CI_Model {
$this->db->select('BatchCode'); $this->db->select('BatchCode');
$this->db->where('BatchCode', $arrayDetails['BatchCode']); $this->db->where('BatchCode', $arrayDetails['BatchCode']);
if($this->db->get(T_BATCHMASTER)->first_row()){ if($this->db->get(BATCH)->first_row()){
$result['batchStatus'] = false; $result['batchStatus'] = false;
$result['message'] = "This batch Code is already exist!"; $result['message'] = "This batch Code is already exist!";
} else { } else {
$this->db->insert(T_BATCHMASTER, $arrayDetails); $this->db->insert(BATCH, $arrayDetails);
if ($this->db->affected_rows() == '1') { if ($this->db->affected_rows() == '1') {
$result['batchStatus'] = true; $result['batchStatus'] = true;
@ -48,7 +48,7 @@ class Batch_model extends CI_Model {
public function getBatch() public function getBatch()
{ {
$this->db->select('CU.BatchCode,CU.BatchName,CU.IsActive,US.UniversityID,US.UniversityName'); $this->db->select('CU.BatchCode,CU.BatchName,CU.IsActive,US.UniversityID,US.UniversityName');
$this->db->from(T_BATCHMASTER.' as CU'); $this->db->from(BATCH.' as CU');
$this->db->join(UNIVERSITY.' as US', 'US.UniversityID = CU.UniversityID'); $this->db->join(UNIVERSITY.' as US', 'US.UniversityID = CU.UniversityID');
$this->db->order_by('CU.CreatedOn','DESC'); $this->db->order_by('CU.CreatedOn','DESC');
$batchDetails = $this->db->get(); $batchDetails = $this->db->get();
@ -76,7 +76,7 @@ class Batch_model extends CI_Model {
public function updateBatch($arrayDetails=null) public function updateBatch($arrayDetails=null)
{ {
$this->db->where('BatchCode',$arrayDetails['BatchCode']); $this->db->where('BatchCode',$arrayDetails['BatchCode']);
$upateStatus=$this->db->update(T_BATCHMASTER, $arrayDetails); $upateStatus=$this->db->update(BATCH, $arrayDetails);
if($upateStatus){ if($upateStatus){
$result['batchStatus'] = true; $result['batchStatus'] = true;

View File

@ -71,7 +71,7 @@ class Course_model extends CI_Model {
$this->db->select('CU.CourseID,CU.CourseName,CU.FeesType,CU.PC,CU.DC,CU.TC,CU.MC,CU.OtherFees,CU.IsActive,US.UniversityID,US.UniversityName'); $this->db->select('CU.CourseID,CU.CourseName,CU.FeesType,CU.PC,CU.DC,CU.TC,CU.MC,CU.OtherFees,CU.IsActive,US.UniversityID,US.UniversityName');
$this->db->from(COURSE.' as CU'); $this->db->from(COURSE.' as CU');
$this->db->join(UNIVERSITY.' as US', 'US.UniversityID = CU.UniversityID'); $this->db->join(UNIVERSITY.' as US', 'US.UniversityID = CU.UniversityID');
$this->db->order_by('CourseID','DESC'); $this->db->order_by('CU.CreatedOn','DESC');
$courseDetails = $this->db->get(); $courseDetails = $this->db->get();
if($courseDetails->result()){ if($courseDetails->result()){