{% load i18n admin_static %}
{% load customadmin %}

<div id="content-main-icon">
<div class="module">
    
{% for app in app_list|add_model_icons:CUSTOM_ADMIN %}
    {% comment %}
    <table summary="{% blocktrans with app.verbose_app_name as name %}Models available in the {{ name }} application.{% endblocktrans %}">
    <caption><span class="section">{% blocktrans with app.verbose_app_name as name %}{{ name }}{% endblocktrans %}</span></caption>
	</table>
	{% endcomment %}
    {% for model in app.models %}
        {% if not model.perms.list_hide %} {# prevede perms['list_hide'] #}
            <div class = "box_model">
				<div class = "box_model_row">
					<div class="box_model_row_image"><a href="{{ model.admin_url }}"><img src="{% if model.image %}{{ model.image.url }}{% else %}/upy_static/images/upy_model.png{% endif %}" alt="{{model.name}}" /></a></div>
					<div class="box_model_row_name">
						{% if model.perms.change %}
                			<a href="{{ model.admin_url }}">{{ model.name }}</a>
			            {% else %}
                			{{ model.name }}
			            {% endif %}		
					</div>
					<div class="fixfloat"></div>
				</div>
				<div class = "box_model_row">
					<div class="box_model_row_add">
						{% if model.perms.add %}
                			<a href="{{ model.admin_url }}add/" class="addlink">{% trans 'Add' %}</a>
						{% endif %}
					</div>
					<div class="box_model_row_change">
						{% if model.perms.change %}
               				<a href="{{ model.admin_url }}" class="changelink">{% trans 'Change' %}</a>
						{% endif %}
					</div>
					<div class="fixfloat"></div>
				</div>
			</div>
        {% endif %}
    {% endfor %}

	
    <!-- </table> -->
{% endfor %}
<div class="fixfloat"></div>
</div> <!-- /module -->
<div class="module">
<table summary="{% blocktrans %}Other links{% endblocktrans %}">
<caption><span class="section">{% blocktrans %}Other links{% endblocktrans %}</span></caption>
</table>
{% for link in CUSTOM_LINK_LIST %}
<div class="app_icon_box">
	<a href="{{ link.link_url }}" class="section"><img src="{% if link.image %}{{ link.image.url }}{% else %}/upy_static/images/default_app_icon.png{% endif %}" alt="{% blocktrans with link.verbose_url_name as name %}{{ name }}{% endblocktrans %}" /></a>
    <p><a href="{{ link.link_url }}" class="section">{% blocktrans with link.verbose_url_name as name %}{{ name }}{% endblocktrans %}</a></p>
  </div> <!-- /module -->
{% endfor %}

<div class="fixfloat"></div>
<!-- </table> -->
</div> <!-- /module -->
</div>