Use double quotes in app/views/budgets

This commit is contained in:
Julian Herrero
2019-03-14 17:11:32 +01:00
parent 0bb2633c7a
commit c87267d34f
24 changed files with 82 additions and 82 deletions

View File

@@ -45,7 +45,7 @@
<% end %> <% end %>
<ul class="ballot-list"> <ul class="ballot-list">
<%= render partial: 'budgets/ballot/investment', <%= render partial: "budgets/ballot/investment",
collection: @ballot.investments.by_group(group.id) %> collection: @ballot.investments.by_group(group.id) %>
</ul> </ul>
</div> </div>

View File

@@ -4,7 +4,7 @@
<% if @budget.balloting? %> <% if @budget.balloting? %>
<%= link_to budget_ballot_line_path(@budget, id: investment.id), <%= link_to budget_ballot_line_path(@budget, id: investment.id),
title: t('budgets.ballots.show.remove'), title: t("budgets.ballots.show.remove"),
class: "remove-investment-project", class: "remove-investment-project",
method: :delete, method: :delete,
remote: true do %> remote: true do %>

View File

@@ -5,11 +5,11 @@
<% if @budget.balloting? %> <% if @budget.balloting? %>
<%= link_to budget_ballot_line_url(id: investment.id, <%= link_to budget_ballot_line_url(id: investment.id,
investments_ids: investment_ids), investments_ids: investment_ids),
title: t('budgets.ballots.show.remove'), title: t("budgets.ballots.show.remove"),
class: "remove-investment-project", class: "remove-investment-project",
method: :delete, method: :delete,
remote: true do %> remote: true do %>
<span class="show-for-sr"><%= t('budgets.ballots.show.remove') %></span> <span class="show-for-sr"><%= t("budgets.ballots.show.remove") %></span>
<span class="icon-x"></span> <span class="icon-x"></span>
<% end %> <% end %>
<% end %> <% end %>

View File

@@ -5,7 +5,7 @@ $("#<%= dom_id(@investment) %>_ballot").html('<%= j render("/budgets/investments
investment_ids: @investment_ids, investment_ids: @investment_ids,
ballot: @ballot) %>'); ballot: @ballot) %>');
<%= render 'refresh_ballots', <%= render "refresh_ballots",
investment: @investment, investment: @investment,
investment_ids: @investment_ids, investment_ids: @investment_ids,
ballot: @ballot %> ballot: @ballot %>

View File

@@ -6,7 +6,7 @@ $("#<%= dom_id(@investment) %>_ballot").html('<%= j render("/budgets/investments
investment: @investment, investment: @investment,
investment_ids: @investment_ids, investment_ids: @investment_ids,
ballot: @ballot) %>'); ballot: @ballot) %>');
<%= render 'refresh_ballots', <%= render "refresh_ballots",
investment: @investment, investment: @investment,
investment_ids: @investment_ids, investment_ids: @investment_ids,
ballot: @ballot %> ballot: @ballot %>

View File

@@ -6,8 +6,8 @@
<% investments.each do |investment| %> <% investments.each do |investment| %>
<div class="small-12 medium-6 large-4 column end margin-bottom"> <div class="small-12 medium-6 large-4 column end margin-bottom">
<div class="budget-execution"> <div class="budget-execution">
<%= link_to budget_investment_path(@budget, investment, anchor: "tab-milestones"), data: { 'equalizer-watch': true } do %> <%= link_to budget_investment_path(@budget, investment, anchor: "tab-milestones"), data: { "equalizer-watch": true } do %>
<%= render 'image', investment: investment %> <%= render "image", investment: investment %>
<div class="budget-execution-info"> <div class="budget-execution-info">
<div class="budget-execution-content"> <div class="budget-execution-content">
<h5><%= investment.title %></h5> <h5><%= investment.title %></h5>

View File

