Subversion-Projekte lars-tiefland.zeldi.de

Revision

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