Subversion Repositories SmartDukaan

Rev

Rev 20712 | Rev 20760 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
18388 naman 1
 
20683 amit.gupta 2
<script type="text/javascript" src="<?php echo $base_url;?>js/iscroll.js?v=<?php echo $staticversion;?>"></script>
19828 naman 3
<script type="text/javascript" src="<?php echo $base_url;?>js/deals.js?v=<?php echo $staticversion;?>"></script>
20752 amit.gupta 4
<script type="text/javascript" src="http://hammerjs.github.io/dist/hammer.min.js"></script>
5
 
19828 naman 6
<script type="text/javascript">
7
function loaded () {
8
	myScroll = new IScroll('#wrapper', { scrollX: true, scrollY: false, mouseWheel: true, click: true, tap: true });
20008 naman 9
	<?php if($id == 3):?>
10
		myScroll3 = new IScroll('#wrapper3', { scrollX: true, scrollY: false, mouseWheel: true, click: true, tap: true });
20328 amit.gupta 11
 
20008 naman 12
	<?php endif;?>
20711 amit.gupta 13
}
14
</script>
19828 naman 15
 
20711 amit.gupta 16
 
19605 naman 17
<script>
18
$(document).ready(function(){
19
 
20
	var scrollerwidth = 0;
21
	var scroller1width = 0;
20004 naman 22
	var scroller3width = 0;
19605 naman 23
	$('#scroller li').each(function() {
24
	    var $this = $(this);
25
	    scrollerwidth =scrollerwidth + $this.outerWidth() + 4;
26
	});
27
	var scrollerwidth = ""+(scrollerwidth + 2)+"px";
28
	$('#scroller1 li').each(function() {
29
	    var $this = $(this);
30
	    scroller1width =scroller1width + $this.outerWidth() + 10;
31
	});
32
	var scroller1width = ""+(scroller1width + 2)+"px";
33
 
20004 naman 34
	$('#scroller3 li').each(function() {
35
	    var $this = $(this);
36
	    scroller3width =scroller3width + $this.outerWidth() + 10;
37
	});
38
	var scroller3width = ""+(scroller3width + 2)+"px";
39
 
19605 naman 40
    $('#scroller').css("width",scrollerwidth);
41
    $('#scroller1').css("width",scroller1width);
20004 naman 42
    $('#scroller3').css("width",scroller3width);
19605 naman 43
 
44
});
45
</script>
46
<style>
47
.activate{
48
	color:green;
49
}
50
#wrapper,#wrapper1 {
51
	z-index: 1;
52
	bottom: 48px;
53
	left: 0;
54
	overflow: hidden;
55
}
56
#wrapper{
19620 naman 57
	max-height:40px;
19605 naman 58
	width: 97%;
19620 naman 59
	padding: 0px 5px;
60
	min-height: 0px;
19605 naman 61
}
62
#wrapper1{
63
	height:30px;
64
	width: 100%;
65
}
66
 
20004 naman 67
#wrapper3{
19605 naman 68
	z-index: 1;
20004 naman 69
	left: 0;
70
	overflow: hidden;
20008 naman 71
 	height:20px; 
20004 naman 72
	width: 100%;
73
}
74
 
75
#scroller, #scroller1,  #scroller3{
76
	z-index: 1;
19605 naman 77
	-webkit-tap-highlight-color: rgba(0,0,0,0);
78
	-webkit-transform: translateZ(0);
79
	-moz-transform: translateZ(0);
80
	-ms-transform: translateZ(0);
81
	-o-transform: translateZ(0);
82
	transform: translateZ(0);
83
	-webkit-touch-callout: none;
84
	-webkit-user-select: none;
85
	-moz-user-select: none;
86
	-ms-user-select: none;
87
	user-select: none;
88
	-webkit-text-size-adjust: none;
89
	-moz-text-size-adjust: none;
90
	-ms-text-size-adjust: none;
91
	-o-text-size-adjust: none;
92
	text-size-adjust: none;
93
}
94
 
20004 naman 95
#scroller ul,#scroller1 ul ,#scroller3 ul{
19605 naman 96
	list-style: none;
97
	padding: 0;
98
	margin: 0;
99
	width: 100%;	
100
	text-align: center;
101
}
102
 
20004 naman 103
#scroller li, #scroller1 li,#scroller3 li {
19605 naman 104
	display: block;
105
	float: left;
106
  	margin:2px;
107
	color:white;
