Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compatibilitiy of index.html.erb with the new voting booth view #106

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 32 additions & 14 deletions app/views/decidim/budgets/projects/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,47 @@
<% cell("decidim/budgets/limit_announcement", budget) %>

<div class="voting-wrapper <%="margin-top-3" if voting_booth_forced? %>">
<div class="row columns">
<% if voting_finished? %>
<h2 class="heading2">
<%= t("decidim.budgets.projects.projects_for", name: translated_attribute(budget.title)) %>
</h2>
<% else %>
<%= render partial: "budget_summary" %>
<%= render partial: "cancel_voting_modal" %>
<% end %>
</div>

<div class="row columns">
<h2 class="section-heading">
<%= render partial: "count" %>
<%= render partial: "budget_backButton" %>
<h2 class="section-heading budget-title">
<%= t(".budget_title", budget_title_h2: translated_attribute(budget.title)) %>
</h2>
<p class="budget-description">
<%= t(".budget_description_before") %>
<%= render partial: "count" %>
<%= t(".budget_description_after") %>
</p>
<% unless voting_mode? %>
<%= render partial: "budget_summary" %>
<% end %>
</div>

<div class="row">
<div id="projects" class="columns mediumlarge-12" aria-live="polite">
<div id="projects" class="columns mediumlarge-8 large-9" aria-live="polite">
<%= render partial: "projects" %>
</div>
</div>
</div>

<div class="row columns">
<% if voting_finished? %>
<h2 class="heading2">
<%= t("decidim.budgets.projects.projects_for", name: translated_attribute(budget.title)) %>
</h2>
<% else %>
<% if voting_mode? %>
<%= render partial: "budget_summary" %>
<% end %>
<%= render partial: "cancel_voting_modal" %>
<% end %>
</div>

<%= render partial: "decidim/budgets/partials/voting_help_modal" unless current_workflow.try(:disable_voting_instructions?) %>

<%= javascript_pack_tag("decidim_budgets_booth_voting") %>
<%= javascript_pack_tag("decidim_budgets_booth_voting") %>

<style>
.budget-title {margin-bottom: 0;}
.budget-description {margin-left: 12px;}
</style>
Loading