aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuc Donnet2018-04-13 23:16:07 +0200
committerGitHub2018-04-13 23:16:07 +0200
commit264f373d7298278f84972d5b15470daea7728e72 (patch)
treef7d1cb0ae070e6905b9fed407b37cd8b2eeb2999
parent61f92d3bf28acd834b3e1e5d010829725992fb00 (diff)
parente14e10502e1396befc52446f34c2f42d4c08b2d3 (diff)
downloadchouette-core-264f373d7298278f84972d5b15470daea7728e72.tar.bz2
Merge pull request #396 from af83/6242-workbench-output
Ref #6242 Add changes to navbar menu and dashboard
-rw-r--r--app/views/layouts/navigation/_main_nav_left_content_stif.html.slim46
-rw-r--r--app/views/stif/dashboards/_dashboard.html.slim9
-rw-r--r--config/locales/dashboard.en.yml1
-rw-r--r--config/locales/dashboard.fr.yml1
-rw-r--r--config/locales/layouts.en.yml17
-rw-r--r--config/locales/layouts.fr.yml17
-rw-r--r--config/locales/merges.yml2
-rw-r--r--config/locales/workbench_outputs.en.yml6
-rw-r--r--config/locales/workbench_outputs.fr.yml4
9 files changed, 72 insertions, 31 deletions
diff --git a/app/views/layouts/navigation/_main_nav_left_content_stif.html.slim b/app/views/layouts/navigation/_main_nav_left_content_stif.html.slim
index 02614dcab..3741ef19b 100644
--- a/app/views/layouts/navigation/_main_nav_left_content_stif.html.slim
+++ b/app/views/layouts/navigation/_main_nav_left_content_stif.html.slim
@@ -5,44 +5,44 @@
.panel-heading
h4.panel-title
= link_to '#miOne', data: {toggle: 'collapse', parent: '#menu-items'}, 'aria-expanded' => 'false' do
- |Offres courantes
+ = t('layouts.navbar.current_offer.other')
#miOne.panel-collapse.collapse
.list-group
= link_to root_path, class: "list-group-item #{(@localizationUrl == 'workbenches#index') ? 'active' : ''}" do
- span Tableau de bord
+ span = t('layouts.navbar.dashboard')
+ = link_to workbench_output_path(current_user.workbenches.first), class: 'list-group-item' do
+ span = t('layouts.navbar.workbench_outputs.organisation')
= link_to '#', class: 'list-group-item' do
- span Offre de mon organisation
- = link_to '#', class: 'list-group-item' do
- span Offre IDF
+ span = t('layouts.navbar.workbench_outputs.idf')
.menu-item.panel
.panel-heading
h4.panel-title
= link_to '#miTwo', data: {toggle: 'collapse', parent: '#menu-items'}, 'aria-expanded' => 'false' do
- |Espace de travail
+ - t('activerecord.models.workbench.one').capitalize
#miTwo.panel-collapse.collapse
.list-group
- current_user.workbenches.each do |current_workbench|
= link_to workbench_path(current_workbench), class: "list-group-item #{params[:controller] == 'workbenches' ? 'active' : ''}" do
- span Jeux de données
+ span = t('activerecord.models.referential.other').capitalize
= link_to workbench_imports_path(current_workbench), class: "list-group-item #{(params[:controller] == 'imports') ? 'active' : ''}" do
- span Import
+ span = t('activerecord.models.import.other').capitalize
= link_to workbench_exports_path(current_workbench), class: "list-group-item #{(params[:controller] == 'exports') ? 'active' : ''}" do
- span Export
+ span = t('activerecord.models.export.other').capitalize
= link_to workgroup_calendars_path(current_workbench.workgroup), class: 'list-group-item' do
- span Modèles de calendrier
+ span = t('activerecord.models.calendar.other').capitalize
= link_to workbench_compliance_check_sets_path(current_workbench), class: 'list-group-item' do
- span Rapport de contrôle
+ span = t('activerecord.models.compliance_check_set.other').capitalize
= link_to compliance_control_sets_path, class: 'list-group-item' do
- span Jeux de contrôle
+ span = t('activerecord.models.compliance_control_set.other').capitalize
.menu-item.panel
.panel-heading
h4.panel-title
= link_to '#miThree', data: {toggle: 'collapse', parent: '#menu-items'}, 'aria-expanded' => 'false' do
- |Données
+ = t('layouts.navbar.referential_datas')
#miThree.panel-collapse.collapse
- if @referential.try(:id) && respond_to?(:current_referential)
@@ -57,7 +57,7 @@
span = t('companies.index.title')
= link_to '#', class: 'list-group-item disabled' do
- span Tracés
+ span = t('layouts.navbar.shapes')
= link_to referential_time_tables_path(current_referential), class: 'list-group-item' do
span = t('time_tables.index.title')
@@ -65,45 +65,45 @@
- else
.panel-body
em.text-muted
- = "Sélectionnez un jeu de données pour accéder à plus de fonctionnalités"
+ = t('layouts.navbar.select_referential_for_more_features')
.menu-item.panel
.panel-heading
h4.panel-title
= link_to '#miFour', data: {toggle: 'collapse', parent: '#menu-items'}, 'aria-expanded' => 'false' do
- |Synchronisation
+ = t('layouts.navbar.sync')
#miFour.panel-collapse.collapse
.list-group
= link_to line_referential_path(1), class: "list-group-item #{(@localizationUrl == 'line_referentials#show') ? 'active' : ''}" do
- span Synchronisation iLICO
+ span = t('layouts.navbar.sync_ilico')
= link_to stop_area_referential_path(1), class: "list-group-item #{(@localizationUrl == 'stop_area_referentials#show') ? 'active' : ''}" do
- span Synchronisation iCAR
+ span = t('layouts.navbar.sync_icar')
.menu-item.panel
.panel-heading
h4.panel-title
= link_to '#miFive', data: {toggle: 'collapse', parent: '#menu-items'}, 'aria-expanded' => 'false' do
- |Outils
+ = t('layouts.navbar.tools')
#miFive.panel-collapse.collapse
.list-group
= link_to Rails.application.config.try(:portal_url), target: '_blank', class: 'list-group-item' do
span
span.fa.fa-2x.fa-circle
- |Portail (POSTIF)
+ = t('layouts.navbar.portal')
= link_to Rails.application.config.try(:codifligne_url), target: '_blank', class: 'list-group-item' do
span
span.fa.fa-2x.fa-circle
- |iLICO
+ = t('layouts.navbar.ilico')
= link_to Rails.application.config.try(:reflex_url), target: '_blank', class: 'list-group-item' do
span
span.fa.fa-2x.fa-circle
- |iCAR
+ = t('layouts.navbar.icar')
= link_to '#', target: '_blank', class: 'list-group-item' do
span
span.fa.fa-2x.fa-circle
- |Support
+ = t('layouts.navbar.support') \ No newline at end of file
diff --git a/app/views/stif/dashboards/_dashboard.html.slim b/app/views/stif/dashboards/_dashboard.html.slim
index 7538c7fc7..74e607e26 100644
--- a/app/views/stif/dashboards/_dashboard.html.slim
+++ b/app/views/stif/dashboards/_dashboard.html.slim
@@ -5,8 +5,13 @@
h3.panel-title
= t('.organisation')
- .panel-body
- em.small.text-muted = t('.no_content')
+ - if @dashboard.workbench.output.referentials.present?
+ - @dashboard.workbench.output.referentials.first(5).each do |referential|
+ .list-group
+ = link_to referential.name, referential_path(referential), class: 'list-group-item'
+ - else
+ .panel-body
+ em.small.text-muted = t('.no_content')
.panel.panel-default
.panel-heading
diff --git a/config/locales/dashboard.en.yml b/config/locales/dashboard.en.yml
index 361a3cf2b..472f5bc2f 100644
--- a/config/locales/dashboard.en.yml
+++ b/config/locales/dashboard.en.yml
@@ -1,5 +1,6 @@
en:
dashboards:
+ main_nav_left: Dashboard
show:
title: "Dashboard %{organisation}"
workbench:
diff --git a/config/locales/dashboard.fr.yml b/config/locales/dashboard.fr.yml
index 1e1c095b1..65022fcb8 100644
--- a/config/locales/dashboard.fr.yml
+++ b/config/locales/dashboard.fr.yml
@@ -1,5 +1,6 @@
fr:
dashboards:
+ main_nav_left: Tableau de bord
show:
title: "Tableau de bord %{organisation}"
workbench:
diff --git a/config/locales/layouts.en.yml b/config/locales/layouts.en.yml
index d5717b400..954525ac4 100644
--- a/config/locales/layouts.en.yml
+++ b/config/locales/layouts.en.yml
@@ -10,9 +10,26 @@ en:
navbar:
return_to_referentials: "Return to data spaces"
select_referential: "Select data space"
+ select_referential_for_more_features: "Select data space for more foeatures"
select_referential_datas: "Select datas"
return_to_dashboard: "Return to Dashboard"
+ dashboard: Dashboard
referential_datas: "Datas"
+ current_offer:
+ one: Current offer
+ other: Current offers
+ workbench_output:
+ organisation: Organisation offers
+ idf: IDF offers
+ tools: Tools
+ sync: Synchronization
+ sync_icar: iCAR synchronization
+ sync_ilico: iLICO synchronization
+ icar: iCAR
+ ilico: iLICO
+ portal: Portal (POSTIF)
+ support: Support
+ shapes: Shapes
history_tag:
title: "Metadatas"
created_at: "Created at"
diff --git a/config/locales/layouts.fr.yml b/config/locales/layouts.fr.yml
index 17d23c756..f125a002d 100644
--- a/config/locales/layouts.fr.yml
+++ b/config/locales/layouts.fr.yml
@@ -10,9 +10,26 @@ fr:
navbar:
return_to_referentials: "Retour à la liste des espaces de données"
select_referential: "Sélection de l'espace de données"
+ select_referential_for_more_features: "Sélectionnez un jeu de données pour accéder à plus de fonctionnalités"
select_referential_datas: "Sélection des données"
return_to_dashboard: "Retour au Tableau de Bord"
+ dashboard: Tableau de bord
referential_datas: "Données"
+ current_offer:
+ one: Offres courante
+ other: Offres courantes
+ workbench_outputs:
+ organisation: Offres de mon organisation
+ idf: Offres IDF
+ tools: Outils
+ sync: Synchronisation
+ sync_icar: Synchronisation iCAR
+ sync_ilico: Synchronisation iLICO
+ icar: iCAR
+ ilico: iLICO
+ portal: Portail (POSTIF)
+ support: Support
+ shapes: Tracés
history_tag:
title: "Métadonnées"
created_at: "Créé le"
diff --git a/config/locales/merges.yml b/config/locales/merges.yml
index d8511a7b4..345727b74 100644
--- a/config/locales/merges.yml
+++ b/config/locales/merges.yml
@@ -8,7 +8,7 @@ fr:
show:
title: "Finalisation de l'offre %{name}"
actions:
- create: "Finaliser des Jeux de Données"
+ create: Finaliser des Jeux de Données
activerecord:
models:
merge: "Finalisation de l'offre"
diff --git a/config/locales/workbench_outputs.en.yml b/config/locales/workbench_outputs.en.yml
index 05cf52d0e..2af2f7023 100644
--- a/config/locales/workbench_outputs.en.yml
+++ b/config/locales/workbench_outputs.en.yml
@@ -1,7 +1,7 @@
en:
workbench_outputs:
show:
- title: "Finalisations de l'offre"
- see_current_output: "Voir l'Offre actuelle"
+ title: Current offers
+ see_current_output: See the current offer
table_headers:
- ended_at: "Offer created date"
+ ended_at: "Ended at"
diff --git a/config/locales/workbench_outputs.fr.yml b/config/locales/workbench_outputs.fr.yml
index 560888c54..b4d339434 100644
--- a/config/locales/workbench_outputs.fr.yml
+++ b/config/locales/workbench_outputs.fr.yml
@@ -1,7 +1,7 @@
fr:
workbench_outputs:
show:
- title: "Finalisations de l'offre"
+ title: Finaliser des jeux de données
see_current_output: "Voir l'Offre actuelle"
table_headers:
- ended_at: "Date et heure de création de l'offre"
+ ended_at: "Date et heure de création"