108
	border-right: 1px solid #ccc;
20004 naman 109
/* 	background-color: #F2DEDE; */
19605 naman 110
	font-size: 12px;
111
}
112
#scroller li{
113
	font-weight:bold;
114
	padding: 7px;
115
	height: 37px;
116
	border-radius:5px;
117
	vertical-align:middle;
118
	font-size: 11px;
119
	min-width: 67px;
120
	max-width: 92px;
121
	text-transform: uppercase;
122
/* 	overflow: hidden ; */
123
	}
124
#scroller1 li {
125
	color: #555;
126
    padding: 5px;
127
    background : none;
128
    height: 23px;
129
    border : #E5E5E5 1px solid;
130
    margin:3px;
131
    text-transform: uppercase;
132
    font-size: 10px;
133
}
134
 
135
.cancelstyle{
136
	font-weight:bold;
137
	background: black;
138
    padding: 1px 3px;
139
    color: white;
140
	border-radius: 4px;
141
 
142
}
143
</style>
20006 naman 144
 
19656 naman 145
<?php
146
	if(isset($subcategories)){
147
		$catstr = explode("^",$subcategories);
148
	}
149
 
150
?>
19605 naman 151
 
16912 naman 152
 <ul class="nav nav-tabs catselect">
16929 anikendra 153
<?php foreach($categories AS $catId => $name):?>
17686 naman 154
 
19638 naman 155
  	<li class=" tab_layout <?php if((isset($id)) && $catId == $id):?>active<?php endif;?> col-xs-<?php echo (12/(count($categories)));?>">
19383 amit.gupta 156
	    <a href="/category/<?php echo $catId;?>"<?php if($id!=6 && $catId==6):?> id="popovertrigger4" data-container="body" data-toggle="popover" data-placement="bottom" data-content="Accessories at wholesale rates"<?php endif;?>>
19638 naman 157
	    	<?php if($catId==6):?>
158
	    		Accessories
159
	    	<?php else:?>
160
	    		<?php echo $name;?>
161
	    	<?php endif;?>
19383 amit.gupta 162
	    </a>
18008 amit.gupta 163
    </li>
19383 amit.gupta 164
<?php endforeach;?>		
16929 anikendra 165
</ul>
19661 naman 166
 
19909 naman 167
<?php if($this->params->action != 'linkdeal'):?>
168
	<?php if(isset($id)):?>
169
 
170
	<div class="filters row" >	
171
	<!-- For apps tab -->		
172
	<?php if($id==2):?>
173
		<div class="text-center">
174
			<div class="text_arrange cb">				
175
 
176
	                  <div class="card row" >
177
	                  	<a href = "<?php echo $base_url;?>appb"><span style="color:red;font-size:1.1em">Earn upto Rs. 10,000 per month</span> 
178
	                  		<!-- <u style="font-size:.9em">SEE HOW</u> -->
179
	                  		<button type="button" class="btn btn-primary btn-sm">SEE HOW</button>
180
	                  	</a><br>
181
	                  	<!--<span class="glyphicon glyphicon-download-alt" aria-hidden="true"></span>--><a href = "<?php echo $base_url;?>appb" style="font-size:1em; color:black"> Download these free apps for your customer.</a>
182
	            <hr style="margin:1px;">
183
	            <ul class="list-unstyled " style='margin:1px';>
184
	                <li class="row row_style" >
185
	                  	<div class="row showtips" style="font-size:.9em">
186
	                  		<br>
187
	                  		<div class='col-xs-11'>
188
	                  	 		<font color= 'grey'>Normally cashbacks are not approved for 30-40% cases.</font><br> <font color='red'>Click here </font>to see tips on increasing your profit. 
189
	                  	 	</div>
190
	                  	 	<div class='col-xs-1'><span class="glyphicon glyphicon-chevron-down"></span></div>
191
	                  	</div>
192
	                  </div>
193
	                  <div class="apptips hidden" style="background:#fff;">
194
	                    <div class="row">
195
 
196
	                    	<div class="col-xs-12" style='padding:1px'>
197
	                    		<ol style="text-align:left;background:#f9fafb">
198
	                    			<li>Only install new apps</li>
199
	                    			<li>Keep network connected after installing apps</li>   			
200
	                    			<li>Open the app 4-5 minutes after installing</li>
201
	                    			<li>Preferably register and login on app</li>
202
	                    		</ol>
203
	                    	</div>
