<?php
  /**
   * Category List
   *
   * @package Wojo Framework
   * @author wojoscripts.com
   * @copyright 2017
   * @version $Id: _category_list.tpl.php, v1.00 2017-05-05 10:12:05 gewa Exp $
   */
  if (!defined("_WOJO"))
      die('Direct access to this location is not allowed.');
?>
<?php foreach($this->featured as $row):?>
<div class="row celled align-middle" id="item_<?php echo $row->id;?>">
  <div class="columns shrink mobile-30 phone-100 phone-content-center half-padding">
    <img src="<?php echo Product::hasThumb($row->thumb, $row->id);?>" alt="<?php echo $row->title?>" class="wojo basic listing image">
  </div>
  <div class="columns mobile-70 phone-100 phone-content-center half-padding">
    <h4>
      <a href="<?php echo Url::url('/product', $row->slug);?>" class="inverted"><?php echo $row->title?></a>
    </h4>
    <?php echo Lang::$word->IN;?>
    <a href="<?php echo Url::url('/category', $row->cslug);?>" class="wojo small text inverted"><?php echo $row->name?></a>
    <div class="wojo small divided horizontal list align-middle">
      <div class="item">
        <i class="icon positive star"></i>
        <?php echo $row->likes;?>
      </div>
      <div class="item">
        <i class="icon secondary bubbles"></i>
        <?php echo $row->comments;?>
      </div>
      <div class="item">
        <?php echo Date::doDate("short_date", $row->created);?>
      </div>
    </div>
    <div class="wojo small icon text">
      <?php echo $row->memberships ? '<i class="icon membership"></i>' . $row->memberships : '<i class="icon minus alt"></i>' . Lang::$word->MEMBERSHIP . ':  ' . Lang::$word->NONE;?></div>
  </div>
  <div class="columns mobile-30 half-padding">
    <span class="wojo label"><?php echo Utility::renderPrice($row->is_sale, $row->price, $row->sprice, "negative");?></span>
  </div>
  <div class="columns shrink mobile-30 half-padding">
    <a data-tooltip="<?php echo Lang::$word->WISHLIST;?>" data-layout="list" data-id="<?php echo $row->id?>" class="wishlist">
      <i class="icon inverted heart"></i></a>
    &nbsp;
    <a data-tooltip="<?php echo Lang::$word->COMPARE;?>" data-layout="list" data-id="<?php echo $row->id?>" class="compare">
      <i class="icon inverted files"></i></a>
  </div>
  <div class="columns shrink mobile-40 content-right half-padding">
    <?php include(THEMEBASE . '/snippets/listButton.tpl.php');?>
  </div>
</div>
<?php endforeach;?>