recuperation item en fonction de la langue
This commit is contained in:
parent
85056034b0
commit
d26b7680b7
3 changed files with 11 additions and 5 deletions
|
@ -40,4 +40,10 @@ translations:
|
|||
en: "comments"
|
||||
onlyin:
|
||||
fr: "Seulement en"
|
||||
fr: "Only in"
|
||||
en: "Only in"
|
||||
whatsthis:
|
||||
fr: "?"
|
||||
en: "?"
|
||||
loading:
|
||||
fr: "Chargement en cours..."
|
||||
en: "loading..."
|
||||
|
|
|
@ -17,8 +17,7 @@ end
|
|||
|
||||
conf=LocalConf.new
|
||||
|
||||
language=@item_rep.path
|
||||
language.sub!(/\/Scratch\//,'').sub!(/\/.*$/,'')
|
||||
language=@item_rep.path.sub(/\/Scratch\//,'').sub(/\/.*$/,'')
|
||||
conf.language=language
|
||||
|
||||
# the current item is an article
|
||||
|
|
|
@ -23,6 +23,7 @@ def tradOfKeywordIn(keyword, language)
|
|||
end
|
||||
|
||||
def item_of_language(language)
|
||||
puts %{lib/multi::item_of_language not implemented yet}
|
||||
return @item
|
||||
searched_path=@item_rep.path.sub(@conf.language,language)
|
||||
puts %{source path = #{@item_rep.path}, searched_path = #{searched_path}}
|
||||
@items.find { |i| i.reps[0].path == searched_path }
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue