Example #1
0
 function get_category_op($q = array(), $type = 'arr')
 {
     $this->db->select('*');
     $this->db->where($q);
     $query = $this->db->get($this->table);
     return Product::row_as($query, $type);
 }
Example #2
0
 function get_product_view($q, $type = 'arr')
 {
     $this->db->select('*');
     $this->db->from($this->view);
     $this->db->where($q);
     $this->db->join('price', 'price_product_id = product_id');
     $query = $this->db->get();
     return Product::row_as($query, $type);
 }