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

class Tab_pemeriksaan_persiapan extends CI_Controller {
	function index(){
		$data['enc'] = $this->nativesession->get_flash_session('enc');
		$data['idperkara'] = $this->encrypt->decode(base64_decode($data['enc']));
		$idperkara = $this->encrypt->decode(base64_decode($data['enc']));
		$this->load->model('perkara/pemeriksaan_persiapan_m','perkara');
		$data['lastUrutan'] = $this->perkara->getLastUrutanProses($idperkara);		
		$data['persiapanProses'] = $this->perkara->getPersiapanProses($idperkara);
		$tglPendaftaran = $this->perkara->getTanggalPendaftaran($idperkara);
		foreach($tglPendaftaran->result() as $row){
			$data['tanggalPendaftaranPerkara'] = $row->tanggal_pendaftaran;
		}
		$persiapanPemeriksaan = $this->perkara->getPemeriksaanPersiapan($idperkara);
		foreach($persiapanPemeriksaan->result() as $row){
			$data['tanggalPenetapanPersiapan'] = $this->tanggalhelper->convertDayDate($row->tanggal_penetapan_persiapan);
			$data['prositaPetitum'] = $row->petitum;
			$data['petitumDokumen'] = $row->petitum_dok;
		}
		$this->load->vars($data);
		$this->load->view('perkara_tab/pemeriksaan_persiapan/pemeriksaan_persiapan_tab');
	}
}
