| 13715 |
anikendra |
1 |
<!-- template for deals tab -->
|
| 18524 |
naman |
2 |
<script type="text/javascript">
|
|
|
3 |
$(document).on('click','.morebulkprice',function(){
|
|
|
4 |
if($(this).hasClass('glyphicon-chevron-down'))
|
|
|
5 |
{
|
|
|
6 |
$(this).parent().parent().parent().find('.bulkpricingclass').removeClass('hidden');
|
|
|
7 |
$(this).removeClass('glyphicon-chevron-down');
|
|
|
8 |
$(this).addClass('glyphicon-chevron-up');
|
|
|
9 |
}
|
|
|
10 |
else
|
|
|
11 |
{
|
|
|
12 |
$(this).parent().parent().parent().find('.bulkpricingclass').addClass('hidden');
|
|
|
13 |
$(this).removeClass('glyphicon-chevron-up');
|
|
|
14 |
$(this).addClass('glyphicon-chevron-down');
|
|
|
15 |
}
|
|
|
16 |
});
|
| 17598 |
naman |
17 |
$(document).ready(function(){
|
|
|
18 |
$('.uvideo').click(function(){
|
| 18370 |
naman |
19 |
window.history.pushState('forward', null, './forward');
|
| 17598 |
naman |
20 |
var source= $(this).data('source');
|
|
|
21 |
// alert(source);
|
| 17640 |
naman |
22 |
$('#content-add').empty();
|
| 17598 |
naman |
23 |
var content = "<iframe width='100%' height='100%' src='http://www.youtube.com/embed/"+source+"?autoplay=1'></iframe>"
|
| 17640 |
naman |
24 |
$('#content-add').append(content);
|
| 18023 |
amit.gupta |
25 |
var producttitle = $(this).closest(".productdetails").find(".producttitle").html().trim();
|
|
|
26 |
ga('send', 'event', 'Video Link Clicked', producttitle, me);
|
| 17640 |
naman |
27 |
$('#videoModal').modal('show');
|
| 17598 |
naman |
28 |
});
|
|
|
29 |
|
| 18370 |
naman |
30 |
if (window.history && window.history.pushState) {
|
|
|
31 |
|
|
|
32 |
$(window).on('popstate', function() {
|
|
|
33 |
$('#videoModal').modal('hide');
|
|
|
34 |
$('.text-center').empty();
|
|
|
35 |
});
|
|
|
36 |
|
|
|
37 |
}
|
|
|
38 |
|
| 17640 |
naman |
39 |
$('.close').click(function(){
|
|
|
40 |
$('#videoModal').modal('hide');
|
|
|
41 |
$('.text-center').empty();
|
|
|
42 |
});
|
|
|
43 |
|
|
|
44 |
$('#videoModal').click(function(){
|
|
|
45 |
$('#content-add').empty();
|
| 18370 |
naman |
46 |
window.history.back();
|
| 17640 |
naman |
47 |
// $('.text-center').append('<img src="/img/ajax-loader.gif"/>');
|
|
|
48 |
});
|
|
|
49 |
|
| 17963 |
naman |
50 |
$('.img-overlay a').click(function(){
|
|
|
51 |
$('#loadingModal').modal('show');
|
|
|
52 |
});
|
|
|
53 |
|
|
|
54 |
$('.objectlink a').click(function(){
|
|
|
55 |
$('#loadingModal').modal('show');
|
|
|
56 |
});
|
|
|
57 |
|
|
|
58 |
|
| 17762 |
naman |
59 |
$('.see_more_link a').click(function(){
|
| 18067 |
naman |
60 |
setCookie('brandschosen', '', -1, true);
|
|
|
61 |
setCookie('subcategorieschosen','',-1, true);
|
|
|
62 |
$('#loadingModal').modal('show');
|
| 17762 |
naman |
63 |
});
|
| 17818 |
manish.sha |
64 |
setTimeout(function () {$('.carterror').fadeOut('slow');}, 20000);
|
| 17598 |
naman |
65 |
});
|
| 17963 |
naman |
66 |
|
|
|
67 |
|
|
|
68 |
|
| 17598 |
naman |
69 |
</script>
|
|
|
70 |
|
| 17640 |
naman |
71 |
<div class="modal fade" id="videoModal">
|
| 17598 |
naman |
72 |
<div class="modal-dialog">
|
|
|
73 |
<div class="modal-content">
|
|
|
74 |
<div class="modal-body">
|
| 17640 |
naman |
75 |
<div class="text-center" id='content-add'>
|
|
|
76 |
|
| 17598 |
naman |
77 |
</div>
|
|
|
78 |
</div>
|
|
|
79 |
</div><!-- /.modal-content -->
|
|
|
80 |
</div><!-- /.modal-dialog -->
|
|
|
81 |
</div>
|
|
|
82 |
|
| 13682 |
anikendra |
83 |
<?php echo $this->element('unlikemodal');?>
|
| 17598 |
naman |
84 |
|
| 17640 |
naman |
85 |
|
| 17963 |
naman |
86 |
|
| 17804 |
manish.sha |
87 |
<?php if(isset($errorstr) && !empty($errorstr)):?>
|
|
|
88 |
<div class="alert alert-warning carterror">
|
|
|
89 |
<a href="#" class="close" data-dismiss="alert">×</a>
|
|
|
90 |
<?php echo $errorstr;?>
|
|
|
91 |
</div>
|
|
|
92 |
<?php endif;?>
|
| 17640 |
naman |
93 |
|
| 17693 |
naman |
94 |
<?php if($response_count ==1 && empty($deals)):?>
|
|
|
95 |
<div class="text-center">
|
|
|
96 |
<span class="nodeals" data-href="<?php echo $base_url;?>search/?user_id=<?php echo $logged_user['id'];?>">Didn't find your deal? Search for it</span>
|
|
|
97 |
</div>
|
| 17804 |
manish.sha |
98 |
<br><br><br>
|
| 17693 |
naman |
99 |
<?php else:?>
|
| 17640 |
naman |
100 |
|
| 16098 |
anikendra |
101 |
<?php if(!empty($deals) && !empty($deals[0])):?>
|
|
|
102 |
<?php foreach($deals AS $dealarray):?>
|
|
|
103 |
<div class="row card">
|
| 17963 |
naman |
104 |
<?php //debug($dealarray);?>
|
| 16098 |
anikendra |
105 |
<?php foreach ($dealarray as $key => $deal) :?>
|
| 17640 |
naman |
106 |
<?php //debug($deal);?>
|
|
|
107 |
<?php if(empty($deal))continue;?>
|
|
|
108 |
<?php if (!empty($deal['dealObject'])):?>
|
|
|
109 |
|
|
|
110 |
|
|
|
111 |
<!-- <dealobject part start here> -->
|
|
|
112 |
|
| 17898 |
naman |
113 |
<?php //debug($deal);?>
|
|
|
114 |
<?php if($deal['template_id'] == 1):?>
|
|
|
115 |
<div class="subcard">
|
|
|
116 |
<div class="col-xs-4">
|
|
|
117 |
<?php if($key == 0):?>
|
|
|
118 |
|
|
|
119 |
<div class="img-overlay">
|
|
|
120 |
<!-- <div class="product_actions like">
|
|
|
121 |
<span data-id="<?php //echo $deal['_id'];?>" class="likedeal <?php //if(isset($likedDeals[$deal['_id']])):?>active<?php //endif;?>">
|
|
|
122 |
</span>
|
|
|
123 |
</div> -->
|
| 17963 |
naman |
124 |
|
|
|
125 |
|
|
|
126 |
|
|
|
127 |
<div class="productthumb" data-id="<?php echo $deal['_id'];?>" style="8%">
|
|
|
128 |
<img src="<?php echo $base_url;?>app/webroot/timthumb.php?src=<?php echo urlencode ($deal['img_url']);?>&h=100&q=95" />
|
|
|
129 |
</div>
|
|
|
130 |
|
| 17898 |
naman |
131 |
|
|
|
132 |
<!-- <div class="product_actions dislike">
|
|
|
133 |
<span data-id="<?php //echo $deal['_id'];?>" class="dislikedeal <?php //if(isset($disLikedDeals[$deal['_id']])):?>active<?php //endif;?>">
|
|
|
134 |
</span>
|
|
|
135 |
</div> -->
|
|
|
136 |
</div>
|
|
|
137 |
|
|
|
138 |
|
|
|
139 |
<?php else:?>
|
|
|
140 |
<span class="pull-right arrowright"></span>
|
|
|
141 |
<?php endif;?>
|
|
|
142 |
</div>
|
| 17640 |
naman |
143 |
|
| 17963 |
naman |
144 |
<div class="col-xs-8 objectlink">
|
| 17898 |
naman |
145 |
<?php if(isset($deal['link1']) && !empty($deal['link1'])):?>
|
|
|
146 |
<div class="text-small">
|
|
|
147 |
<?php echo $deal['link1'];?>
|
|
|
148 |
</div>
|
|
|
149 |
<?php endif;?>
|
|
|
150 |
|
|
|
151 |
<?php if(isset($deal['link2']) && !empty($deal['link2'])):?>
|
|
|
152 |
<div class="text-small">
|
|
|
153 |
<?php echo $deal['link2'];?>
|
|
|
154 |
</div>
|
|
|
155 |
<?php endif;?>
|
| 17640 |
naman |
156 |
|
| 17898 |
naman |
157 |
<?php if(isset($deal['link3']) && !empty($deal['link3'])):?>
|
|
|
158 |
<div class="text-small">
|
|
|
159 |
<?php echo $deal['link3'];?>
|
|
|
160 |
</div>
|
|
|
161 |
<?php endif;?>
|
| 17640 |
naman |
162 |
|
| 17898 |
naman |
163 |
<?php if(isset($deal['link4']) && !empty($deal['link4'])):?>
|
|
|
164 |
<div class="text-small">
|
|
|
165 |
<?php echo $deal['link4'];?>
|
|
|
166 |
</div>
|
|
|
167 |
<?php endif;?>
|
|
|
168 |
|
|
|
169 |
<?php if(isset($deal['link5']) && !empty($deal['link5'])):?>
|
|
|
170 |
<div class="text-small">
|
|
|
171 |
<?php echo $deal['link5'];?>
|
|
|
172 |
</div>
|
|
|
173 |
<?php endif;?>
|
|
|
174 |
|
|
|
175 |
</div>
|
| 17640 |
naman |
176 |
</div>
|
|
|
177 |
|
| 17898 |
naman |
178 |
<?php endif;?>
|
|
|
179 |
<!-- <for template id 2 start here> -->
|
|
|
180 |
<?php if($deal['template_id'] == 2):?>
|
|
|
181 |
<div class="subcard">
|
|
|
182 |
<div class="col-xs-12" style="padding:0px;">
|
|
|
183 |
|
|
|
184 |
|
|
|
185 |
<div class="img-overlay" style="padding-bottom:5px;">
|
| 17963 |
naman |
186 |
<a href = "<?php echo $deal['link'];?>"><img src="<?php echo $base_url.$deal['img_url'];?>" width='100%'/></a>
|
| 17898 |
naman |
187 |
<br>
|
|
|
188 |
</div>
|
|
|
189 |
|
|
|
190 |
|
|
|
191 |
|
|
|
192 |
</div>
|
|
|
193 |
|
|
|
194 |
|
| 17640 |
naman |
195 |
</div>
|
|
|
196 |
|
| 17898 |
naman |
197 |
<?php endif;?>
|
|
|
198 |
<!-- <for template id 2 ends here> -->
|
| 17640 |
naman |
199 |
|
|
|
200 |
<!-- <dealObject part end here> -->
|
| 17766 |
manish.sha |
201 |
|
| 17640 |
naman |
202 |
<?php else:?>
|
| 17693 |
naman |
203 |
<?php //debug($deal);?>
|
| 17640 |
naman |
204 |
<div class="subcard">
|
| 17766 |
manish.sha |
205 |
<div class="col-xs-4 productimage">
|
| 16098 |
anikendra |
206 |
<?php if($key == 0):?>
|
| 17766 |
manish.sha |
207 |
<div class="img-overlay">
|
|
|
208 |
<div class="product_actions likeit" data-id="<?php echo $deal['_id'];?>" name="likediv_<?php echo $deal['_id'];?>">
|
|
|
209 |
<span class="likedeal <?php if(isset($likedDeals[$deal['_id']])):?>active<?php endif;?>">
|
|
|
210 |
</span>
|
|
|
211 |
</div>
|
| 18227 |
naman |
212 |
<div class="productthumb <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17835 |
amit.gupta |
213 |
<img src="<?php echo $base_url;?>app/webroot/timthumb.php?src=<?php echo urlencode($deal['thumbnail']);?>&h=100&q=95" />
|
| 17766 |
manish.sha |
214 |
</div>
|
|
|
215 |
<div class="product_actions dislikeit" data-id="<?php echo $deal['_id'];?>" name="dislikediv_<?php echo $deal['_id'];?>">
|
|
|
216 |
<span class="dislikedeal <?php if(isset($disLikedDeals[$deal['_id']])):?>active<?php endif;?>">
|
|
|
217 |
</span>
|
|
|
218 |
</div>
|
|
|
219 |
</div>
|
| 17640 |
naman |
220 |
|
| 17766 |
manish.sha |
221 |
<?php else:?>
|
|
|
222 |
<span class="pull-right arrowright"></span>
|
|
|
223 |
<?php endif;?>
|
| 17640 |
naman |
224 |
|
| 17766 |
manish.sha |
225 |
</div>
|
| 17177 |
naman |
226 |
|
| 17766 |
manish.sha |
227 |
<div class="col-xs-8 <?php if($key == 0):?>productdetails<?php else:?>productsmalldetails<?php endif;?>" data-id="<?php echo $deal['_id'];?>">
|
|
|
228 |
<?php if($key == 0):?>
|
|
|
229 |
<div class="product_title">
|
| 18227 |
naman |
230 |
<h5 class="producttitle <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-source="<?php echo $deal['source_id'];?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
231 |
<?php echo $deal['source_product_name'];?>
|
|
|
232 |
</h5>
|
|
|
233 |
</div>
|
|
|
234 |
|
|
|
235 |
<?php endif;?>
|
| 17963 |
naman |
236 |
<div class="col-xs-6 productpricedetails" style="position:relative;min-height:70px;padding-bottom:20px;">
|
| 17766 |
manish.sha |
237 |
<?php if($key == 0):?>
|
| 18227 |
naman |
238 |
<div class="<?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?> <?php if(strlen(strip_tags($deal['tagline'],'<p>')) == strlen($deal['tagline'])):?>product_short_description<?php endif;?> <?php if(!isset($deal['tagline'])):?>hidden<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
239 |
<?php //echo $deal['tagline'];?>
|
|
|
240 |
<?php
|
|
|
241 |
$str1=preg_replace('/<\/p>/i', '', $deal['tagline']);
|
|
|
242 |
if($str1 != $deal['tagline']) {
|
|
|
243 |
$str=preg_replace('/<p[^>]*>/i', '', $str1);
|
|
|
244 |
echo $str;
|
|
|
245 |
} else {
|
|
|
246 |
echo $deal['tagline'];
|
|
|
247 |
}
|
|
|
248 |
?>
|
|
|
249 |
</div>
|
|
|
250 |
<?php endif;?>
|
|
|
251 |
<?php if((isset($deal['showMrp']) && ($deal['showMrp']==1) && isset($deal['mrp']) && ($deal['mrp']>0))) :?>
|
|
|
252 |
<div class="text-small">
|
|
|
253 |
|
|
|
254 |
<?php if(isset($deal['showMrp']) && ($deal['showMrp']==1) && isset($deal['mrp']) && ($deal['mrp']>0)):?>
|
|
|
255 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
| 18436 |
naman |
256 |
MRP <span class="cashbackrupee"></span> <?php echo round(($deal['mrp']/$deal['quantity']), 2);?> per unit
|
| 17963 |
naman |
257 |
<!-- (Total <span class="cashbackrupee"></span> <?php //echo $deal['mrp']?>) -->
|
| 17766 |
manish.sha |
258 |
<?php else:?>
|
| 18003 |
naman |
259 |
MRP <span class="cashbackrupee"></span><?php echo $deal['mrp'];?>
|
| 17766 |
manish.sha |
260 |
<?php endif;?>
|
|
|
261 |
<?php endif;?>
|
|
|
262 |
|
|
|
263 |
</div>
|
|
|
264 |
<?php endif;?>
|
| 18436 |
naman |
265 |
|
|
|
266 |
|
|
|
267 |
|
| 18542 |
naman |
268 |
<?php if (isset($deal['availabilityInfo'][0]['bulkPricing']) && !empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
| 18524 |
naman |
269 |
<div class="" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php endif;?>">
|
| 18542 |
naman |
270 |
<?php foreach(array_reverse($deal['availabilityInfo'][0]['bulkPricing']) AS $bulkkey => $value):?>
|
| 18524 |
naman |
271 |
|
| 18542 |
naman |
272 |
<div class="<?php echo "select".$deal['availabilityInfo'][0]['item_id']."a".$value['quantity'];?> text-small<?php if($bulkkey >1 && $bulkkey <= 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;?>">
|
| 18524 |
naman |
273 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
|
|
274 |
<span class="rupee"></span><span style="font-size:13px; color:#ff0000"><strong><?php echo round(($value['price']/($deal['quantity']*$value['quantity'])),2);?></strong></span> per unit for
|
|
|
275 |
<?php echo $deal['quantity']*$value['quantity'];?> pcs
|
|
|
276 |
<?php else:?>
|
|
|
277 |
<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
|
|
|
278 |
<?php endif;?>
|
| 18542 |
naman |
279 |
<?php if($bulkkey ==1 && intval(sizeof($deal['availabilityInfo'][0]['bulkPricing'])) >3):?>
|
| 18524 |
naman |
280 |
<button type="button" class="btn btn-default btn-xs"><span class="glyphicon glyphicon-chevron-down morebulkprice"></span></button>
|
|
|
281 |
<?php endif;?>
|
|
|
282 |
</div>
|
|
|
283 |
|
|
|
284 |
|
| 18436 |
naman |
285 |
<?php endforeach;?>
|
|
|
286 |
</div>
|
|
|
287 |
<?php endif;?>
|
|
|
288 |
|
| 18524 |
naman |
289 |
<?php if(isset($deal['ppq']) && !empty($deal['ppq']) &&($deal['ppq']>0) && isset($deal['availabilityInfo'][0]['bulkPricing']) && empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
| 18436 |
naman |
290 |
<div class="text-small<?php if($deal['source_id'] == 4):?> accsproduct<?php endif;?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php endif;?>">
|
|
|
291 |
<span class="rupee"></span><span style="font-size:13px; color:#ff0000"><strong><?php echo $deal['ppq'];?></strong></span> per unit
|
|
|
292 |
<?php if(isset($deal['quantity']) && $deal['quantity']>1):?>
|
|
|
293 |
|
|
|
294 |
<font style="size:12px;"><?php echo "for ".$deal['quantity']." pcs";?></font>
|
|
|
295 |
<?php endif;?>
|
| 17766 |
manish.sha |
296 |
</div>
|
|
|
297 |
<?php endif;?>
|
|
|
298 |
|
| 18227 |
naman |
299 |
<div <?php if(!empty($deal['coupon'])):?>style="margin:0 !important"<?php endif;?> class="product_prices <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>" <?php if($key > 0):?>style='margin:0;'<?php endif;?>>
|
| 17766 |
manish.sha |
300 |
<div>
|
|
|
301 |
<?php if($key == 0 && isset($deal['showDp']) && $deal['showDp']==1 && !empty($deal['dp'])):?>
|
|
|
302 |
<div class="dp">DP <span class="cashbackrupee"></span> <?php echo $deal['dp'];?></div>
|
|
|
303 |
<?php endif;?>
|
| 18436 |
naman |
304 |
|
| 18524 |
naman |
305 |
<?php if(!isset($deal['availabilityInfo'][0]['bulkPricing']) || empty($deal['availabilityInfo'][0]['bulkPricing'])):?>
|
|
|
306 |
|
|
|
307 |
<?php if(isset($deal['gross_price']) && $deal['gross_price']>$deal['available_price']):?>
|
|
|
308 |
<?php if(isset($deal['quantity']) && $deal['quantity']<2):?>
|
|
|
309 |
<span class="rupee"></span><span class="red pt2"><?php echo intval($deal['gross_price']);?></span>
|
|
|
310 |
<?php endif;?>
|
|
|
311 |
<?php else:?>
|
|
|
312 |
<?php if(isset($deal['quantity']) && $deal['quantity']<2):?>
|
|
|
313 |
<span class="rupee"></span> <span class="product_price" data-did="<?php echo $deal['_id']; ?>"><?php echo intval($deal['available_price']);?></span>
|
|
|
314 |
|
|
|
315 |
<?php endif;?>
|
|
|
316 |
<?php endif;?>
|
|
|
317 |
<?php endif;?>
|
| 17963 |
naman |
318 |
|
| 18524 |
naman |
319 |
|
| 17766 |
manish.sha |
320 |
<?php if(isset($deal['cash_back_type']) && !empty($deal['cash_back_type']) && $deal['cash_back_type']!=0 && $deal['cash_back']>0):?> +
|
|
|
321 |
<?php if($deal['cash_back_type'] == 2):?>
|
|
|
322 |
<span class="cashbackrupee"></span> <span class="cashback"><?php echo $deal['cash_back'];?></span>
|
|
|
323 |
<?php else:?>
|
|
|
324 |
<?php echo $deal['cash_back'];?> %
|
|
|
325 |
<?php endif;?>
|
|
|
326 |
Cashback
|
|
|
327 |
<?php endif;?>
|
|
|
328 |
</div>
|
|
|
329 |
</div>
|
|
|
330 |
|
|
|
331 |
<?php if(isset($deal['gross_price']) && $deal['gross_price']>$deal['available_price']):?>
|
| 18227 |
naman |
332 |
<div class="text-small <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
333 |
Paytm cashback <?php echo ($deal['gross_price']-$deal['available_price']);?><br/> Net Price = <span class='product_price'><span class="rupee"></span> <?php echo $deal['available_price'];?></span>
|
|
|
334 |
</div>
|
|
|
335 |
<?php endif;?>
|
|
|
336 |
|
|
|
337 |
<?php if(isset($deal['coupon']) && !empty($deal['coupon'])):?>
|
| 18227 |
naman |
338 |
<div class="text-small <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
339 |
Use Coupon <span class="red"><?php echo $deal['coupon'];?></span>
|
|
|
340 |
</div>
|
|
|
341 |
<?php endif;?>
|
|
|
342 |
|
|
|
343 |
<?php if(isset($deal['codAvailable']) && !$deal['codAvailable']):?>
|
| 18542 |
naman |
344 |
|
| 18227 |
naman |
345 |
<div class="text-small <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
346 |
(COD not available)
|
|
|
347 |
</div>
|
|
|
348 |
<?php else:?>
|
|
|
349 |
<?php if($key!=0):?>
|
| 18227 |
naman |
350 |
<div class="text-small <?php if($deal['source_id'] == 4):?>accsproduct<?php else:?>viewproduct<?php endif;?>" data-id="<?php echo $deal['_id'];?>" data-source="<?php echo $deal['source_id'];?>" data-url="<?php if($deal['source_id'] == 4):?><?php echo $base_url."categories/dealdetail/".$deal['identifier'];?><?php else:?><?php echo $deal['marketPlaceUrl'];?><?php endif;?>" data-price="<?php echo intval($deal['available_price']);?>">
|
| 17766 |
manish.sha |
351 |
(COD available)
|
|
|
352 |
</div>
|
|
|
353 |
<?php endif;?>
|
|
|
354 |
<?php endif;?>
|
|
|
355 |
|
|
|
356 |
<div class="dealoffer <?php if(!isset($deal['offer']) || empty($deal['offer'])):?>hidden<?php endif;?> row">
|
|
|
357 |
<div class="<?php if(strlen(strip_tags($deal['offer'],'<p>')) == strlen($deal['offer'])):?>offerhasnohtml<?php endif;?> offertext" data-fulltext="<?php echo strip_tags($deal['offer']);?>">
|
|
|
358 |
<?php //echo $this->Text->truncate($deal['offer'],140);?>
|
|
|
359 |
<?php
|
|
|
360 |
if(strlen($deal['offer'])>0){
|
|
|
361 |
echo $deal['offer'];
|
|
|
362 |
}
|
|
|
363 |
else if($deal['source_id'] == 4){
|
|
|
364 |
echo "Exclusive price @ProfitMandi";
|
|
|
365 |
}
|
|
|
366 |
?>
|
|
|
367 |
</div>
|
|
|
368 |
|
|
|
369 |
</div>
|
| 18436 |
naman |
370 |
|
| 17766 |
manish.sha |
371 |
<?php if(isset($deal['videoLink']) && !empty($deal['videoLink'])):?>
|
| 17598 |
naman |
372 |
|
| 17766 |
manish.sha |
373 |
<div class="text-small" style = "padding-top:4px;padding-bottom:4px;">
|
|
|
374 |
<button type="button" class="btn btn-default btn-sm uvideo" data-source="<?php echo $deal['videoLink'];?>">
|
|
|
375 |
<span class="glyphicon glyphicon-play-circle"></span> Play Video
|
|
|
376 |
</button>
|
|
|
377 |
</div>
|
|
|
378 |
<?php endif;?>
|
|
|
379 |
|
| 17963 |
naman |
380 |
|
| 17804 |
manish.sha |
381 |
<?php $colors=0;
|
| 17818 |
manish.sha |
382 |
$colorsAvailable = array();
|
| 17804 |
manish.sha |
383 |
if($deal['source_id']==4 && isset($deal['availabilityInfo']) && count($deal['availabilityInfo']) >1){
|
|
|
384 |
foreach ($deal['availabilityInfo'] as $key => $value){
|
|
|
385 |
if($value['color']!=''){
|
|
|
386 |
$colors= $colors+1;
|
| 17818 |
manish.sha |
387 |
if($value['availability']>0){
|
|
|
388 |
array_push($colorsAvailable,$value);
|
|
|
389 |
}
|
| 17804 |
manish.sha |
390 |
}
|
|
|
391 |
}
|
|
|
392 |
}
|
|
|
393 |
?>
|
| 17818 |
manish.sha |
394 |
<?php if($colors>1 && count($colorsAvailable)>1):?>
|
| 17766 |
manish.sha |
395 |
<div class="see_more_colors" data-id="<?php echo $deal['skuBundleId']?>">
|
|
|
396 |
<span class="morecolors"><u>View More Colors</u></span>
|
|
|
397 |
</div>
|
| 17804 |
manish.sha |
398 |
<?php endif;?>
|
| 17963 |
naman |
399 |
|
|
|
400 |
|
|
|
401 |
<?php if(isset($deal['filterLink']) && !empty($deal['filterLink']) && isset($deal['filterText']) && !empty($deal['filterText'])):?>
|
|
|
402 |
<div class='see_more_link' style='position:absolute; bottom: 0px;'>
|
|
|
403 |
<?php if(count($dealarray) >1):?>
|
|
|
404 |
<?php if($key == 1):?>
|
|
|
405 |
<a href = <?php echo $deal['filterLink'];?> style='color:#A8A5A5;'><u><?php echo $deal['filterText'];?></u></a>
|
|
|
406 |
<?php endif;?>
|
|
|
407 |
<?php else:?>
|
|
|
408 |
<a href = <?php echo $deal['filterLink'];?> style='color:#A8A5A5;'><u><?php echo $deal['filterText'];?></u></a>
|
| 18064 |
naman |
409 |
|
| 17963 |
naman |
410 |
<?php endif;?>
|
|
|
411 |
</div>
|
|
|
412 |
|
|
|
413 |
<?php endif;?>
|
| 17766 |
manish.sha |
414 |
|
|
|
415 |
</div>
|
|
|
416 |
|
|
|
417 |
<?php if($deal['source_id']==4):?>
|
| 17906 |
manish.sha |
418 |
<?php if(isset($deal['availabilityInfo']) && count($deal['availabilityInfo'])>0 && $deal['availabilityInfo'][0]['maxQuantity']>0):?>
|
| 17766 |
manish.sha |
419 |
<div class="col-xs-2 cartaddition">
|
| 18007 |
manish.sha |
420 |
<div class="input-group number-spinner">
|
| 17766 |
manish.sha |
421 |
<span class="input-group-btn data-up">
|
| 18436 |
naman |
422 |
<button class="btn btn-default plusqtybutton" data-minquantity="<?php echo $deal['availabilityInfo'][0]['minBuyQuantity'];?>" <?php printf('data-bulkpricing = "%s"',htmlspecialchars(json_encode($deal['availabilityInfo'][0]['bulkPricing']), ENT_QUOTES, 'UTF-8'));?> data-quantitystep="<?php echo $deal['availabilityInfo'][0]['quantityStep'];?>" data-id="<?php echo $deal['availabilityInfo'][0]['item_id'];?>" data-price="<?php echo intval($deal['availabilityInfo'][0]['sellingPrice']);?>" data-did="<?php echo $deal['_id'];?>" data-dir="up" data-name="<?php echo $deal['source_product_name'];?>" data-brand="<?php echo $deal['brand'];?>" data-identifier="<?php echo $deal['identifier']; ?>"><span class="glyphicon glyphicon-plus plusqty"></span></button>
|
| 17766 |
manish.sha |
423 |
</span>
|
| 17950 |
manish.sha |
424 |
<input type="text" class="itemquantity" value="0" min="0" max="<?php echo $deal['availabilityInfo'][0]['maxQuantity'];?>" data-did="<?php echo $deal['_id'];?>" autocomplete="off" readonly>
|
| 17766 |
manish.sha |
425 |
<span class="input-group-btn data-dwn">
|
| 18436 |
naman |
426 |
<button class="btn btn-default minusqtybutton" data-minquantity="<?php echo $deal['availabilityInfo'][0]['minBuyQuantity'];?>" <?php printf('data-bulkpricing = "%s"',htmlspecialchars(json_encode($deal['availabilityInfo'][0]['bulkPricing']), ENT_QUOTES, 'UTF-8'));?> data-quantitystep="<?php echo $deal['availabilityInfo'][0]['quantityStep'];?>" data-id="<?php echo $deal['availabilityInfo'][0]['item_id'];?>" data-price="<?php echo intval($deal['availabilityInfo'][0]['sellingPrice']);?>" data-did="<?php echo $deal['_id'];?>" data-dir="dwn" data-name="<?php echo $deal['source_product_name'];?>" data-brand="<?php echo $deal['brand'];?>" data-identifier="<?php echo $deal['identifier']; ?>"><span class="glyphicon glyphicon-minus minusqty"></span></button>
|
| 17766 |
manish.sha |
427 |
</span>
|
|
|
428 |
</div>
|
|
|
429 |
</div>
|
|
|
430 |
|
| 17804 |
manish.sha |
431 |
<?php endif;?>
|
| 17766 |
manish.sha |
432 |
<?php endif;?>
|
|
|
433 |
</div>
|
|
|
434 |
|
|
|
435 |
|
| 17640 |
naman |
436 |
</div>
|
| 17818 |
manish.sha |
437 |
<?php if($deal['source_id']==4 && isset($deal['availabilityInfo']) && count($colorsAvailable) >1 && $colors>1):?>
|
| 17766 |
manish.sha |
438 |
<div class="morecoloroptions_<?php echo $deal['skuBundleId']?> hidden"
|
|
|
439 |
style="background: #fff;">
|
| 17804 |
manish.sha |
440 |
<div class="col-xs-2"></div>
|
|
|
441 |
<div class="col-xs-10 button-checkbox text-left">
|
| 17818 |
manish.sha |
442 |
<?php for($i=0; $i<count($colorsAvailable); $i=$i+2){
|
|
|
443 |
$value = $colorsAvailable[$i];
|
| 17804 |
manish.sha |
444 |
?>
|
|
|
445 |
<button type="button" class="btn btn-xs choosecolor colorbtn" data-id="<?php echo $value['item_id'];?>" data-price="<?php echo $value['sellingPrice'];?>" data-did="<?php echo $deal['_id'];?>" data-color="primary" data-max="<?php echo $value['maxQuantity'];?>"><?php echo strtoupper($value['color']);?></button>
|
|
|
446 |
<?php
|
|
|
447 |
$j = $i+1;
|
| 17818 |
manish.sha |
448 |
$value = $colorsAvailable[$j];
|
|
|
449 |
if($j<count($colorsAvailable)){?>
|
| 17804 |
manish.sha |
450 |
<button type="button" class="btn btn-xs choosecolor colorbtn" data-id="<?php echo $value['item_id'];?>" data-price="<?php echo $value['sellingPrice'];?>" data-did="<?php echo $deal['_id'];?>" data-color="primary" data-max="<?php echo $value['maxQuantity'];?>"><?php echo strtoupper($value['color']);?></button><br>
|
|
|
451 |
|
|
|
452 |
<?php }?>
|
|
|
453 |
<?php }?>
|
| 17766 |
manish.sha |
454 |
</div>
|
| 17804 |
manish.sha |
455 |
|
| 17766 |
manish.sha |
456 |
</div>
|
| 17804 |
manish.sha |
457 |
<?php endif;?>
|
| 17640 |
naman |
458 |
|
| 17766 |
manish.sha |
459 |
<?php endif;?>
|
| 17640 |
naman |
460 |
|
|
|
461 |
|
|
|
462 |
|
| 16098 |
anikendra |
463 |
<?php endforeach;?>
|
|
|
464 |
</div>
|
| 16368 |
anikendra |
465 |
<?php endforeach;?>
|
| 17640 |
naman |
466 |
|
|
|
467 |
|
| 16368 |
anikendra |
468 |
<?php if(!$noscrolling):?>
|
|
|
469 |
<?php if($this->params->controller=='store_products'):?>
|
|
|
470 |
<p class="text-center"><a class="btn btn-primary infitescroller" href="/store_products/getdeals/?page=<?php echo $page+1;?>&sort=<?php echo $sort;?>&direction=<?php echo $direction;?><?php echo $filterstr;?>">Load More</a></p>
|
|
|
471 |
<?php else:?>
|
| 18064 |
naman |
472 |
<!-- <p class="text-center"><a class="btn btn-primary infitescroller" href="/categories/getdeals/<?php //echo $id;?>/?page=<?php //echo ($page+1);?>&sort=<?php //echo $sort;?>&direction=<?php //echo $direction;?><?php //echo $filterstr;?>">Load More</a></p> -->
|
| 17963 |
naman |
473 |
|
| 18064 |
naman |
474 |
<p class="text-center"><a class="btn btn-primary infitescroller" href="<?php echo $nexturl;?>">Load More</a></p>
|
| 17696 |
naman |
475 |
|
| 17963 |
naman |
476 |
|
| 16368 |
anikendra |
477 |
<?php endif;?>
|
|
|
478 |
<?php endif;?>
|
| 13719 |
anikendra |
479 |
<?php else:?>
|
| 16368 |
anikendra |
480 |
<?php if($page==1):?>
|
|
|
481 |
<h4>The content you requested couldn't be found</h4>
|
|
|
482 |
<div class="text-center">
|
|
|
483 |
<button type="button" class="btn btn-xs btn-primary refresh">Retry</button>
|
|
|
484 |
</div>
|
|
|
485 |
<?php endif;?>
|
| 17193 |
anikendra |
486 |
<?php endif;?>
|
| 17693 |
naman |
487 |
|
|
|
488 |
|
|
|
489 |
|
|
|
490 |
<?php endif;?>
|