<?php

 class Link_documento_model extends CI_Model{

     
     public function get_links($per_page, $offset) {
        
         $this->db->order_by('id_link_documento', 'desc')
                ->limit($per_page, $offset);
         
        return $this->db->get('link_documento');
     }
     
    
    public function get_count_links() {

        $this->db->select('l.*');
        $this->db->from('link_documento as l');

        return $this->db->get()->num_rows();
    }
     
    
}

?>
