<?php 
/**
 * The browse view file of gift module of ZDOO.
 *
 * @copyright   Copyright 2009-2018 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
 * @license     ZPL (http://zpl.pub/page/zplv12.html)
 * @author      Yuting Wang <wangyuting@cnezsoft.com>
 * @package     gift
 * @version     $Id$
 * @link        http://www.zdoo.com
 */
?>
<?php include '../../common/view/header.html.php';?>
<div class='panel main-table'>
  <div class="cards">
    <?php foreach($gifts as $gift):?>
    <div class="col-sm-3">
      <div class="card">
        <?php echo html::a($this->createLink('gift', 'view', "giftID={$gift->id}"), "<img src='{$gift->imgUrl}'>", "class='media-wrapper'"); ?>
        <div class="card-heading">
          <div class="gift-item-footer">
            <div class="gift-item-footer-left">
              <?php echo html::a($this->createLink('gift', 'view', "giftID={$gift->id}"), $gift->name); ?>
            </div>
            <div class="gift-item-footer-right">
              <?php echo $lang->gift->score . ':' . $gift->score;?>
              <?php commonModel::printLink('exchange', 'create', "giftID={$gift->id}", $lang->gift->exchange, "class='btn mgl-10 btn-primary btn-sm' data-toggle='modal'");?>
            </div>
          </div>
        </div>
      </div>
    </div>
    <?php endforeach;?>
  </div>
  <div class='table-footer'><?php $pager->show();?></div>
</div>
<?php include '../../common/view/footer.html.php';?>
