Subversion Repositories SmartDukaan

Rev

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

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