Raise limit to number of reports on map


#1

We'd like to show all reports on the map at once, and not have them in chunks of 20 or 50. I found in the database where to manually edit that number, but even then the most it will accept is 100, and if any change is made to the settings page, it changes the field back to whatever is in the pulldown on the settings page. Any idea how to change this so that 200-300 reports can be shown all at once?



#2

@cdragin,

This is because the validation rules in the settings controller - application/controllers/admin/settings.php (Line 107-108) limit the maximum no. of reports that can be displayed on both the frontend and admin console to 50 items. To increase the limit to say 300, change the validation rules to read something like:


Code:
$post->add_rules('items_per_page', 'required', 'between[10,300]')

This will ensure that the changes you make are saved.



#3

Thanks! Also changed line 220 in order to change the pulldown menu.



#4

Have done this and don’t see any changes in the amount of viewable reports on the front of the site or in the admin backend. Can anyone assist? Thanks.


#5

hallo!
I would like to show more than 50 reports in my map (e.g. 200 reports)…I changed some settings but I had no results! here what I changed:

in the file: application/config/setting.php

  • row 23: ‘items_per_page’ => ‘200’,
  • row 24: ‘items_per_page_admin’ => ‘200’,

in the file: application/controllers/admin/setting.php
-row 107: $post->add_rules(‘items_per_page’,‘required’,‘between[5,200]’);
-row 108: $post->add_rules(‘items_per_page_admin’,‘required’,‘between[5,200]’);

  • row 306 (to add the possibility to change the number of reports in admin page, setting, website…): $this->template->content->items_per_page_array = array(‘5’=>‘5 Items’,‘10’=>‘10 Items’,‘20’=>‘20 Items’,‘30’=>‘30 Items’,‘50’=>‘50 Items’, ‘200’=>'200 Items’);

so, after these changes, all the reports ON THE MAP are disappear!

where I’m wrong?

thanks!!