| 13695 |
anikendra |
1 |
<?php echo $this->Html->css('slider');?>
|
|
|
2 |
<div class="container">
|
|
|
3 |
<?php if(!empty($categories)):?>
|
|
|
4 |
<?php foreach ($categories as $key => $category):?>
|
|
|
5 |
<div class="categorypreferences">
|
|
|
6 |
<form name="preferenceform" id="categorypreference-<?php echo $category['Category']['id'];?>" action="/preferences/add" method="POST">
|
|
|
7 |
<input type="hidden" name="user_id" value="<?php echo $logged_user['id'];?>"/>
|
|
|
8 |
<input type="hidden" name="category_id" value="<?php echo $category['Category']['id'];?>"/>
|
|
|
9 |
<div class="row">
|
|
|
10 |
<div class="categorytab">
|
|
|
11 |
<div class="col-xs-8"><span class="categoryname"><?php echo $category['Category']['name'];?></span> <button data-id="<?php echo $category['Category']['id'];?>" type="button" class="editcategorypreferences btn btn-xs">Edit</button></div>
|
|
|
12 |
<div class="col-xs-4" data-id="<?php echo $category['Category']['id'];?>">
|
|
|
13 |
<span class="categorytabcontrol" id="togglepreferences-<?php echo $category['Category']['id'];?>" data-id="<?php echo $category['Category']['id'];?>"></span>
|
|
|
14 |
</div>
|
|
|
15 |
</div>
|
|
|
16 |
</div>
|
|
|
17 |
<div class="row hidden" id="preferences-<?php echo $category['Category']['id'];?>">
|
|
|
18 |
<div class="brandpreferences">
|
|
|
19 |
<?php if(!empty($category['Brand'])):?>
|
|
|
20 |
<h5>My Favourite Brands</h5>
|
|
|
21 |
<?php foreach ($category['Brand'] as $key => $brand):?>
|
|
|
22 |
<div class="col-xs-6">
|
|
|
23 |
<?php if(!empty($preferredBrands) && in_array($brand['name'],$preferredBrands[$category['Category']['id']])):?>
|
|
|
24 |
<input type="checkbox" name="brand[]" value="<?php echo $brand['name'];?>" class="brandselector" data-catid="<?php echo $category['Category']['id'];?>" checked="checked"/>
|
|
|
25 |
<?php else:?>
|
|
|
26 |
<input type="checkbox" name="brand[]" value="<?php echo $brand['name'];?>" class="brandselector" data-catid="<?php echo $category['Category']['id'];?>"/>
|
|
|
27 |
<?php endif;?>
|
|
|
28 |
<?php echo $brand['name'];?>
|
|
|
29 |
</div>
|
|
|
30 |
<?php endforeach;?>
|
|
|
31 |
<?php endif;?>
|
|
|
32 |
</div>
|
|
|
33 |
<div class="clearfix"></div>
|
|
|
34 |
<div class="pricepreferences">
|
|
|
35 |
<h5>My Price Range</h5>
|
|
|
36 |
<?php if(!empty($preferredPrices) && isset($preferredPrices[$category['Category']['id']])){
|
|
|
37 |
$range = "[".intval($preferredPrices[$category['Category']['id']]['min_price']).",".intval($preferredPrices[$category['Category']['id']]['max_price'])."]";
|
|
|
38 |
}else{
|
|
|
39 |
$range = '[2000,78000]';
|
|
|
40 |
}?>
|
|
|
41 |
<div class="maxrange col-xs-12">
|
|
|
42 |
<input id="pricerange-<?php echo $category['Category']['id'];?>" value="" type="text" class="col-xs-12 slider" name="pricerange" data-slider-min="500" data-slider-max="80000" data-slider-step="500" data-slider-orientation="horizontal" data-slider-selection="after"data-slider-tooltip="show" data-slider-value="<?php echo $range;?>">
|
|
|
43 |
</div>
|
| 13747 |
anikendra |
44 |
<b class="minrange col-xs-6"><span class="cashbackrupee"></span>500</b>
|
|
|
45 |
<b class="maxrange col-xs-6 text-right"><span class="cashbackrupee"></span>80000</b>
|
| 13695 |
anikendra |
46 |
</div>
|
|
|
47 |
</div>
|
|
|
48 |
</form>
|
|
|
49 |
</div>
|
|
|
50 |
<?php endforeach;?>
|
|
|
51 |
<?php endif;?>
|
|
|
52 |
</div>
|
|
|
53 |
</div>
|
|
|
54 |
<script type="text/javascript" src="/js/jquery.jscroll.min.js"></script>
|
|
|
55 |
<script type="text/javascript" src="/js/profittill.js?v=<?php echo $staticversion;?>"></script>
|
|
|
56 |
<?php echo $this->Html->script('bootstrap-slider');?>
|
|
|
57 |
<script type="text/javascript">
|
|
|
58 |
$('.slider').slider()
|
|
|
59 |
</script>
|