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

class ModelDesa extends CI_Model
{

    public function __construct()
    {
        parent::__construct();
        //Codeigniter : Write Less Do More
    }

    public function get_data()
    {
        return $this->db->get_where("desa")->result();
    }

    public function get_data_edit($id)
    {
        return $this->db->get_where("desa", array("id_desa" => $id))->row_array();
    }

    public function count_desa()
    {
        return $this->db->count_all("desa");
    }
    
}