204
 
205
	                    </div>
206
	                  </div>              
207
	                </li>
208
	            </ul>
209
	            <hr style="margin:1px;">
210
			</div>
211
		</div>		
212
	<?php endif;?>	
213
	<!-- End of apps tab code -->
214
	<?php if(isset($notification) && !empty($notification)):?>
215
		<?php if($notification['NotificationRule']['type']=='link'):?>
216
		<div class="alert alert-info text-center col-xs-12">
217
			<a target="_blank" href="<?php echo $notification['NotificationRule']['url'].'?user_id='.$logged_user['id'];?>" class="webnotification"><?php echo $notification['NotificationRule']['message'];?></a>
16929 anikendra 218
		</div>
19909 naman 219
		<?php elseif($notification['NotificationRule']['type']=='popup'):?>
220
		<?php 
221
			$url = $notification['NotificationRule']['url'];
222
			if(strpos($url, '?')!==false){
223
				$url .= '&user_id='.$logged_user['id'];
224
			}else{
225
				$url .= '?user_id='.$logged_user['id'];
226
			}
227
		?>
228
		<div class="herotext col-xs-9" style='padding-top:0px'>
229
			<!-- Daily profitable deals for you -->
230
			<script type="text/javascript">
231
				$(function(){
232
					$('.notificationMessage').html('<?php echo $notification['NotificationRule']['message'];?>');
233
					$('.notificationUrl').prop('href','<?php echo $url;?>').data('id','<?php echo $notification['NotificationRule']['id'];?>');
234
					if(showpopup(<?php echo $notification['NotificationRule']['id'];?>,<?php echo $notification['NotificationRule']['popup_display_count'];?>,<?php echo $notification['NotificationRule']['popup_display_interval'];?>)) {
235
						$('#notificationModal'+'<?php echo ucfirst($notification['NotificationRule']['popup_type']);?>').modal({show: true,keyboard: false,backdrop: 'static'});	
236
						var postdata = {'user_id':me,'notification_rule_id':'<?php echo $notification['NotificationRule']['id'];?>'};
237
						$.post( "/notification_views/add", postdata, function( data ) {});		
238
						ga('send', 'event', 'popupnotification-<?php echo $notification['NotificationRule']['id'];?>', 'shown', me);	
239
						var properties = {};
240
						properties.id = String('<?php echo $notification['NotificationRule']['id'];?>');
241
						pma.send('popupnotification','shown','<?php echo $notification['NotificationRule']['type'];?>',me,properties);			
242
					}
243
				});
244
			</script>
245
		</div>
246
		<?php endif;?>
16929 anikendra 247
	<?php endif;?>
19605 naman 248
 
249
 
19909 naman 250
		<?php if($id != 2 && ((!isset($brands) || ( empty($brands))) && (!isset($subcategories) || (empty($subcategories))))):?>
251
 
252
		<div class="col-xs-12 herotext" style='padding-top:0px'> 
253
 
254
				<?php echo $this->element('headerlinks',array(),array());?>
255
 
256
		</div>
257
 
19931 naman 258
		<?php elseif($id != 2 && $id != 6 && (isset($brands) || !empty($brands))):?>
259
 
19909 naman 260
		<div class="col-xs-12 herotext" style='padding-top:0px'> 
261
 
262
				<?php echo $this->element('headerlinks',array(),array());?>
263
 
264
		</div>
19605 naman 265
 
19909 naman 266
		<?php elseif($id!=2):?>
267
		<div class="col-xs-9 herotext" style='padding-top:0px'>                	
268
 
269
		    	<?php if($id == 6):?>
270
			    	<div id="wrapperboss" style="position:relative;">
271
					<!-- crossfilter start -->
20711 amit.gupta 272
						<script type="text/javascript">
273
						function loaded () {
274
							myScroll1 = new IScroll('#wrapper1', { scrollX: true, scrollY: false, mouseWheel: true, click: true, tap: true });
275
						}
276
						</script>
19909 naman 277
			    		<div id="wrapper1" style="background:white;">
278
							<div id="scroller1">
279
								<ul>
280
 
281
									<?php foreach($allbrandsubcat['idListInfo'] as $akey => $avalue ):?>
282
										<li class="upselect mtop getcancel quickclick" data-type="<?php if(isset($whatfirst)&&!empty($whatfirst)):?><?php echo $whatfirst;?><?php endif;?>" data-<?php echo $whatfirst."id";?>="<?php echo $akey;?>" ><?php echo $avalue;?> <span class="cancelstyle"> X </span></li>
