| Line 60... |
Line 60... |
| 60 |
<?php endif;?>
|
60 |
<?php endif;?>
|
| 61 |
|
61 |
|
| 62 |
</div>
|
62 |
</div>
|
| 63 |
<?php endif;?>
|
63 |
<?php endif;?>
|
| 64 |
|
64 |
|
| - |
|
65 |
<!-- bulk price started-->
|
| - |
|
66 |
<?php if (isset($deal['availabilityInfo'][0]['bulkPricing']) && !empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
| - |
|
67 |
|
| - |
|
68 |
<?php
|
| - |
|
69 |
usort($deal['availabilityInfo'][0]['bulkPricing'], function($a, $b) {
|
| - |
|
70 |
return $a['quantity'] > $b['quantity'] ? -1 : 1;
|
| - |
|
71 |
});
|
| - |
|
72 |
|
| - |
|
73 |
foreach($deal['availabilityInfo'][0]['bulkPricing'] as $key => $value){
|
| - |
|
74 |
if($deal['availabilityInfo'][0]['maxQuantity']< $value['quantity']){
|
| - |
|
75 |
unset($deal['availabilityInfo'][0]['bulkPricing'][$key]);
|
| - |
|
76 |
}
|
| - |
|
77 |
}
|
| - |
|
78 |
debug($deal['availabilityInfo'][0]['bulkPricing']);
|
| - |
|
79 |
?>
|
| - |
|
80 |
|
| - |
|
81 |
<div class="" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php endif;?>">
|
| - |
|
82 |
<?php foreach($deal['availabilityInfo'][0]['bulkPricing'] AS $key => $value):?>
|
| - |
|
83 |
|
| 65 |
|
84 |
<div class="text-small<?php if($key >1 && $key <= intval(sizeof($deal['availabilityInfo'][0]['bulkPricing']))-2 && intval(sizeof($deal['availabilityInfo'][0]['bulkPricing'])) !=3):?> bulkpricingclass hidden<?php endif;?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php endif;?>>
|
| - |
|
85 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
| - |
|
86 |
<span class="rupee"></span><span style="font-size:13px; color:#ff0000"><strong><?php echo ($value['price']/($deal['quantity']*$value['quantity']));?></strong></span> per unit for
|
| - |
|
87 |
<?php echo $deal['quantity']*$value['quantity'];?> pcs
|
| - |
|
88 |
<?php else:?>
|
| - |
|
89 |
<span class="rupee"></span><span style="font-size:13px; color:#ff0000"><strong><?php echo $value['price'];?></strong></span> per unit for <?php echo $value['quantity'];?> pcs
|
| - |
|
90 |
<?php endif;?>
|
| - |
|
91 |
<?php if($key ==1 && intval(sizeof($deal['availabilityInfo'][0]['bulkPricing'])) >3):?>
|
| - |
|
92 |
<button type="button" class="btn btn-default btn-xs"><span class="glyphicon glyphicon-chevron-down morebulkprice"></span></button>
|
| - |
|
93 |
<?php endif;?>
|
| - |
|
94 |
</div>
|
| - |
|
95 |
|
| - |
|
96 |
|
| - |
|
97 |
<?php endforeach;?>
|
| - |
|
98 |
</div>
|
| - |
|
99 |
<?php endif;?>
|
| 66 |
|
100 |
|
| - |
|
101 |
<!-- bulk price ended-->
|
| - |
|
102 |
|
| 67 |
<?php if(isset($deal['ppq']) && !empty($deal['ppq']) &&($deal['ppq']>0)):?>
|
103 |
<?php if(isset($deal['ppq']) && !empty($deal['ppq']) &&($deal['ppq']>0) && isset($deal['availabilityInfo'][0]['bulkPricing']) && empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
| 68 |
<div class="text-small">
|
104 |
<div class="text-small">
|
| 69 |
<span class="rupee"></span><span style="font-size:14px; color:#ff0000"><strong><?php echo $deal['ppq'];?></strong></span> /- per unit.
|
105 |
<span class="rupee"></span><span style="font-size:14px; color:#ff0000"><strong><?php echo $deal['ppq'];?></strong></span> /- per unit.
|
| 70 |
</div>
|
106 |
</div>
|
| 71 |
<?php endif;?>
|
107 |
<?php endif;?>
|
| 72 |
|
108 |
|
| Line 74... |
Line 110... |
| 74 |
<div>
|
110 |
<div>
|
| 75 |
<?php if($key == 0 && isset($deal['showDp']) && $deal['showDp']==1 && !empty($deal['dp'])):?>
|
111 |
<?php if($key == 0 && isset($deal['showDp']) && $deal['showDp']==1 && !empty($deal['dp'])):?>
|
| 76 |
<div class="dp">DP <span class="cashbackrupee"></span> <?php echo $deal['dp'];?></div>
|
112 |
<div class="dp">DP <span class="cashbackrupee"></span> <?php echo $deal['dp'];?></div>
|
| 77 |
<?php endif;?>
|
113 |
<?php endif;?>
|
| 78 |
|
114 |
|
| - |
|
115 |
<?php if(!isset($deal['availabilityInfo'][0]['bulkPricing']) || empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
| - |
|
116 |
|
| 79 |
<span class="rupee"></span>
|
117 |
<span class="rupee"></span>
|
| 80 |
<?php if(isset($deal['gross_price']) && $deal['gross_price']>$deal['available_price']):?>
|
118 |
<?php if(isset($deal['gross_price']) && $deal['gross_price']>$deal['available_price']):?>
|
| 81 |
<span class="red pt2"><?php echo intval($deal['gross_price']);?></span>
|
119 |
<span class="red pt2"><?php echo intval($deal['gross_price']);?></span>
|
| 82 |
<?php else:?>
|
120 |
<?php else:?>
|
| 83 |
<span class="product_price" data-did="<?php echo $deal['_id']; ?>"><?php echo intval($deal['available_price']);?></span>
|
121 |
<span class="product_price" data-did="<?php echo $deal['_id']; ?>"><?php echo intval($deal['available_price']);?></span>
|
| 84 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
122 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
| 85 |
|
123 |
|
| 86 |
<font style="color:black;size:12px;"><?php echo "for ".$deal['quantity']." pcs.";?></font>
|
124 |
<font style="color:black;size:12px;"><?php echo "for ".$deal['quantity']." pcs.";?></font>
|
| 87 |
<?php endif;?>
|
125 |
<?php endif;?>
|
| 88 |
<?php endif;?>
|
126 |
<?php endif;?>
|
| - |
|
127 |
|
| - |
|
128 |
<?php endif;?>
|
| 89 |
|
129 |
|
| 90 |
|
130 |
|
| 91 |
<?php if(isset($deal['cash_back_type']) && !empty($deal['cash_back_type']) && $deal['cash_back_type']!=0 && $deal['cash_back']>0):?> +
|
131 |
<?php if(isset($deal['cash_back_type']) && !empty($deal['cash_back_type']) && $deal['cash_back_type']!=0 && $deal['cash_back']>0):?> +
|
| 92 |
<?php if($deal['cash_back_type'] == 2):?>
|
132 |
<?php if($deal['cash_back_type'] == 2):?>
|
| 93 |
<span class="cashbackrupee"></span> <span class="cashback"><?php echo $deal['cash_back'];?></span>
|
133 |
<span class="cashbackrupee"></span> <span class="cashback"><?php echo $deal['cash_back'];?></span>
|