Extract link to verify account to a mehtod
We were using the same text and the same route in many places.
This commit is contained in:
@@ -38,7 +38,7 @@
|
||||
<% else %>
|
||||
<div class="callout warning margin-top">
|
||||
<%= t("budgets.investments.index.sidebar.verified_only",
|
||||
verify: link_to(t("users.verify_account"), verification_path)).html_safe %>
|
||||
verify: link_to_verify_account).html_safe %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% else %>
|
||||
|
||||
@@ -43,7 +43,6 @@
|
||||
<% if reason.present? && !ballot.has_investment?(investment) %>
|
||||
|
||||
<div class="js-participation-not-allowed participation-not-allowed" style="display:none">
|
||||
<% verify_account = link_to(t("users.verify_account"), verification_path) %>
|
||||
<% my_heading = link_to(investment.heading.name,
|
||||
budget_investments_path(budget_id: investment.budget_id,
|
||||
heading_id: investment.heading_id)) %>
|
||||
@@ -53,7 +52,7 @@
|
||||
<p>
|
||||
<small>
|
||||
<%= t("budgets.ballots.reasons_for_not_balloting.#{reason}",
|
||||
verify_account: verify_account, signin: link_to_signin,
|
||||
verify_account: link_to_verify_account, signin: link_to_signin,
|
||||
signup: link_to_signup, my_heading: my_heading,
|
||||
change_ballot: change_ballot,
|
||||
heading_link: heading_link(@assigned_heading, @budget)).html_safe %>
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<% else %>
|
||||
<div class="callout warning">
|
||||
<%= t("budgets.investments.index.sidebar.verified_only",
|
||||
verify: link_to(t("users.verify_account"), verification_path)).html_safe %>
|
||||
verify: link_to_verify_account).html_safe %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
<small>
|
||||
<%= t("votes.budget_investments.#{reason}",
|
||||
count: investment.group.max_votable_headings,
|
||||
verify_account: link_to(t("users.verify_account"), verification_path),
|
||||
verify_account: link_to_verify_account,
|
||||
signin: link_to_signin,
|
||||
signup: link_to_signup,
|
||||
supported_headings: (current_user && current_user.headings_voted_within_group(investment.group).map(&:name).sort.to_sentence)
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<% else %>
|
||||
<div class="callout warning margin-top">
|
||||
<%= t("budgets.investments.index.sidebar.verified_only",
|
||||
verify: link_to(t("users.verify_account"), verification_path)).html_safe %>
|
||||
verify: link_to_verify_account).html_safe %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% else %>
|
||||
|
||||
Reference in New Issue
Block a user