From 69f29b4f49279544d8a0b94ec3de27cb0412b9b8 Mon Sep 17 00:00:00 2001 From: decabeza Date: Thu, 26 Oct 2017 19:07:47 +0200 Subject: [PATCH] shows create button and categories only if proposals phase is open --- app/views/legislation/processes/proposals.html.erb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/app/views/legislation/processes/proposals.html.erb b/app/views/legislation/processes/proposals.html.erb index a6346671e..cf6bd25b2 100644 --- a/app/views/legislation/processes/proposals.html.erb +++ b/app/views/legislation/processes/proposals.html.erb @@ -19,10 +19,12 @@ -
-

<%= link_to t("proposals.index.start_proposal"), new_legislation_process_proposal_path(@process), class: 'button expanded' %>

- <%= render 'legislation/proposals/categories', taggable: @process %> -
+ <% if @process.proposals_phase.open? %> +
+

<%= link_to t("proposals.index.start_proposal"), new_legislation_process_proposal_path(@process), class: 'button expanded' %>

+ <%= render 'legislation/proposals/categories', taggable: @process %> +
+ <% end %>