From 61017bddd337dc9b93df72f4bcb36b1578dacb79 Mon Sep 17 00:00:00 2001 From: gitnnolabs Date: Mon, 28 Mar 2022 07:25:27 -0300 Subject: [PATCH] =?UTF-8?q?Garante=20que=20seja=20apresentado=20o=20doi=20?= =?UTF-8?q?original=20caso=20n=C3=A3o=20exista=20o=20doi=20com=20idioma.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- opac/webapp/templates/macros/article.html | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/opac/webapp/templates/macros/article.html b/opac/webapp/templates/macros/article.html index 37f8cf67e..1c49f8dee 100644 --- a/opac/webapp/templates/macros/article.html +++ b/opac/webapp/templates/macros/article.html @@ -1,11 +1,15 @@ {# Retorna o número do fascículo especial que deve ser exibido #} {% macro get_doi_by_lang(article, article_lang) -%} - {%- if article_lang -%} - {%- for doi in article.doi_with_lang %} - {%- if doi.language == article_lang -%} - {{ doi.doi }} - {%- endif -%} - {% endfor %} + {%- if article.doi_with_lang -%} + {%- if article_lang -%} + {%- for doi in article.doi_with_lang %} + {%- if doi.language == article_lang -%} + {{ doi.doi }} + {%- endif -%} + {% endfor %} + {%- endif -%} + {%- else -%} + {{ article.doi }} {%- endif -%} {%- endmacro %}