@@ -1,14 +1,14 @@
<% provide :title, t("budgets.executions.page_title", budget: @budget.name) %> <% provide :title, t("budgets.executions.page_title", budget: @budget.name) %>
<% content_for :meta_description do %><%= @budget.description_for_phase('finished') %><% end %> <% content_for :meta_description do %><%= @budget.description_for_phase("finished") %><% end %>
<% provide :social_media_meta_tags do %> <% provide :social_media_meta_tags do %>
<%= render 'shared/social_media_meta_tags', <%= render "shared/social_media_meta_tags",
social_url: budget_executions_url(@budget), social_url: budget_executions_url(@budget),
social_title: @budget.name, social_title: @budget.name,
social_description: @budget.description_for_phase('finished') %> social_description: @budget.description_for_phase("finished") %>
<% end %> <% end %>
<% content_for :canonical do %> <% content_for :canonical do %>
<%= render 'shared/canonical', href: budget_executions_url(@budget) %> <%= render "shared/canonical", href: budget_executions_url(@budget) %>
<% end %> <% end %>
<div class="budgets-stats"> <div class="budgets-stats">
@@ -32,7 +32,7 @@
<%= link_to t("budgets.results.link"), budget_results_path(@budget) %> <%= link_to t("budgets.results.link"), budget_results_path(@budget) %>
</li> </li>
<li class="tabs-title is-active"> <li class="tabs-title is-active">
<%= link_to t("budgets.executions.link"), budget_executions_path(@budget), class: 'is-active' %> <%= link_to t("budgets.executions.link"), budget_executions_path(@budget), class: "is-active" %>
</li> </li>
</ul> </ul>
</div> </div>
@@ -67,7 +67,7 @@
<% end %> <% end %>
<% if @investments_by_heading.any? %> <% if @investments_by_heading.any? %>
<%= render 'budgets/executions/investments' %> <%= render "budgets/executions/investments" %>
<% else %> <% else %>
<div class="callout primary clear"> <div class="callout primary clear">
<%= t("budgets.executions.no_winner_investments") %> <%= t("budgets.executions.no_winner_investments") %>

View File

@@ -2,7 +2,7 @@
<%= render "shared/banner" %> <%= render "shared/banner" %>
<% end %> <% end %>
<% provide :title do %><%= t('budgets.index.title') %><% end %> <% provide :title do %><%= t("budgets.index.title") %><% end %>
<% content_for :canonical do %> <% content_for :canonical do %>
<%= render "shared/canonical", href: budgets_url %> <%= render "shared/canonical", href: budgets_url %>

View File

@@ -10,7 +10,7 @@
<%= investment.formatted_price %> <%= investment.formatted_price %>
</p> </p>
<% if investment.should_show_ballots? %> <% if investment.should_show_ballots? %>
<%= link_to t('budgets.ballots.show.remove'), <%= link_to t("budgets.ballots.show.remove"),
budget_ballot_line_path(id: investment.id, budget_ballot_line_path(id: investment.id,
budget_id: investment.budget_id, budget_id: investment.budget_id,
investments_ids: investment_ids), investments_ids: investment_ids),
@@ -32,7 +32,7 @@
budget_id: investment.budget_id, budget_id: investment.budget_id,
investments_ids: investment_ids), investments_ids: investment_ids),
class: "button button-support small expanded", class: "button button-support small expanded",
title: t('budgets.investments.investment.support_title'), title: t("budgets.investments.investment.support_title"),
method: :post, method: :post,
remote: true %> remote: true %>
<% end %> <% end %>

View File

@@ -5,7 +5,7 @@
<ul id="categories" class="no-bullet categories"> <ul id="categories" class="no-bullet categories">
<% @categories.each do |category| %> <% @categories.each do |category| %>
<li class="inline-block"> <li class="inline-block">
<% css_class = { class: 'is-active' } if params[:search] == category.name %> <% css_class = { class: "is-active" } if params[:search] == category.name %>
<%= link_to category.name, budget_investments_path(@budget, search: category.name), css_class || {} %> <%= link_to category.name, budget_investments_path(@budget, search: category.name), css_class || {} %>
</li> </li>
<% end %> <% end %>

View File

@@ -4,7 +4,7 @@
<span class="icon-flag flag-disable"></span> <span class="icon-flag flag-disable"></span>
</a> </a>
<span class="dropdown-pane" id="flag-drop-investment-<%= investment.id %>" data-dropdown data-auto-focus="true"> <span class="dropdown-pane" id="flag-drop-investment-<%= investment.id %>" data-dropdown data-auto-focus="true">
<%= link_to t('shared.flag'), flag_budget_investment_path(investment.budget, investment.id), <%= link_to t("shared.flag"), flag_budget_investment_path(investment.budget, investment.id),
method: :put, method: :put,
remote: true, remote: true,
id: "flag-investment-#{ investment.id }" %> id: "flag-investment-#{ investment.id }" %>
@@ -16,7 +16,7 @@
<span class="icon-flag flag-active"></span> <span class="icon-flag flag-active"></span>
</a> </a>
<span class="dropdown-pane" id="unflag-drop-investment-<%= investment.id %>" data-dropdown data-auto-focus="true"> <span class="dropdown-pane" id="unflag-drop-investment-<%= investment.id %>" data-dropdown data-auto-focus="true">
<%= link_to t('shared.unflag'), unflag_budget_investment_path(investment.budget, investment.id), <%= link_to t("shared.unflag"), unflag_budget_investment_path(investment.budget, investment.id),
method: :put, method: :put,
remote: true, remote: true,
id: "unflag-investment-#{ investment.id }" %> id: "unflag-investment-#{ investment.id }" %>

