{% extends "base/module_base.html" %}

{% set active_page ='' %}

{% block pagehead %}

{% endblock %}



{% block sidebar %}
  {%include 'category/blocks/sidebar.html'%}


{%endblock%}



{% block content %}
<br><br>
<ul class="list-group">
	{%if category.subcategories%}
	{%for subcategory in category.subcategories%}
		<li class="list-group-item">
			<img 
				style="width:50px; height: 50px;" 
				{%set filename_ = '--'%}
				{%if subcategory.resources%}
					filename_ = subcategory.resources[0].filename
				{%endif%}
				src="{{url_for('category.subcategory_image', filename=filename_)}}">

			<a href="{{url_for('product.list', subcategory_id=subcategory.id)}}" class="btn btn-info"><i class="fa fa-clipboard-list"></i></a>
			{{subcategory.name}}
		</li>
	{%endfor%}
	{%endif%}
</ul>
	
{% endblock %}