Commit 14af33e6 authored by c24b's avatar c24b

TAG for lang in menu

parent 8a231e13
...@@ -4,6 +4,7 @@ help = {"#project": ...@@ -4,6 +4,7 @@ help = {"#project":
"fr":{ "fr":{
"title": "Ajouter un projet", "title": "Ajouter un projet",
"content":"Cliquez sur le bouton et donnez un nom à votre projet",} "content":"Cliquez sur le bouton et donnez un nom à votre projet",}
,
"placement":"bottom", "placement":"bottom",
"position": "inside", "position": "inside",
}, },
...@@ -128,10 +129,9 @@ help = {"#project": ...@@ -128,10 +129,9 @@ help = {"#project":
} }
$( ".help" ).each(function(i, el) { $( ".help" ).each(function(i, el) {
lang = $("a#lang").data("lang")
//console.log("This", el) //console.log("This", el)
id = el.id id = el.id
div_id = "#"+id div_id = "#"+id
help_steps = Object.keys(help) help_steps = Object.keys(help)
console.log(help_steps) console.log(help_steps)
...@@ -144,7 +144,7 @@ $( ".help" ).each(function(i, el) { ...@@ -144,7 +144,7 @@ $( ".help" ).each(function(i, el) {
info = help[div_id] info = help[div_id]
//console.log(info) //console.log(info)
help_btn = '<span class="glyphicon glyphicon-question-sign" tab-index=0 data-toggle="popover" data-placement="'+info["placement"]+'" title="'+info["title"]+'" data-content="'+info["content"]+'"></span>' help_btn = '<span class="glyphicon glyphicon-question-sign" tab-index=0 data-toggle="popover" data-placement="'+info["placement"]+'" title="'+info[lang]["title"]+'" data-content="'+info[lang]["content"]+'"></span>'
if (info["position"] == "inside"){ if (info["position"] == "inside"){
......
...@@ -105,7 +105,7 @@ ...@@ -105,7 +105,7 @@
</ul> </ul>
</li> </li>
<li class="lang"> <li class="lang">
<a href="#" role="button" class="dropdown-toggle navbar-text"> <a href="#" id="lang" data-lang="{{user_parameters.language}}" role="button" class="dropdown-toggle navbar-text">
{% if user_parameters.language == "fr" %} {% if user_parameters.language == "fr" %}
<img value="{{user_parameters.language}}" src= "{% static "img/fr.png"%}" width="45%"/> <img value="{{user_parameters.language}}" src= "{% static "img/fr.png"%}" width="45%"/>
{%else %} {%else %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment