Patch #16069 » 0001-domingo-galdos.patch
| app/controllers/application_controller.rb | ||
|---|---|---|
|
limit = options[:limit].to_i
|
||
|
if limit < 1
|
||
|
limit = 25
|
||
|
elsif limit > 100
|
||
|
limit = 100
|
||
|
elsif limit > Setting.api_limit.to_i
|
||
|
limit = Setting.api_limit.to_i
|
||
|
end
|
||
|
if offset.nil? && options[:page].present?
|
||
|
offset = (options[:page].to_i - 1) * limit
|
||
| app/views/settings/_general.html.erb | ||
|---|---|---|
|
<p><%= setting_select :wiki_compression, [['Gzip', 'gzip']], :blank => :label_none %></p>
|
||
|
<p><%= setting_text_field :api_limit, :size => 6 %></p>
|
||
|
<p><%= setting_text_field :feeds_limit, :size => 6 %></p>
|
||
|
<%= call_hook(:view_settings_general_form) %>
|
||
| config/locales/en.yml | ||
|---|---|---|
|
setting_host_name: Host name and path
|
||
|
setting_text_formatting: Text formatting
|
||
|
setting_wiki_compression: Wiki history compression
|
||
|
setting_api_limit: Maximum number of items returned in a JSON/XML API response
|
||
|
setting_feeds_limit: Maximum number of items in Atom feeds
|
||
|
setting_default_projects_public: New projects are public by default
|
||
|
setting_autofetch_changesets: Fetch commits automatically
|
||
| config/settings.yml | ||
|---|---|---|
|
protocol:
|
||
|
default: http
|
||
|
security_notifications: 1
|
||
|
api_limit:
|
||
|
format: int
|
||
|
default: 100
|
||
|
feeds_limit:
|
||
|
format: int
|
||
|
default: 15
|
||