Subversion Repositories SmartDukaan

Rev

Rev 13717 | Rev 13720 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

<!-- template for deals tab -->
<?php echo $this->element('unlikemodal');?>
<?php if(!empty($deals)):?>
    <?php foreach($deals AS $deal):?>
    <?php //debug($deal);?>
    <div class="row card">      
      <div class="col-xs-4 productthumb viewproduct">
        <img src="<?php echo $base_url;?>app/webroot/timthumb.php?src=<?php echo $deal['StoreProduct']['thumbnail'];?>&h=100" data-id="<?php echo $deal['StoreProduct']['id'];?>"/>
      </div>
      <div class="col-xs-6 productdetails viewproduct">
        <h5 class="producttitle" data-id="<?php echo $deal['StoreProduct']['id'];?>"><?php echo  $this->Text->truncate($deal['StoreProduct']['title'],140,array('ellipsis' => '...','exact' => false));?></h5>
        <div class="product_short_description <?php if(!isset($deal['StoreProduct']['tagline'])):?>hidden<?php endif;?>"><?php echo $deal['StoreProduct']['tagline'];?></div>
        <div class="product_prices">
          <div><span class="rupee"></span><span class="product_price"><?php echo $deal['StoreProduct']['available_price'];?></span></div>
          <?php if(isset($deal['StoreProduct']['cashback']) && !empty($deal['StoreProduct']['cashback'])):?><div><span class="cashbacklabel">Cashback</span><span class="cashbackrupee"></span> <span class="cashback"><?php echo $deal['StoreProduct']['cashback'];?></span></div><?php endif;?>
        </div>  
        <div class="dealoffer <?php if(!isset($deal['StoreProduct']['offer']) || empty($deal['StoreProduct']['offer'])):?>hidden<?php endif;?> row">
            <div class="col-xs-3 offerlabel">
              OFFER
            </div>
            <div class="col-xs-9 offertext">
              <?php echo $deal['StoreProduct']['offer'];?>
            </div>
        </div>        
      </div>
      <div class="col-xs-2 pull-right product_actions">
        <ul class="list-unstyled">
          <li data-id="<?php echo $deal['StoreProduct']['id'];?>" class="likedeal <?php if(isset($likedDeals[$deal['StoreProduct']['id']])):?>active<?php endif;?>">
          </li>
          <li data-id="<?php echo $deal['StoreProduct']['id'];?>" class="dislikedeal <?php if(isset($disLikedDeals[$deal['StoreProduct']['id']])):?>active<?php endif;?>">
          </li>
        </ul>
      </div>
    </div>       
  <?php endforeach;?>    
  <?php if($this->params->controller=='store_products'):?>
    <p class="text-center"><a class="btn btn-primary" href="/store_products/getdeals/?page=<?php echo $page+1;?>">Load More</a></p>
  <?php else:?>
    <p class="text-center"><a class="btn btn-primary" href="/categories/getdeals/<?php echo $id;?>/?page=<?php echo ($page+1);?>">Load More</a></p>
  <?php endif;?>
<?php endif;?>