Subversion-Projekte lars-tiefland.zeldi.de_alt

Revision

Revision 42 | Details | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
2 lars 1
{extends file="page.tpl"}
2
{block name=content}
3
<!-- $Id: subdir.tpl 2980 2022-12-01 11:45:36Z erling $ BEGIN -->
4
 
5
    {include file="shopposition.tpl"}
6
 
7
<div class="subdir_info_wrapper">
8
    {if is_countable($subdir->medium) && count($subdir->medium) > 0}
38 lars 9
        {if $subdir->medium[1]->medium->name}
2 lars 10
            <div class="subdir_bild">
38 lars 11
                {if $subdir->medium[1]->medium->name}
12
                    <img src="/images/upload/{$subdir->medium[1]->medium->folder}/gr/{$subdir->medium[1]->medium->name}" alt="">
2 lars 13
                {/if}
14
            </div>
38 lars 15
        {elseif $subdir->medien[0]->medium->name}
16
            <div class="subdir_bild">
17
                <img src="/images/upload/{$subdir->medium[0]->medium->folder}/gr/{$subdir->medium[0]->medium->name}" alt="">
2 lars 18
            </div>
19
        {/if}
20
    {/if}
21
 
22
    {if $subdir->description}
23
        <div class="subdir_text">
24
            <h1>{$subdir->Alternativer_Titel|default:$subdir->name}</h1>
25
            {$subdir->description}
26
 
27
            {if $subdir->description2}
28
                <p class="infotext_subdir"><a href="#infotext">Mehr lesen</a></p>
41 lars 29
            {/if}
30
        </div>
2 lars 31
    {/if}
32
</div>
33
 
8 lars 34
{if $subdir->subdirs|count}
2 lars 35
<div class="subdir">
36
    {foreach $subdir->subdirs as $subDir}
37
    <div class="box_subdir">
10 lars 38
            <a href="/directory/{$subDir->id}-{$subDir->slug}">
2 lars 39
                <div class="top"
40
                {if $subDir->medium[0]->medium->name != ''}
41
                    style="
42
                        background: url('/images/upload/{$subDir->medium[0]->medium->folder}/gr/{$subDir->medium[0]->medium->name}') no-repeat center;
43
                        background-size:cover;
44
                    "
45
                {/if}
41 lars 46
                alt="{$subDir.name}"
2 lars 47
                >
41 lars 48
 
2 lars 49
                </div>
50
                <div class="bottom bold">
51
                    <span>{$subDir->name}</span>
52
                </div>
53
            </a>
54
        </div>
55
    {/foreach}
56
</div>
57
{/if}
58
 
59
<div class="subdir_artikel_wrapper">
60
    {if is_countable($subdir->items)}
61
        {if count($subdir->items) > 0}
62
 
63
 
64
            {if (isset($dropdown_opts) && ($dropdown_opts|count>0 )|| ( isset($bool_opts) && $bool_opts|count>0)) && $ini.filter_auspraegungen==1}
65
                <div class="subdir_sort loading">
66
                    <form name="sort" action="" method="get" id="modellForm1">
67
                        <strong>Produktfilter:</strong>
68
                        <div class="break"></div>
69
            	        <input type="hidden" name="navigation" value="{$subdir->id}" />
70
                        <input type="hidden" name="Father" value="{$subdir->id}" />
71
                        {include file="auspraegungen.tpl" nocache}
72
            	    </form>
73
                </div>
74
            {/if}
75
 
76
 
77
            {if $smarty.const.USE_SMARTY_PAGINATE===true}
78
            {include file="pagination.tpl"}
79
            {/if}
80
 
81
            {if $ini.subdir.switch_css==1}
82
            {include file="switch_css.tpl"}
83
            {/if}
84
            <div class="subdir_artikel">
85
                {foreach $subdir->items as $item}
86
                    {if $item->articlemaster==1}
87
                        {include file="subdir_artstamm.tpl"  artstamm=$item}
41 lars 88
                    {else}
2 lars 89
                        {include file="item_small.tpl"}
90
                    {/if}
41 lars 91
                {/foreach}
2 lars 92
            </div>
