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

class ControllerPinjamanMacet extends CI_Controller
{

    public function __construct()
    {
        parent::__construct();
        check_not_login();
        if ($this->session->userdata('level') != 7) {
            redirect();
        }
        $this->load->library('encrypt');
        $this->load->library('form_validation');
        $this->load->library('mycustom');
        $this->load->library('pdfgenerator');
        $this->load->model('marketing/insert_model');
        $this->load->model('marketing/select_model');
        $this->load->model('marketing/update_model');
        $this->set_timezone();
    }
    public function set_timezone()
    {
        date_default_timezone_set("Asia/Jakarta");
    }
    public function index()
    {
        // Data Login
        $data_login            = $this->userlogin->user_login();
        $data_id_login         = $this->session->userdata('isloggedin');
        // Data Isian Konten
        // Tampilkan Jenis Pinjaman
        $pinjaman_macet        = $this->select_model->vd_PinjamanMacet();
        $data_jaminan          = $this->select_model->vd_jaminanPinjaman();
        $data = array(
            // Untuk memanggil halaman sesuai menu
            'folder'              => 'kegiatan/macet',
            'page'                => 'index',
            'judul'               => 'Pinjaman Macet || Bagian Marketing',
            'data_id_login'       => $data_id_login,
            'data_login'          => $data_login,
            // Isi dalam konten
            'pinjaman_macet'      => $pinjaman_macet,
            'data_jaminan'        => $data_jaminan
        );
        $this->load->view('marketing/index', $data);
    }
}

/* End of file ControllerPinjamanMacet.php and path \application\controllers\marketing\kegiatan\ControllerPinjamanMacet.php */