diff --git a/application/controllers/customers.php b/application/controllers/customers.php index a025d3ce2..9d5de6687 100644 --- a/application/controllers/customers.php +++ b/application/controllers/customers.php @@ -9,14 +9,15 @@ class Customers extends Person_controller function index() { - $config['base_url'] = site_url('?c=customers&m=index'); + $config['base_url'] = site_url('/customers/index'); $config['total_rows'] = $this->Customer->count_all(); - $config['per_page'] = '20'; + $config['per_page'] = '20'; + $config['uri_segment'] = 3; $this->pagination->initialize($config); $data['controller_name']=strtolower(get_class()); $data['form_width']=$this->get_form_width(); - $data['manage_table']=get_people_manage_table($this->Customer->get_all($config['per_page'], $this->input->get('per_page')),$this); + $data['manage_table']=get_people_manage_table( $this->Customer->get_all( $config['per_page'], $this->uri->segment( $config['uri_segment'] ) ), $this ); $this->load->view('people/manage',$data); } diff --git a/application/controllers/employees.php b/application/controllers/employees.php index 748dda0ca..aa80b1979 100644 --- a/application/controllers/employees.php +++ b/application/controllers/employees.php @@ -9,14 +9,15 @@ class Employees extends Person_controller function index() { - $config['base_url'] = site_url('?c=employees&m=index'); + $config['base_url'] = site_url('/employees/index'); $config['total_rows'] = $this->Employee->count_all(); - $config['per_page'] = '20'; + $config['per_page'] = '20'; + $config['uri_segment'] = 3; $this->pagination->initialize($config); $data['controller_name']=strtolower(get_class()); $data['form_width']=$this->get_form_width(); - $data['manage_table']=get_people_manage_table($this->Employee->get_all($config['per_page'], $this->input->get('per_page')),$this); + $data['manage_table']=get_people_manage_table( $this->Employee->get_all( $config['per_page'], $this->uri->segment( $config['uri_segment'] ) ), $this ); $this->load->view('people/manage',$data); } diff --git a/application/controllers/giftcards.php b/application/controllers/giftcards.php index b256eb91b..eadde440b 100644 --- a/application/controllers/giftcards.php +++ b/application/controllers/giftcards.php @@ -10,14 +10,15 @@ class Giftcards extends Secure_area implements iData_controller function index() { - $config['base_url'] = site_url('?c=giftcards&m=index'); + $config['base_url'] = site_url('/giftcards/index'); $config['total_rows'] = $this->Giftcard->count_all(); - $config['per_page'] = '20'; + $config['per_page'] = '20'; + $config['uri_segment'] = 3; $this->pagination->initialize($config); $data['controller_name']=strtolower(get_class()); $data['form_width']=$this->get_form_width(); - $data['manage_table']=get_giftcards_manage_table($this->Giftcard->get_all($config['per_page'], $this->input->get('per_page')),$this); + $data['manage_table']=get_giftcards_manage_table( $this->Giftcard->get_all( $config['per_page'], $this->uri->segment( $config['uri_segment'] ) ), $this ); $this->load->view('giftcards/manage',$data); } diff --git a/application/controllers/item_kits.php b/application/controllers/item_kits.php index ddbc31575..518bcfd5d 100644 --- a/application/controllers/item_kits.php +++ b/application/controllers/item_kits.php @@ -10,14 +10,15 @@ class Item_kits extends Secure_area implements iData_controller function index() { - $config['base_url'] = site_url('?c=item_kits&m=index'); + $config['base_url'] = site_url('/item_kits/index'); $config['total_rows'] = $this->Item_kit->count_all(); - $config['per_page'] = '20'; + $config['per_page'] = '20'; + $config['uri_segment'] = 3; $this->pagination->initialize($config); $data['controller_name']=strtolower(get_class()); $data['form_width']=$this->get_form_width(); - $data['manage_table']=get_item_kits_manage_table( $this->Item_kit->get_all($config['per_page'], $this->input->get('per_page')),$this); + $data['manage_table']=get_item_kits_manage_table( $this->Item_kit->get_all( $config['per_page'], $this->uri->segment( $config['uri_segment'] ) ), $this ); $this->load->view('item_kits/manage',$data); } diff --git a/application/controllers/suppliers.php b/application/controllers/suppliers.php index eafcb9905..684e4c685 100644 --- a/application/controllers/suppliers.php +++ b/application/controllers/suppliers.php @@ -9,14 +9,15 @@ class Suppliers extends Person_controller function index() { - $config['base_url'] = site_url('?c=suppliers&m=index'); + $config['base_url'] = site_url('/suppliers/index'); $config['total_rows'] = $this->Supplier->count_all(); - $config['per_page'] = '20'; + $config['per_page'] = '20'; + $config['uri_segment'] = 3; $this->pagination->initialize($config); $data['controller_name']=strtolower(get_class()); $data['form_width']=$this->get_form_width(); - $data['manage_table']=get_supplier_manage_table($this->Supplier->get_all($config['per_page'], $this->input->get('per_page')),$this); + $data['manage_table']=get_supplier_manage_table( $this->Supplier->get_all( $config['per_page'], $this->uri->segment( $config['uri_segment'] ) ), $this ); $this->load->view('suppliers/manage',$data); }