{# Copyright (C) 2020 CERN. Copyright (C) 2020 Northwestern University. Invenio RDM Records is free software; you can redistribute it and/or modify it under the terms of the MIT License; see LICENSE file for more details. #} {% macro list_entities(entities) %} {% for entity in entities %} {# TODO: Is the first identifier given precedence or is "Orcid" given precedence? #} {# Assume first identifier is given precedence #} {% set main_identifier = entity.identifiers[0] if entity.identifiers and entity.identifiers[0] else {"scheme": ""} %} {%- if main_identifier.scheme == "Orcid" %} {# TODO: Other potential main identifiers #} {%- elif entity.type == "Organizational" %} {%- else %} {%- endif %} {{entity.name}} {% endfor %} {%- endmacro %}