<div class="panel panel-default">
  <div class="panel-heading">
    <h3 class="panel-title"><i class="fa fa-comments"></i> {{ heading_title }}</h3>
  </div>
  
  <div class="panel-body">
    {% if products %}
      <div class="table-responsive">
        <table class="table table-bordered table-hover">
          <thead>
            <tr>
              <th>{{ column_image }}</th>
              <th>{{ column_name }}</th>
              <th>{{ column_views }}</th>
              <th>{{ column_status }}</th>
            </tr>
          </thead>
          <tbody>
            {% for product in products %}
              <tr>
                <td class="text-center" style="width: 50px;">
                  <img src="{{ product.image }}" alt="{{ product.name }}" class="img-thumbnail" />
                </td>
                <td>{{ product.name }}</td>
                <td>{{ product.viewed }}</td>
                <td>
                  <span class="badge {{ product.stock_status == 'In Stock' ? 'bg-success' : 'bg-warning' }}">
                    {{ product.stock_status }}
                  </span>
                </td>
              </tr>
            {% endfor %}
          </tbody>
        </table>
      </div>
    {% else %}
      <p>{{ text_no_results }}</p>
    {% endif %}
  </div>
</div>