diff options
author | Uģis Ozols <ugis.ozolss@gmail.com> | 2012-06-27 22:29:31 +0300 |
---|---|---|
committer | Uģis Ozols <ugis.ozolss@gmail.com> | 2012-06-27 22:29:31 +0300 |
commit | 8b1d10fab257d8a0ce7230f27a530dd7f8140acc (patch) | |
tree | a51bffee0dd234df9c823257d9c7bf3a02c92fd6 /app/views | |
parent | fc97c846689d545a2b3844c8f9810eda129c8803 (diff) | |
download | refinerycms-blog-8b1d10fab257d8a0ce7230f27a530dd7f8140acc.tar.gz refinerycms-blog-8b1d10fab257d8a0ce7230f27a530dd7f8140acc.tar.bz2 refinerycms-blog-8b1d10fab257d8a0ce7230f27a530dd7f8140acc.zip |
Use shorter syntax of render where possible.
Diffstat (limited to 'app/views')
8 files changed, 32 insertions, 48 deletions
diff --git a/app/views/refinery/blog/admin/categories/_form.html.erb b/app/views/refinery/blog/admin/categories/_form.html.erb index 6b4e20d..559dbe1 100644 --- a/app/views/refinery/blog/admin/categories/_form.html.erb +++ b/app/views/refinery/blog/admin/categories/_form.html.erb @@ -1,9 +1,7 @@ <%= form_for [refinery, :blog_admin, @category] do |f| -%> - <%= render :partial => "/refinery/admin/error_messages", - :locals => { - :object => f.object, - :include_object_name => true - } %> + <%= render "/refinery/admin/error_messages", + :object => f.object, + :include_object_name => true %> <%= render "/refinery/blog/admin/shared/locale_picker", :current_locale => Thread.current[:globalize_locale] if Refinery.i18n_enabled? %> @@ -13,10 +11,8 @@ <%= f.text_field :title, :class => 'larger widest' -%> </div> - <%= render :partial => "/refinery/admin/form_actions", - :locals => { - :f => f, - :continue_editing => false, - :delete_title => t('delete', :scope => 'refinery.blog.admin.categories.category') - } %> + <%= render "/refinery/admin/form_actions", + :f => f, + :continue_editing => false, + :delete_title => t('delete', :scope => 'refinery.blog.admin.categories.category') %> <% end %> diff --git a/app/views/refinery/blog/admin/categories/_sortable_list.html.erb b/app/views/refinery/blog/admin/categories/_sortable_list.html.erb index 8040dc0..2a6461a 100644 --- a/app/views/refinery/blog/admin/categories/_sortable_list.html.erb +++ b/app/views/refinery/blog/admin/categories/_sortable_list.html.erb @@ -1,7 +1,5 @@ <ul id='sortable_list'> <%= render :partial => 'category', :collection => @categories %> </ul> -<%= render :partial => "/refinery/admin/sortable_list", - :locals => { - :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) - } %> +<%= render "/refinery/admin/sortable_list", + :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) %> diff --git a/app/views/refinery/blog/admin/comments/_sortable_list.html.erb b/app/views/refinery/blog/admin/comments/_sortable_list.html.erb index 9f8bbbc..6596896 100644 --- a/app/views/refinery/blog/admin/comments/_sortable_list.html.erb +++ b/app/views/refinery/blog/admin/comments/_sortable_list.html.erb @@ -1,7 +1,5 @@ <ul id='sortable_list'> <%= render :partial => 'comment', :collection => @comments %> </ul> -<%= render :partial => "/refinery/admin/sortable_list", - :locals => { - :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) - } %> +<%= render "/refinery/admin/sortable_list", + :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) %> diff --git a/app/views/refinery/blog/admin/posts/_form.html.erb b/app/views/refinery/blog/admin/posts/_form.html.erb index b6fc535..9e91133 100644 --- a/app/views/refinery/blog/admin/posts/_form.html.erb +++ b/app/views/refinery/blog/admin/posts/_form.html.erb @@ -1,9 +1,7 @@ <%= form_for [refinery, :blog_admin, @post] do |f| -%> - <%= render :partial => "/refinery/admin/error_messages", - :locals => { - :object => f.object, - :include_object_name => true - } %> + <%= render "/refinery/admin/error_messages", + :object => f.object, + :include_object_name => true %> <%= render "/refinery/blog/admin/shared/locale_picker", :current_locale => Thread.current[:globalize_locale] if Refinery.i18n_enabled? %> @@ -117,14 +115,14 @@ <%= render '/seo_meta/form', :form => f %> </div> </div> - <%= render :partial => "/refinery/admin/form_actions", - :locals => { - :f => f, - :continue_editing => true, - :delete_title => t('delete', :scope => 'refinery.blog.admin.posts.post') - } %> + <%= render "/refinery/admin/form_actions", + :f => f, + :continue_editing => true, + :delete_title => t('delete', :scope => 'refinery.blog.admin.posts.post') %> <% end -%> <% content_for :stylesheets, stylesheet_link_tag('refinery/blog/backend') %> <% content_for :javascripts, javascript_include_tag('refinery/blog/backend') %> -<%= render 'refinery/shared/admin/autocomplete', :dom_id => '#blog_post_tag_list', :url => refinery.tags_blog_admin_posts_url %> +<%= render 'refinery/shared/admin/autocomplete', + :dom_id => '#blog_post_tag_list', + :url => refinery.tags_blog_admin_posts_url %> diff --git a/app/views/refinery/blog/admin/posts/_sortable_list.html.erb b/app/views/refinery/blog/admin/posts/_sortable_list.html.erb index 471d4f0..e924d19 100644 --- a/app/views/refinery/blog/admin/posts/_sortable_list.html.erb +++ b/app/views/refinery/blog/admin/posts/_sortable_list.html.erb @@ -1,7 +1,5 @@ <ul id='sortable_list'> <%= render :partial => 'post', :collection => @posts %> </ul> -<%= render :partial => "/refinery/admin/sortable_list", - :locals => { - :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) - } %> +<%= render "/refinery/admin/sortable_list", + :continue_reordering => (defined?(continue_reordering) ? continue_reordering : true) %> diff --git a/app/views/refinery/blog/admin/settings/notification_recipients.html.erb b/app/views/refinery/blog/admin/settings/notification_recipients.html.erb index 132ab17..dc7070f 100644 --- a/app/views/refinery/blog/admin/settings/notification_recipients.html.erb +++ b/app/views/refinery/blog/admin/settings/notification_recipients.html.erb @@ -14,11 +14,9 @@ <%= t('.example') %> </p> - <%= render :partial => "/refinery/admin/form_actions", - :locals => { - :f => nil, - :continue_editing => false, - :cancel_url => refinery.blog_admin_posts_url, - :hide_delete => true - } %> + <%= render "/refinery/admin/form_actions", + :f => nil, + :continue_editing => false, + :cancel_url => refinery.blog_admin_posts_url, + :hide_delete => true %> <% end %> diff --git a/app/views/refinery/blog/posts/_comments.html.erb b/app/views/refinery/blog/posts/_comments.html.erb index d662a1f..8415971 100644 --- a/app/views/refinery/blog/posts/_comments.html.erb +++ b/app/views/refinery/blog/posts/_comments.html.erb @@ -16,11 +16,9 @@ <h2><%= t('add', :scope => 'refinery.blog.posts.show.comments') %></h2> <%= form_for [refinery, :blog, @comment] do |f| %> - <%= render :partial => "/refinery/admin/error_messages", - :locals => { - :object => f.object, - :include_object_name => true - } %> + <%= render "/refinery/admin/error_messages", + :object => f.object, + :include_object_name => true %> <div class='field'> <%= f.label :name %> <%= f.text_field :name %> diff --git a/app/views/refinery/blog/posts/show.html.erb b/app/views/refinery/blog/posts/show.html.erb index d7abd1e..bc9b203 100644 --- a/app/views/refinery/blog/posts/show.html.erb +++ b/app/views/refinery/blog/posts/show.html.erb @@ -10,7 +10,7 @@ <%= render '/refinery/blog/shared/body_content_right' %> -<%= render :partial => "/refinery/content_page", :locals => { :remove_automatic_sections => true } %> +<%= render "/refinery/content_page", :remove_automatic_sections => true %> <% content_for :stylesheets, stylesheet_link_tag('refinery/blog/frontend') %> <% content_for :javascripts do %> |