Merge pull request #1417 from consul/admin_main_link

Main link in namespaces
This commit is contained in:
Enrique García
2017-02-12 23:04:46 +01:00
committed by GitHub
10 changed files with 27 additions and 3 deletions

View File

@@ -4,6 +4,14 @@ module AdminHelper
render "/#{namespace}/menu"
end
def namespaced_root_path
"/#{namespace}"
end
def namespaced_header_title
t("#{namespace}.header.title")
end
def menu_tags?
["tags"].include? controller_name
end

View File

@@ -10,7 +10,7 @@
<div class="expanded row">
<div class="top-bar">
<%= link_to setting['org_name'], admin_root_path, class: "logo show-for-small-only" %>
<%= link_to setting['org_name'], namespaced_root_path, class: "logo show-for-small-only" %>
<span data-responsive-toggle="responsive-menu" data-hide-for="medium" class="float-right">
<span class="menu-icon dark" data-toggle></span>
@@ -20,10 +20,10 @@
<div id="responsive-menu">
<div class="top-bar-title">
<h1>
<%= link_to admin_root_path, class: "hide-for-small-only" do %>
<%= link_to namespaced_root_path, class: "hide-for-small-only" do %>
<%= image_tag('logo_header.png', class: 'hide-for-small-only float-left', size: '80x80', alt: t("layouts.header.logo")) %>
<%= setting['org_name'] %>
&nbsp;|&nbsp;<%= t("admin.dashboard.index.title") %>
&nbsp;|&nbsp;<%= namespaced_header_title %>
<% end %>
</h1>
</div>

View File

@@ -1,6 +1,8 @@
---
en:
admin:
header:
title: Administration
actions:
actions: Actions
confirm: Are you sure?

View File

@@ -1,6 +1,8 @@
---
es:
admin:
header:
title: Administración
actions:
actions: Acciones
confirm: "¿Estás seguro?"

View File

@@ -1,6 +1,8 @@
---
en:
moderation:
header:
title: Moderation
comments:
index:
block_authors: Block authors

View File

@@ -1,6 +1,8 @@
---
es:
moderation:
header:
title: Moderación
comments:
index:
block_authors: Bloquear autores

View File

@@ -1,6 +1,8 @@
---
en:
officing:
header:
title: Polling
dashboard:
index:
title: Poll officing

View File

@@ -1,6 +1,8 @@
---
es:
officing:
header:
title: Votaciones
dashboard:
index:
title: Presidir mesa de votaciones

View File

@@ -1,6 +1,8 @@
---
en:
valuation:
header:
title: Valuation
menu:
title: Valuation
budgets: Participatory budgets

View File

@@ -1,6 +1,8 @@
---
es:
valuation:
header:
title: Evaluación
menu:
title: Evaluación
budgets: Presupuestos participativos