Commit 5a1e6f02cb79009c7ca8d28c1a7298be2289a6ea
1 parent
19ff2dc0
Exists in
master
and in
1 other branch
render with implicit partial param
Showing
9 changed files
with
9 additions
and
9 deletions
Show diff stats
app/helpers/application_helper.rb
@@ -58,7 +58,7 @@ module ApplicationHelper | @@ -58,7 +58,7 @@ module ApplicationHelper | ||
58 | percent = 100.0 / total.to_f | 58 | percent = 100.0 / total.to_f |
59 | rows = tallies.map {|value, count| [(count.to_f * percent), value]} \ | 59 | rows = tallies.map {|value, count| [(count.to_f * percent), value]} \ |
60 | .sort {|a, b| a[0] <=> b[0]} | 60 | .sort {|a, b| a[0] <=> b[0]} |
61 | - render :partial => "errs/tally_table", :locals => {:rows => rows} | 61 | + render "errs/tally_table", :rows => rows |
62 | end | 62 | end |
63 | 63 | ||
64 | private | 64 | private |
app/helpers/notices_helper.rb
@@ -5,7 +5,7 @@ module NoticesHelper | @@ -5,7 +5,7 @@ module NoticesHelper | ||
5 | end | 5 | end |
6 | 6 | ||
7 | def notice_atom_summary(notice) | 7 | def notice_atom_summary(notice) |
8 | - render :partial => "notices/atom_entry.html.haml", :locals => {:notice => notice} | 8 | + render "notices/atom_entry.html.haml", :notice => notice |
9 | end | 9 | end |
10 | 10 | ||
11 | def link_to_source_file(app, line, &block) | 11 | def link_to_source_file(app, line, &block) |
app/views/apps/show.atom.builder
app/views/errs/index.atom.builder
app/views/errs/show.html.haml
@@ -18,7 +18,7 @@ | @@ -18,7 +18,7 @@ | ||
18 | %span= link_to 'iCal', app_err_path(:app_id => @app.id, :id => @problem.id, :format => "ics", :auth_token => current_user.authentication_token), :class => "calendar_link" | 18 | %span= link_to 'iCal', app_err_path(:app_id => @app.id, :id => @problem.id, :format => "ics", :auth_token => current_user.authentication_token), :class => "calendar_link" |
19 | %span>= link_to 'up', (request.env['HTTP_REFERER'] ? :back : app_errs_path(@app)), :class => 'up' | 19 | %span>= link_to 'up', (request.env['HTTP_REFERER'] ? :back : app_errs_path(@app)), :class => 'up' |
20 | %br | 20 | %br |
21 | - = render :partial => "issue_tracker_links" | 21 | + = render "issue_tracker_links" |
22 | 22 | ||
23 | - if Errbit::Config.allow_comments_with_issue_tracker || !@app.issue_tracker_configured? || @problem.comments.any? | 23 | - if Errbit::Config.allow_comments_with_issue_tracker || !@app.issue_tracker_configured? || @problem.comments.any? |
24 | - content_for :comments do | 24 | - content_for :comments do |
app/views/layouts/application.html.haml
@@ -25,7 +25,7 @@ | @@ -25,7 +25,7 @@ | ||
25 | #action-bar | 25 | #action-bar |
26 | = action_bar | 26 | = action_bar |
27 | #content | 27 | #content |
28 | - = render :partial => 'shared/flash_messages' | 28 | + = render 'shared/flash_messages' |
29 | = yield | 29 | = yield |
30 | - if content_for?(:comments) | 30 | - if content_for?(:comments) |
31 | #content-comments | 31 | #content-comments |
app/views/users/edit.html.haml
1 | - content_for :title, "Edit #{@user.name}" | 1 | - content_for :title, "Edit #{@user.name}" |
2 | - content_for :action_bar do | 2 | - content_for :action_bar do |
3 | - = render :partial => 'shared/link_github_account', :locals => {:user => @user} | 3 | + = render 'shared/link_github_account', :user => @user |
4 | = link_to('cancel', user_path(@user), :class => 'button') | 4 | = link_to('cancel', user_path(@user), :class => 'button') |
5 | 5 | ||
6 | = form_for @user, :html => {:autocomplete => "off"} do |f| | 6 | = form_for @user, :html => {:autocomplete => "off"} do |f| |
app/views/users/show.html.haml
1 | - content_for :title, @user.name | 1 | - content_for :title, @user.name |
2 | - content_for :action_bar do | 2 | - content_for :action_bar do |
3 | - = render :partial => 'shared/link_github_account', :locals => {:user => @user} | 3 | + = render 'shared/link_github_account', :user => @user |
4 | %span= link_to('Add a New User', new_user_path, :class => 'add') | 4 | %span= link_to('Add a New User', new_user_path, :class => 'add') |
5 | = link_to 'edit', edit_user_path(@user), :class => 'button' | 5 | = link_to 'edit', edit_user_path(@user), :class => 'button' |
6 | = link_to 'destroy', user_path(@user), :method => :delete, :confirm => 'Seriously?', :class => 'button' | 6 | = link_to 'destroy', user_path(@user), :method => :delete, :confirm => 'Seriously?', :class => 'button' |
spec/views/notices/_backtrace.html.haml_spec.rb
@@ -12,7 +12,7 @@ describe "notices/_backtrace.html.haml" do | @@ -12,7 +12,7 @@ describe "notices/_backtrace.html.haml" do | ||
12 | end | 12 | end |
13 | 13 | ||
14 | it "should replace nil file with [unknown source]" do | 14 | it "should replace nil file with [unknown source]" do |
15 | - render :partial => "notices/backtrace", :locals => {:lines => @notice.backtrace} | 15 | + render "notices/backtrace", :lines => @notice.backtrace |
16 | rendered.should match(/\[unknown source\]/) | 16 | rendered.should match(/\[unknown source\]/) |
17 | end | 17 | end |
18 | end | 18 | end |