<?php

defined('BASEPATH') or exit('No direct script access allowed');

/* * *****************Welcome.php**********************************
 * @product name    : Hospital Management System
 * @type            : Class
 * @class name      : Welcome
 * @description     : This is default class of the application.  
 * @author          : South Bangla IT Zone Team 	
 * @url             : http://hms.sbitzone.com    
 * @support         : rabibd.it@gmail.com	
 * @copyright       : South Bangla IT Zone Team		
 * ********************************************************** */

class Welcome extends CI_Controller {

	public function __construct() {
		parent::__construct();
		$this->load->model('Profile_Model', 'profile', true);
	}

	/*     * **************Function index**********************************
     * @type            : Function
     * @function name   : index
     * @description     : this function load login view page            
     * @param           : null; 
     * @return          : null 
     * ********************************************************** */
	public function index() {

		if (logged_in_user_id()) {
			redirect('dashboard');
		}
		$this->data['sliders'] = $this->profile->get_list('sliders', array('type' => 'login', 'is_view_on_web' => 1), '', '', '', 'sort_by', 'ASC');
		$this->global_setting = $this->db->get_where('global_setting', array('status' => 1))->row();
		$this->load->view('login', $this->data);
	}
}
