<?php

class Satusehat_kirim_data_otomatis extends CI_Controller {

	public function __construct()
	{
		parent::__construct();

		$this->load->model('data_pasien_model');
		$this->load->model('data_pendaftaran_model');
		$this->load->model('data_pemeriksaan_model');
		$this->load->model('api_satusehat_model');
		$this->load->model('satusehat_data_encounter_model');
		$this->load->model('pengaturan_model');

		$this->load->model('asset_menu_class_model');
		$this->load->model('paging_model');				
		$this->load->model('select_model');		

		$this->url_controller = $this->uri->segment(1);
		$this->navigation = '_top_not_nav';
	}

	public function index()
	{
		$this->load->view($this->navigation.'/body');
	}

	public function page()
	{		
		$this->load->view($this->url_controller.'/page');
	}	

	public function tabel_eror()
	{
		$service_name = $this->input->post('service_name');

		$this->load->view($this->url_controller.'/tabel_'.$service_name);
	}		

	public function tabel()
	{
		$context_data = array(		
			'service_name' => $this->input->post('service_name')
		);

		$get_data = $this->data_pemeriksaan_model->tabel_all_satusehat($context_data);

		echo json_encode($get_data);
	}
}

?>