View File

@@ -1,5 +1,5 @@
<%= form_for(@investment, url: form_url, method: :post, html: { multipart: true }) do |f| %> <%= form_for(@investment, url: form_url, method: :post, html: { multipart: true }) do |f| %>
<%= render 'shared/errors', resource: @investment %> <%= render "shared/errors", resource: @investment %>
<div class="row"> <div class="row">
<div class="small-12 medium-8 column"> <div class="small-12 medium-8 column">
@@ -19,20 +19,20 @@
<% if feature?(:allow_images) %> <% if feature?(:allow_images) %>
<div class="images small-12 column"> <div class="images small-12 column">
<%= render 'images/nested_image', imageable: @investment, f: f %> <%= render "images/nested_image", imageable: @investment, f: f %>
</div> </div>
<% end %> <% end %>
<% if feature?(:allow_attached_documents) %> <% if feature?(:allow_attached_documents) %>
<div class="documents small-12 column"> <div class="documents small-12 column">
<%= render 'documents/nested_documents', documentable: @investment, f: f %> <%= render "documents/nested_documents", documentable: @investment, f: f %>
</div> </div>
<% end %> <% end %>
<% if feature?(:map) %> <% if feature?(:map) %>
<div class="small-12 column"> <div class="small-12 column">
<%= render 'map_locations/form_fields', <%= render "map_locations/form_fields",
form: f, form: f,
map_location: @investment.map_location || MapLocation.new, map_location: @investment.map_location || MapLocation.new,
label: t("budgets.investments.form.map_location"), label: t("budgets.investments.form.map_location"),
@@ -69,7 +69,7 @@
label: false, label: false,
placeholder: t("budgets.investments.form.tags_placeholder"), placeholder: t("budgets.investments.form.tags_placeholder"),
aria: {describedby: "tags-list-help-text"}, aria: {describedby: "tags-list-help-text"},
class: 'js-tag-list tag-autocomplete', class: "js-tag-list tag-autocomplete",
data: {js_url: suggest_tags_path} %> data: {js_url: suggest_tags_path} %>
</div> </div>
@@ -77,7 +77,7 @@
<div class="small-12 column"> <div class="small-12 column">
<%= f.label :terms_of_service do %> <%= f.label :terms_of_service do %>
<%= f.check_box :terms_of_service, title: t('form.accept_terms_title'), label: false %> <%= f.check_box :terms_of_service, title: t("form.accept_terms_title"), label: false %>
<span class="checkbox"> <span class="checkbox">
<%= t("form.accept_terms", <%= t("form.accept_terms",
policy: link_to(t("form.policy"), "/privacy", target: "blank"), policy: link_to(t("form.policy"), "/privacy", target: "blank"),

View File

@@ -27,7 +27,7 @@
<%= t("budgets.investments.index.by_heading", heading: @heading.name) %> <%= t("budgets.investments.index.by_heading", heading: @heading.name) %>
</h2> </h2>
<div id="progress_bar" class="no-margin-top"> <div id="progress_bar" class="no-margin-top">
<%= render 'budgets/ballot/progress_bar' %> <%= render "budgets/ballot/progress_bar" %>
</div> </div>
</div> </div>
<% else %> <% else %>

View File

@@ -18,7 +18,7 @@
<% end %> <% end %>
<div class="budget-investment-content"> <div class="budget-investment-content">
<% cache [locale_and_user_status(investment), 'index', investment, investment.author] do %> <% cache [locale_and_user_status(investment), "index", investment, investment.author] do %>
<h3><%= link_to investment.title, namespaced_budget_investment_path(investment) %></h3> <h3><%= link_to investment.title, namespaced_budget_investment_path(investment) %></h3>
<p class="investment-project-info"> <p class="investment-project-info">
@@ -59,17 +59,17 @@
<% if investment.should_show_votes? %> <% if investment.should_show_votes? %>
<div id="<%= dom_id(investment) %>_votes" <div id="<%= dom_id(investment) %>_votes"
class="small-12 medium-3 column text-center" class="small-12 medium-3 column text-center"
<%= 'data-equalizer-watch' if feature?(:allow_images) && investment.image.present? %>> <%= "data-equalizer-watch" if feature?(:allow_images) && investment.image.present? %>>
<%= render partial: '/budgets/investments/votes', locals: { <%= render partial: "/budgets/investments/votes", locals: {
investment: investment, investment: investment,
investment_votes: investment_votes, investment_votes: investment_votes,
vote_url: namespaced_budget_investment_vote_path(investment, value: 'yes') vote_url: namespaced_budget_investment_vote_path(investment, value: "yes")
} %> } %>
</div> </div>
<% elsif investment.should_show_vote_count? %> <% elsif investment.should_show_vote_count? %>
<div id="<%= dom_id(investment) %>_votes" <div id="<%= dom_id(investment) %>_votes"
class="small-12 medium-3 column text-center" class="small-12 medium-3 column text-center"
<%= 'data-equalizer-watch' if feature?(:allow_images) && investment.image.present? %>> <%= "data-equalizer-watch" if feature?(:allow_images) && investment.image.present? %>>
<div class="supports js-participation"> <div class="supports js-participation">
<span class="total-supports no-button"> <span class="total-supports no-button">
<%= t("budgets.investments.investment.supports", <%= t("budgets.investments.investment.supports",
@@ -80,8 +80,8 @@
<% elsif investment.should_show_ballots? %> <% elsif investment.should_show_ballots? %>
<div id="<%= dom_id(investment) %>_ballot" <div id="<%= dom_id(investment) %>_ballot"
class="small-12 medium-3 column text-center" class="small-12 medium-3 column text-center"
<%= 'data-equalizer-watch' if feature?(:allow_images) && investment.image.present? %>> <%= "data-equalizer-watch" if feature?(:allow_images) && investment.image.present? %>>
<%= render partial: '/budgets/investments/ballot', locals: { <%= render partial: "/budgets/investments/ballot", locals: {
investment: investment, investment: investment,
investment_ids: investment_ids, investment_ids: investment_ids,
ballot: ballot ballot: ballot
@@ -90,7 +90,7 @@
<% elsif investment.should_show_price? %> <% elsif investment.should_show_price? %>
<div id="<%= dom_id(investment) %>_price" <div id="<%= dom_id(investment) %>_price"
class="supports small-12 medium-3 column text-center" class="supports small-12 medium-3 column text-center"
<%= 'data-equalizer-watch' if feature?(:allow_images) && investment.image.present? %>> <%= "data-equalizer-watch" if feature?(:allow_images) && investment.image.present? %>>
<div class="supports"> <div class="supports">
<span class="total-supports no-button"> <span class="total-supports no-button">
<%= investment.formatted_price %> <%= investment.formatted_price %>
@@ -98,7 +98,7 @@
</div> </div>
</div> </div>
<% else %> <% else %>
<div <%= 'data-equalizer-watch' if feature?(:allow_images) && investment.image.present? %>></div> <div <%= "data-equalizer-watch" if feature?(:allow_images) && investment.image.present? %>></div>
<% end %> <% end %>
<% end %> <% end %>

View File

@@ -3,7 +3,7 @@
<div class="row"> <div class="row">
<div class="small-12 column"> <div class="small-12 column">
<div class="budget-investment-content"> <div class="budget-investment-content">
<% cache [locale_and_user_status(investment), 'index_minimal', investment, investment.author] do %> <% cache [locale_and_user_status(investment), "index_minimal", investment, investment.author] do %>
<h3><%= link_to investment.title, namespaced_budget_investment_path(investment) %></h3> <h3><%= link_to investment.title, namespaced_budget_investment_path(investment) %></h3>
<% end %> <% end %>
</div> </div>

View File

@@ -20,7 +20,7 @@
<h1><%= investment.title %></h1> <h1><%= investment.title %></h1>
<div class="budget-investment-info"> <div class="budget-investment-info">
<%= render '/shared/author_info', resource: investment %> <%= render "/shared/author_info", resource: investment %>
<span class="bullet">&nbsp;&bull;&nbsp;</span> <span class="bullet">&nbsp;&bull;&nbsp;</span>
<%= l investment.created_at.to_date %> <%= l investment.created_at.to_date %>
@@ -28,7 +28,7 @@
<%= investment.heading.name %> <%= investment.heading.name %>
<span class="bullet">&nbsp;&bull;&nbsp;</span> <span class="bullet">&nbsp;&bull;&nbsp;</span>
<span class="js-flag-actions"> <span class="js-flag-actions">
<%= render 'budgets/investments/flag_actions', investment: @investment %> <%= render "budgets/investments/flag_actions", investment: @investment %>
</span> </span>
</div> </div>
@@ -61,12 +61,12 @@
<% end %> <% end %>
<% if feature?(:allow_attached_documents) %> <% if feature?(:allow_attached_documents) %>
<%= render 'documents/documents', <%= render "documents/documents",
documents: investment.documents, documents: investment.documents,
max_documents_allowed: Budget::Investment.max_documents_allowed %> max_documents_allowed: Budget::Investment.max_documents_allowed %>
<% end %> <% end %>
<%= render 'shared/tags', taggable: investment %> <%= render "shared/tags", taggable: investment %>
<% if investment.external_url.present? %> <% if investment.external_url.present? %>
<div class="document-link"> <div class="document-link">
@@ -75,7 +75,7 @@
<% end %> <% end %>
<% if investment.should_show_unfeasibility_explanation? %> <% if investment.should_show_unfeasibility_explanation? %>
<h2><%= t('budgets.investments.show.unfeasibility_explanation') %></h2> <h2><%= t("budgets.investments.show.unfeasibility_explanation") %></h2>
<p><%= investment.unfeasibility_explanation %></p> <p><%= investment.unfeasibility_explanation %></p>
<% end %> <% end %>
@@ -86,7 +86,7 @@
<p><%= investment.price_explanation %></p> <p><%= investment.price_explanation %></p>
<% end %> <% end %>
<%= render 'relationable/related_content', relationable: @investment %> <%= render "relationable/related_content", relationable: @investment %>
<div class="js-moderator-investment-actions margin"> <div class="js-moderator-investment-actions margin">
<%= render "budgets/investments/actions", investment: @investment %> <%= render "budgets/investments/actions", investment: @investment %>
@@ -100,7 +100,7 @@
<div class="show-actions-menu"> <div class="show-actions-menu">
<%= link_to image_path(investment.image, from: request.url), <%= link_to image_path(investment.image, from: request.url),
method: :delete, method: :delete,
class: 'button hollow alert expanded' do %> class: "button hollow alert expanded" do %>
<span class="icon-image"></span> <span class="icon-image"></span>
<%= t("images.remove_image") %> <%= t("images.remove_image") %>
<% end %> <% end %>
@@ -113,10 +113,10 @@
<h2><%= t("budgets.investments.show.supports") %></h2> <h2><%= t("budgets.investments.show.supports") %></h2>
<div class="text-center"> <div class="text-center">
<div id="<%= dom_id(investment) %>_votes"> <div id="<%= dom_id(investment) %>_votes">
<%= render partial: '/budgets/investments/votes', locals: { <%= render partial: "/budgets/investments/votes", locals: {
investment: investment, investment: investment,
investment_votes: investment_votes, investment_votes: investment_votes,
vote_url: vote_budget_investment_path(investment.budget, investment, value: 'yes') vote_url: vote_budget_investment_path(investment.budget, investment, value: "yes")
} %> } %>
</div> </div>
</div> </div>
@@ -136,7 +136,7 @@
<h2><%= t("budgets.investments.show.votes") %></h2> <h2><%= t("budgets.investments.show.votes") %></h2>
<div class="text-center"> <div class="text-center">
<div id="<%= dom_id(investment) %>_ballot"> <div id="<%= dom_id(investment) %>_ballot">
<%= render partial: 'ballot', locals: { <%= render partial: "ballot", locals: {
investment: investment, investment: investment,
investment_ids: investment_ids, investment_ids: investment_ids,
ballot: ballot, ballot: ballot,
@@ -187,26 +187,26 @@
<% end %> <% end %>
<% end %> <% end %>
<%= render 'shared/social_share', <%= render "shared/social_share",
share_title: t("budgets.investments.show.share"), share_title: t("budgets.investments.show.share"),
title: investment.title, title: investment.title,
image_url: image_absolute_url(investment.image, :thumb), image_url: image_absolute_url(investment.image, :thumb),
url: budget_investment_url(investment.budget, investment), url: budget_investment_url(investment.budget, investment),
description: t("budgets.investments.share.message", description: t("budgets.investments.share.message",
title: investment.title, title: investment.title,
handle: setting['org_name']), handle: setting["org_name"]),
mobile: t("budgets.investments.share.message", mobile: t("budgets.investments.share.message",
title: investment.title, title: investment.title,
handle: setting['twitter_handle']) %> handle: setting["twitter_handle"]) %>
<% if current_user %> <% if current_user %>
<div class="sidebar-divider"></div> <div class="sidebar-divider"></div>
<p class="sidebar-title"><%= t("shared.follow") %></p> <p class="sidebar-title"><%= t("shared.follow") %></p>
<%= render 'follows/follow_button', follow: find_or_build_follow(current_user, investment) %> <%= render "follows/follow_button", follow: find_or_build_follow(current_user, investment) %>
<% end %> <% end %>
<%= render 'communities/access_button', community: investment.community %> <%= render "communities/access_button", community: investment.community %>
</aside> </aside>
</div> </div>

View File

@@ -22,13 +22,13 @@
<% end %> <% end %>
<% if @heading && !@heading.content_blocks.where(locale: I18n.locale).empty? %> <% if @heading && !@heading.content_blocks.where(locale: I18n.locale).empty? %>
<%= render 'budgets/investments/content_blocks' %> <%= render "budgets/investments/content_blocks" %>
<% end %> <% end %>
<% if @map_location&.available? %> <% if @map_location&.available? %>
<%= render 'budgets/investments/map' %> <%= render "budgets/investments/map" %>
<% end %> <% end %>
<%= render "shared/tag_cloud", taggable: 'budget/investment' %> <%= render "shared/tag_cloud", taggable: "budget/investment" %>
<%= render 'budgets/investments/categories' %> <%= render "budgets/investments/categories" %>
<% if @heading && can?(:show, @ballot) %> <% if @heading && can?(:show, @ballot) %>
@@ -65,7 +65,7 @@
<ul class="ballot-list"> <ul class="ballot-list">
<% if @heading %> <% if @heading %>
<% @ballot.investments.by_heading(@heading.id).each do |investment| %> <% @ballot.investments.by_heading(@heading.id).each do |investment| %>
<%= render 'budgets/ballot/investment_for_sidebar', <%= render "budgets/ballot/investment_for_sidebar",
investment: investment, investment: investment,
investment_ids: @investment_ids %> investment_ids: @investment_ids %>
<% end %> <% end %>

View File

@@ -16,7 +16,7 @@
<% elsif investment.should_show_votes? %> <% elsif investment.should_show_votes? %>
<%= link_to vote_url, <%= link_to vote_url,
class: "button button-support small expanded", class: "button button-support small expanded",
title: t('budgets.investments.investment.support_title'), title: t("budgets.investments.investment.support_title"),
method: "post", method: "post",
remote: (display_support_alert?(investment) ? false: true ), remote: (display_support_alert?(investment) ? false: true ),
data: (display_support_alert?(investment) ? { data: (display_support_alert?(investment) ? {
@@ -28,7 +28,7 @@
</div> </div>
<% if reason.present? && !user_voted_for %> <% if reason.present? && !user_voted_for %>
<div class="js-participation-not-allowed participation-not-allowed" style='display:none' aria-hidden="false"> <div class="js-participation-not-allowed participation-not-allowed" style="display:none" aria-hidden="false">
<p> <p>
<small> <small>
<%= t("votes.budget_investments.#{reason}", <%= t("votes.budget_investments.#{reason}",
@@ -43,9 +43,9 @@
</div> </div>
<% end %> <% end %>
<% if user_voted_for && setting['twitter_handle'] %> <% if user_voted_for && setting["twitter_handle"] %>
<div class="share-supported"> <div class="share-supported">
<%= render partial: 'shared/social_share', locals: { <%= render partial: "shared/social_share", locals: {
title: investment.title, title: investment.title,
image_url: image_absolute_url(investment.image, :thumb), image_url: image_absolute_url(investment.image, :thumb),
url: budget_investment_url(investment.budget, investment), url: budget_investment_url(investment.budget, investment),

View File

@@ -1,4 +1,4 @@
<% provide :title do %><%= t('budgets.investments.index.title') %><% end %> <% provide :title do %><%= t("budgets.investments.index.title") %><% end %>
<% content_for :header_addon do %> <% content_for :header_addon do %>
<%= render "shared/search_form", <%= render "shared/search_form",
search_path: budget_investments_path(budget_id: @budget.id, page: 1), search_path: budget_investments_path(budget_id: @budget.id, page: 1),
@@ -18,7 +18,7 @@
<main id="budget-investments-main"> <main id="budget-investments-main">
<% unless params[:search].present? %> <% unless params[:search].present? %>
<%= render '/budgets/investments/header' %> <%= render "/budgets/investments/header" %>
<% end %> <% end %>
<% if params[:search].present? || params[:advanced_search].present? %> <% if params[:search].present? || params[:advanced_search].present? %>
@@ -73,7 +73,7 @@
<% if investments_default_view? %> <% if investments_default_view? %>
<% @investments.each do |investment| %> <% @investments.each do |investment| %>
<%= render partial: '/budgets/investments/investment', <%= render partial: "/budgets/investments/investment",
locals: { locals: {
investment: investment, investment: investment,
investment_ids: @investment_ids, investment_ids: @investment_ids,
@@ -84,7 +84,7 @@
<% else %> <% else %>
<% @investments.each do |investment| %> <% @investments.each do |investment| %>
<%= render partial: '/budgets/investments/investment_minimal', <%= render partial: "/budgets/investments/investment_minimal",
locals: { investment: investment } %> locals: { investment: investment } %>
<% end %> <% end %>
<% end %> <% end %>
@@ -95,7 +95,7 @@
<div class="small-12 medium-3 column"> <div class="small-12 medium-3 column">
<aside class="margin-bottom"> <aside class="margin-bottom">
<div id="sidebar"> <div id="sidebar">
<%= render '/budgets/investments/sidebar' %> <%= render "/budgets/investments/sidebar" %>
</div> </div>
</aside> </aside>
</div> </div>

View File

@@ -2,6 +2,6 @@
<div class="small-12 medium-9 column"> <div class="small-12 medium-9 column">
<h1><%= t("management.budget_investments.create") %></h1> <h1><%= t("management.budget_investments.create") %></h1>
<%= render '/budgets/investments/form', form_url: budget_investments_path(@budget) %> <%= render "/budgets/investments/form", form_url: budget_investments_path(@budget) %>
</div> </div>
</div> </div>

View File

@@ -3,7 +3,7 @@
<%= render "shared/canonical", href: budget_investment_url %> <%= render "shared/canonical", href: budget_investment_url %>
<% end %> <% end %>
<%= render partial: '/budgets/investments/investment_show', locals: { <%= render partial: "/budgets/investments/investment_show", locals: {
investment: @investment, investment: @investment,
investment_ids: @investment_ids, investment_ids: @investment_ids,
investment_votes: @investment_votes, investment_votes: @investment_votes,
@@ -18,7 +18,7 @@
<div class="tabs-content" data-tabs-content="investments_tabs"> <div class="tabs-content" data-tabs-content="investments_tabs">
<div class="tabs-panel is-active" id="tab-comments"> <div class="tabs-panel is-active" id="tab-comments">
<%= render partial: '/comments/comment_tree', locals: { comment_tree: @comment_tree, <%= render partial: "/comments/comment_tree", locals: { comment_tree: @comment_tree,
comment_flags: @comment_flags, comment_flags: @comment_flags,
display_comments_count: false } %> display_comments_count: false } %>
</div> </div>

View File

@@ -1,4 +1,4 @@
$("#<%= dom_id(@investment) %>_votes").html('<%= j render("/budgets/investments/votes", $("#<%= dom_id(@investment) %>_votes").html('<%= j render("/budgets/investments/votes",
investment: @investment, investment: @investment,
investment_votes: @investment_votes, investment_votes: @investment_votes,
vote_url: namespaced_budget_investment_vote_path(@investment, value: 'yes')) %>'); vote_url: namespaced_budget_investment_vote_path(@investment, value: "yes")) %>');

View File

@@ -1,10 +1,10 @@
<% provide :title, t("budgets.results.page_title", budget: @budget.name) %> <% provide :title, t("budgets.results.page_title", budget: @budget.name) %>
<% content_for :meta_description do %><%= @budget.description_for_phase('finished') %><% end %> <% content_for :meta_description do %><%= @budget.description_for_phase("finished") %><% end %>
<% provide :social_media_meta_tags do %> <% provide :social_media_meta_tags do %>
<%= render "shared/social_media_meta_tags", <%= render "shared/social_media_meta_tags",
social_url: budget_results_url(@budget), social_url: budget_results_url(@budget),
social_title: @budget.name, social_title: @budget.name,
social_description: @budget.description_for_phase('finished') %> social_description: @budget.description_for_phase("finished") %>
<% end %> <% end %>
<% content_for :canonical do %> <% content_for :canonical do %>
<%= render "shared/canonical", href: budget_results_url(@budget) %> <%= render "shared/canonical", href: budget_results_url(@budget) %>
@@ -46,11 +46,11 @@
<ul class="menu vertical no-margin-top no-padding-top"> <ul class="menu vertical no-margin-top no-padding-top">
<% @budget.headings.order('id ASC').each do |heading| %> <% @budget.headings.order("id ASC").each do |heading| %>
<li> <li>
<%= link_to heading.name, <%= link_to heading.name,
budget_results_path(@budget, heading_id: heading.to_param), budget_results_path(@budget, heading_id: heading.to_param),
class: heading.to_param == @heading.to_param ? 'is-active' : '' %> class: heading.to_param == @heading.to_param ? "is-active" : "" %>
</li> </li>
<% end %> <% end %>
</ul> </ul>
@@ -59,16 +59,16 @@
<div class="small-12 medium-9 large-10 column"> <div class="small-12 medium-9 large-10 column">
<%= link_to t("budgets.results.show_all_link"), "#", <%= link_to t("budgets.results.show_all_link"), "#",
class: "js-toggle-link button hollow margin-bottom float-right-medium", class: "js-toggle-link button hollow margin-bottom float-right-medium",
data: {'toggle-selector' => '.js-discarded', data: {"toggle-selector" => ".js-discarded",
'toggle-text' => t("budgets.results.hide_discarded_link")} %> "toggle-text" => t("budgets.results.hide_discarded_link")} %>
<%= render 'results_table', results_type: :compatible, <%= render "results_table", results_type: :compatible,
title: @heading.name, title: @heading.name,
heading_price: @heading.price, heading_price: @heading.price,
investments: @investments.compatible %> investments: @investments.compatible %>
<% if @investments.incompatible.present? %> <% if @investments.incompatible.present? %>
<%= render 'results_table', results_type: :incompatible, <%= render "results_table", results_type: :incompatible,
title: t("budgets.results.incompatibles"), title: t("budgets.results.incompatibles"),
heading_price: @heading.price, heading_price: @heading.price,
investments: @investments.incompatible %> investments: @investments.incompatible %>
@@ -78,10 +78,10 @@
<%= link_to budget_url(@budget) do %> <%= link_to budget_url(@budget) do %>
<small><%= t("budgets.results.investment_proyects") %></small> <small><%= t("budgets.results.investment_proyects") %></small>
<% end %><br> <% end %><br>
<%= link_to budget_url(@budget, filter: 'unfeasible') do %> <%= link_to budget_url(@budget, filter: "unfeasible") do %>
<small><%= t("budgets.results.unfeasible_investment_proyects") %></small> <small><%= t("budgets.results.unfeasible_investment_proyects") %></small>
<% end %><br> <% end %><br>
<%= link_to budget_url(@budget, filter: 'unselected') do %> <%= link_to budget_url(@budget, filter: "unselected") do %>
<small><%= t("budgets.results.not_selected_investment_proyects") %></small> <small><%= t("budgets.results.not_selected_investment_proyects") %></small>
<% end %> <% end %>
</p> </p>

View File

@@ -13,7 +13,7 @@
</div> </div>
<div class="small-12 medium-3 column info padding" data-equalizer-watch> <div class="small-12 medium-3 column info padding" data-equalizer-watch>
<p> <p>
<strong><%= t('budgets.show.phase') %></strong> <strong><%= t("budgets.show.phase") %></strong>
</p> </p>
<h2><%= t("budgets.phase.#{@budget.phase}") %></h2> <h2><%= t("budgets.phase.#{@budget.phase}") %></h2>
@@ -54,7 +54,7 @@
<% end %> <% end %>
<table class="table-fixed"> <table class="table-fixed">
<thead> <thead>
<th><%= t('budgets.show.group') %></th> <th><%= t("budgets.show.group") %></th>
</thead> </thead>
<tbody> <tbody>
<% @budget.groups.each do |group| %> <% @budget.groups.each do |group| %>