# news feeds
def news
News.with_scope(:find => @find_options) do
- @news = News.find :all, :order => "#{News.table_name}.created_on DESC", :limit => 10, :include => [ :author, :project ]
+ @news = News.find :all, :order => "#{News.table_name}.created_on DESC", :include => [ :author, :project ]
end
headers["Content-Type"] = "application/rss+xml"
render :action => 'news_atom' if 'atom' == params[:format]
# global feed
scope = ["#{Project.table_name}.is_public=?", true]
end
- @find_options = {:conditions => scope, :limit => 10}
+ @find_options = {:conditions => scope, :limit => Setting.feeds_limit}
return true
end
end
<h2><%= l(:label_settings) %></h2>
+<div id="settings">
<% form_tag({:action => 'edit'}, :class => "tabular") do %>
<div class="box">
<p><label><%= l(:setting_app_title) %></label>
<p><label><%= l(:setting_wiki_compression) %></label>
<%= select_tag 'settings[wiki_compression]', options_for_select( [[l(:label_none), 0], ["gzip", "gzip"]], Setting.wiki_compression) %></p>
+<p><label><%= l(:setting_feeds_limit) %></label>
+<%= text_field_tag 'settings[feeds_limit]', Setting.feeds_limit, :size => 6 %></p>
+
</div>
<%= submit_tag l(:button_save) %>
+</div>
<% end %>
\ No newline at end of file
default_language:\r
default: en\r
host_name:\r
- default: localhost:3000
\ No newline at end of file
+ default: localhost:3000\r
+feeds_limit:\r
+ format: int\r
+ default: 15\r
setting_host_name: Host Name\r
setting_text_formatting: Textformatierung\r
setting_wiki_compression: Wiki Geschichte Kompression\r
+setting_feeds_limit: Feed content limit\r
\r
label_user: Benutzer\r
label_user_plural: Benutzer\r
setting_host_name: Host name\r
setting_text_formatting: Text formatting\r
setting_wiki_compression: Wiki history compression\r
+setting_feeds_limit: Feed content limit\r
\r
label_user: User\r
label_user_plural: Users\r
setting_host_name: Nombre de anfitrión\r
setting_text_formatting: Formato de texto\r
setting_wiki_compression: Compresión de la historia de Wiki\r
+setting_feeds_limit: Feed content limit\r
\r
label_user: Usuario\r
label_user_plural: Usuarios\r
setting_host_name: Nom d'hôte\r
setting_text_formatting: Formatage du texte\r
setting_wiki_compression: Compression historique wiki\r
+setting_feeds_limit: Limite du contenu des flux RSS\r
\r
label_user: Utilisateur\r
label_user_plural: Utilisateurs\r
setting_host_name: Nome host\r
setting_text_formatting: Formattazione testo\r
setting_wiki_compression: Compressione di storia di Wiki\r
+setting_feeds_limit: Feed content limit\r
\r
label_user: Utente\r
label_user_plural: Utenti\r
setting_host_name: ホスト名\r
setting_text_formatting: テキストの書式\r
setting_wiki_compression: Wiki history compression\r
+setting_feeds_limit: Feed content limit\r
\r
label_user: ユーザ\r
label_user_plural: ユーザ\r
color: #cc0000;\r
}\r
\r
+#settings .tabular p{ padding-left: 250px; }\r
+#settings .tabular label{ margin-left: -250px; width: 245px; }\r
\r
/*.threepxfix class below:\r
Targets IE6- ONLY. Adds 3 pixel indent for multi-line form contents.\r