showSuccess.php 2.24 KB
Newer Older
Яков's avatar
first  
Яков committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?php
$translation = $cat->getTranslation();
slot('title', $translation[$culture]['title']);
include_component('main','breadcrumbs', array('cat' => $cat));
echo '<h1 class="content_title">' . $translation[$culture]['title'] . '</h1>';
?>
<div class="catalog_wrap with_filters">
    <?php
    if (isset($products)) {
        ?>
        <table class="to_div" cellspacing="0" cellpadding="0" width="100%">
            <tbody valign="top" align="left">
            <tr>
                <td width="100%" class="catalog_refresh">
                    <div class="catalog_category_childs_wrap">
                    <?php if (count($products) > 0) {
                        foreach ($products as $product) {
                            include_partial("product/product", array("product" => $product));
                        }
                    } ?>
                    </div>
                    <?php include_partial('catalog/pagination', array('count' => count($products_all), 'in_page_count' => $in_page_count)); ?>
                </td>
                <td width="1">
                    <?php
                    include_component('catalog', 'filter', array('cat' => $cat, 'product_ids' => $product_ids));
                    ?>
                </td>
            </tr>
            </tbody>
        </table>
        <?php
    } elseif (isset($cats)) {
        if (count($cats) > 0) {
            echo '<div class="catalog_category_childs_wrap">';
            foreach ($cats as $cat) {
                ?>
                <div class="catalog_category_child_item">
                    <a href="<?php echo url_for("@catalog_show?alias=" . $cat['alias']); ?>" class="anb">
                        <img src="/i/n.gif"
                             style="background-image: url(/u/i/<?php echo Page::replaceImageSize($cat['photo'], 'S'); ?>);"
                             alt="">
                        <span class="black_link"><?php echo $cat['Translation'][$culture]['title']; ?></span>
                    </a>
                </div>
                <?php
            }
            echo '</div>';
        }
    }
    ?>
</div>
<script>

    $('.discount_available').on('click', function (e) {
        if ($(window).width() < 650) {
            $(this).toggleClass('show');
        }
    })
</script>