Merge pull request #3040 from consul/help-feature

[Backport] Help feature
This commit is contained in:
Alberto
2018-11-14 13:32:35 +01:00
committed by GitHub
4 changed files with 15 additions and 6 deletions

View File

@@ -7,9 +7,12 @@
<div data-alert class="callout primary"> <div data-alert class="callout primary">
<%= t("debates.new.info", <%= t("debates.new.info",
info_link: link_to(t("debates.new.info_link"), new_proposal_path )).html_safe %> info_link: link_to(t("debates.new.info_link"), new_proposal_path )).html_safe %>
<%= link_to help_path, title: t('shared.target_blank_html'), target: "_blank" do %>
<% if feature?(:help_page) %>
<%= link_to help_path, title: t("shared.target_blank_html"), target: "_blank" do %>
<strong><%= t("debates.new.more_info") %></strong> <strong><%= t("debates.new.more_info") %></strong>
<% end %> <% end %>
<% end %>
</div> </div>
<%= render "form" %> <%= render "form" %>
</div> </div>

View File

@@ -4,7 +4,9 @@
<div class="row margin-top"> <div class="row margin-top">
<div class="text small-12 column"> <div class="text small-12 column">
<% if feature?(:help_page) %>
<%= back_link_to help_path %> <%= back_link_to help_path %>
<% end %>
<h1><%= t('pages.help.titles.how_to_use') %></h1> <h1><%= t('pages.help.titles.how_to_use') %></h1>

View File

@@ -40,7 +40,11 @@
<%= link_to(t("welcome.welcome.user_permission_verify_my_account"), verification_path, class: "button success radius expand") %> <%= link_to(t("welcome.welcome.user_permission_verify_my_account"), verification_path, class: "button success radius expand") %>
<% end %> <% end %>
<p class="text-center"> <p>
<%= link_to t("welcome.welcome.go_to_index"), proposals_path %> <% if feature?(:help_page) %>
<%= link_to t("welcome.welcome.go_to_index"), help_path %>
<% else %>
<%= link_to t("welcome.welcome.go_to_index"), root_path %>
<% end %>
</p> </p>
</div> </div>

View File

@@ -21,7 +21,7 @@ section "Creating header and cards for the homepage" do
label_en: 'Welcome to', label_en: 'Welcome to',
label_es: 'Bienvenido a', label_es: 'Bienvenido a',
link_url: 'help_path', link_url: 'http://consulproject.org/',
header: TRUE, header: TRUE,
image_attributes: create_image_attachment('header') image_attributes: create_image_attachment('header')
) )