function delete_by_parent($catalogue_id, $id) { $id = $this->uri->segment(5); $catalogue_id = $this->uri->segment(4); $lands = new Land($id); if (!$lands->exists()) { show_404(); } $lands->delete(); flash_message('success', 'Xóa thành công.'); redirect($this->admin . 'lands/list_by_parent/' . $catalogue_id); }