93
 
94
            {if $smarty.const.USE_SMARTY_PAGINATE===true}
95
                {include file="pagination.tpl"}
96
            {/if}
97
 
98
        {/if}
99
    {else}
100
        <div class="box_2">
101
            <div class="box_top">&nbsp;</div>
102
            <div class="box_middle">Keine Artikel gefunden</div>
103
        </div>
41 lars 104
    {/if}
105
    <div class="break"></div>
106
 
2 lars 107
    {if $subdir->description2}
108
    <section id="infotext">
109
        <div class="inner">
41 lars 110
 
43 lars 111
            {if $subdir->medium[2]->medium->name}
41 lars 112
            <div class="subdir_bild">
43 lars 113
                <img src="/images/upload/{$subdir->medium[2]->medium->folder}/gr/{$subdir->medium[2]->medium->name}" alt="">
41 lars 114
            </div>
115
            {/if}
116
 
2 lars 117
            <div id="beschreibung2">
118
                <a name="infotext" id="infotext"></a>
119
                {$subdir->description2}
120
                <p class="topbutton_text"><a href="#top">Nach oben</a></p>
121
            </div>
122
        </div>
123
    </section>
124
    {/if}
41 lars 125
 
2 lars 126
</div>
127
 
128
<script>
41 lars 129
    $('.box_subdir'). click(function(){
2 lars 130
        window.location.href = $('.bottom a', this).attr("href");
41 lars 131
    });
132
 
2 lars 133
    $('.infotext_subdir a').click(function(e){
134
        e.preventDefault();
135
        let target = $(this).attr('href');
41 lars 136
        let offset = $(target).offset();
2 lars 137
        let scrollTo = $(target).offset().top;
138
        $("html, body").animate( { scrollTop: scrollTo }, 800, 'swing');
41 lars 139
    });
140
 
2 lars 141
</script>
142
 
143
<script>
144
    $(document).ready(function() {
145
        $('.tooltip_opener').mouseenter(function(){
146
            let id = $(this).attr('id');
147
            id = id.split("_");
148
            id = id[1];
41 lars 149
 
2 lars 150
            $('#tooltip_'+id).css("display","block");
151
        }).mouseleave(function(){
152
            $('.tooltip').hide();
153
        });
154
    });
155
</script>
156
<script>
157
    $(document).ready(function () {
41 lars 158
 
2 lars 159
        // ME: update filter using session data
160
        /*
161
        if($.session._cookieCache) {
162
            $.each($.session._cookieCache, function(index,value){
163
                console.log(index + " - " + value);
164
                var type = $("#" + index).attr("type");
165
                switch(type) {
166
                    case "checkbox":
167
                        $('#' + index).trigger("click");
168
                    break;
169
                    default:
170
                    break;
171
                }
172
            });
173
        }
174
        */
175
 
176
        $(".newsorting").css("display", "none");
177
 
178
        $("#drsort").change(function () {
179
 
180
            $(".box_2").css("background-color", "transparent");
181
            $(".subdir_artikel").css("background-color", "#ccc");
182
            $(".loader").show();
183
 
184
            let selid = $('#drsort').val();
185
            let mode = "result";
186
 
187
            let daten = $('#modellForm1').serializeArray();
188
            $.ajax({
189
                type: "POST",
190
                url: "/module/artikelmodell.php?mode=" + mode + "&sort=" + selid,
191
                data: daten,
192
                async: false,
193
                success: function (html) {
194
 
195
                    if (mode === "result") {
196
                        $(".pagination_container").css("display", "none");
197
 
198
                        $('.subdir_artikel').html(html);
199
                        $(".subdir_artikel").css("background-color", "transparent");
200
                        $(".loader").hide();
201
 
202
                        $(".newsorting").css("display", "block");
203
 
204
                    }
205
                }
206
            })
207
 
208
        });
209
    })
210
</script>
211
<style>
212
 
213
.item_slider_img:hover img {
214
    scale:110%;
215
}
216
 
217
</style>
218
<!-- $Id: subdir.tpl 2980 2022-12-01 11:45:36Z erling $ END -->
219
{/block}
220