283
									<?php endforeach;?>
284
 
285
									<?php foreach($allbrandsubcat['result'] as $ckey => $cvalue ):?>
286
										<?php if(in_array($cvalue[$whatsecondid],$secondloop)):?>
287
											<li class="upselect getcancel quickclick" data-type="<?php if(isset($whatsecond)&&!empty($whatsecond)):?><?php echo $whatsecond;?><?php endif;?>" data-<?php echo $whatsecond."id";?>="<?php echo $cvalue[$whatsecondid];?>">
288
											<?php echo $cvalue[$whatsecond];?> <span class="cancelstyle"> X </span>
289
											</li>
290
										<?php endif;?>
291
									<?php endforeach;?>
292
 
293
							    </ul>
294
							</div>
19605 naman 295
						</div>
19909 naman 296
 
297
					<!-- crossfilter end -->
298
 
299
 
300
			    	</div>
301
			    <?php elseif (isset($brands) ||  !empty($brands)):?>
302
			    	<?php echo $this->element('headerlinks',array(),array());?>
303
		    	<!-- Daily profitable deals for you	               	        -->
304
			    <?php endif;?>
305
 
306
		</div>   
307
 
308
 
309
		<div class="col-xs-3 pt7">
310
			<?php if($id == 6 && (isset($brands) && !empty($brands)) || (isset($subcategories) && !empty($subcategories))):?>
311
					<a class="btn btn-xs btn-danger filteraction clearfilters pull-right mr5" id="clearfilters" style="margin-top: 4px;padding: 2px 16px; background: #efefef !important;border: 1px; color: #333!important;font-size: 12px;"> RESET </a>
312
				<?php endif;?>	
313
		</div>
314
		<?php endif;?> 
19605 naman 315
 
19909 naman 316
 
16929 anikendra 317
	</div>
19909 naman 318
 
319
	<?php if($id == 6 && ((isset($brands) && !empty($brands)) || (isset($subcategories) && !empty($subcategories))) && (isset($allbrandsubcat) && !empty($allbrandsubcat))):?>
320
	<!-- for quickfilter start-->
321
					<div style="background:white;">
322
			    		<div id="wrapper" style="background:white;">
323
							<div id="scroller">
324
								<ul>
325
								<?php $colorcount = 0;?>
326
								<?php foreach($allbrandsubcat['result'] as $bkey => $bvalue ):?>
327
									<?php if(!in_array($bvalue[$whatsecondid],$secondloop)):?>
328
									<?php $strarr = explode(" ", $bvalue[$whatsecond]);?>
329
										<li class="downselect quickclick" data-type="<?php if(isset($whatsecond)&&!empty($whatsecond)):?><?php echo $whatsecond;?><?php endif;?>" data-<?php echo $whatsecond."id";?>="<?php echo $bvalue[$whatsecondid];?>" style="background:<?php echo $color[$colorcount];?>; <?php if(strlen($bvalue[$whatsecond]) >9 && sizeof($strarr)>1):?> font-size: 10px;line-height: 12px;<?php elseif(strlen($bvalue[$whatsecond]) <=9 && sizeof($strarr)>1):?>line-height: 12px;<?php else:?>line-height: 24px;<?php endif;?>">
18388 naman 330
 
19909 naman 331
											<?php 
332
												echo $strarr[0]; 
333
												if(sizeof($strarr) >1){
334
													echo "<br>";
335
													for($abs = 1; $abs< sizeof($strarr);$abs++)
336
													{
337
														echo $strarr[$abs]." ";
338
													}	
339
												}									
17700 naman 340
 
341
 
19909 naman 342
 
343
											?>
19605 naman 344
 
19909 naman 345
										</li>
346
										<?php $colorcount = $colorcount+1;
347
											if($colorcount == 6)
348
											{
349
												$colorcount = 0;
350
											}
19605 naman 351
										?>
19909 naman 352
									<?php endif;?>
353
								<?php endforeach;?>
354
							    </ul>
355
							</div>
19605 naman 356
						</div>
357
					</div>
19909 naman 358
	<!-- for quickfilter end-->
359
	<?php endif;?>
360
 
361
	<?php endif;?>
19661 naman 362
 
20328 amit.gupta 363
<?php endif;?>
20332 amit.gupta 364
<?php echo $outputcategory;?>