{% extends 'base.html' %}
{% load i18n %}
{% block title %}{% trans "Data Processing" %}{% endblock %}

{% block page_header %}
    {% include "horizon/common/_page_header.html" with title=_("Image Registry") %}
{% endblock page_header %}

{% block main %}

<div class="image_registry">
    {{ image_registry_table.render }}
</div>

<script type="text/javascript">
  addHorizonLoadEvent(function () {
      horizon.modals.addModalInitFunction(function (modal) {
        var tags = JSON.parse($("#id_tags_list").val());
        $.each(tags, function(i, tag) {
          var tagspan = '<span class="label label-info" style="float: left;display: block; margin: 2px;">' +
                         tag +
                         '<i class="glyphicon glyphicon-remove" onclick="remove_tag(this);"></i></span>';
          $("#image_tags_list").append(tagspan);
        });
     });
  });
</script>
{% endblock %}