Subversion-Projekte lars-tiefland.ci

Revision

Revision 1889 | Revision 1895 | Zur aktuellen Revision | Ganze Datei anzeigen | Leerzeichen ignorieren | Details | Blame | Letzte Änderung | Log anzeigen | RSS feed

Revision 1889 Revision 1891
Zeile 1... Zeile -...
1
{include file="header.tpl"}
-
 
2
		<!-- $Id: bilder.tpl 10828 2016-09-19 08:33:20Z tiefland $ -->
-
 
3
		<script src="/backend/js/bildverwaltung.js"></script>
-
 
4
		<script>
-
 
5
			$(function(){
-
 
6
				$('.search').button({
-
 
7
					icons:{
-
 
8
						primary:"ui-icon-search"
-
 
9
					}
-
 
10
				})
-
 
11
				$('.edit_desc').button({
-
 
12
					icons:{
-
 
13
						primary:"ui-icon-pencil"
-
 
14
					}
-
 
15
				}).css("cursor","pointer").click(edit_medium_desc);
-
 
16
				$('.edit_type').button({
-
 
17
					icons:{
-
 
18
						primary:"ui-icon-pencil"
-
 
19
					}
-
 
20
				}).css("cursor","pointer").click(edit_medium_type);
-
 
21
				$('#edit_desc_dlg').dialog({
-
 
22
					autoOpen:false,
-
 
23
					modal:true,
-
 
24
					resizable:false,
-
 
25
					buttons:{
-
 
26
						"speichern": function()
-
 
27
						{
-
 
28
							url="/toolbox/editMedimDesc.php";
-
 
29
							$.get(url,$('#edit_desc_form').serialize(),function(html){
-
 
30
								$('#desc_'+$('#hidden_id').val()).html(html);
-
 
31
							})
-
 
32
							$('#edit_desc_dlg').dialog("close");
-
 
33
						},
-
 
34
						"abbrechen": function()
-
 
35
						{
-
 
36
							$('#edit_desc_dlg').dialog("close");
-
 
37
						}
-
 
38
					}
-
 
39
				});
-
 
40
				$('#edit_type_dlg').dialog({
-
 
41
					autoOpen:false,
-
 
42
					modal:true,
-
 
43
					resizable:false,
-
 
44
					buttons:{
-
 
45
						"speichern": function()
-
 
46
						{
-
 
47
							url="/toolbox/editMedimType.php";
-
 
48
							$.get(url,$('#edit_type_form').serialize(),function(html){
-
 
49
								$('#type_'+$('#hidden_id_type').val()).html(html);
-
 
50
							})
-
 
51
							$('#edit_type_dlg').dialog("close");
-
 
52
						},
-
 
53
						"abbrechen": function()
-
 
54
						{
-
 
55
							$('#edit_type_dlg').dialog("close");
-
 
56
						}
-
 
57
					}
-
 
58
				});
-
 
59
			});
-
 
60
		</script>
-
 
61
		{if isset($user_rechte.admin.toolbox.bildverwaltung)}
-
 
62
			<table>
-
 
63
				<tr>
-
 
64
					<td>
-
 
65
						<button class="add_image tb_bv_button" title="Bilder verwalten"></button>
-
 
66
						<button class="add_folder tb_bv_button" title="Neues Verzeichnis anlegen"></button>
-
 
67
					</td>
-
 
68
					<td>
-
 
69
						<form id="search_media">
-
 
70
							<input type="text" placeholder="Suche" value="{$search}" name="search" />
-
 
71
							<input type="hidden" name="folder" value="{$folder|urlencode}" />
-
 
72
							<button class="search tb_bv_button" title="Medien durchsuchen">&nbsp;</button>
-
 
73
						</form>
-
 
74
					</td>
-
 
75
				</tr>
-
 
76
			</table>
-
 
77
			<div class="break">&nbsp;</div>
-
 
78
			<div class="pos">
-
 
79
				<span class="aktuell">Position:</span> 
-
 
80
				{if $folder}
-
 
81
					<a class="nav" href="/backend/bildverwaltung/index/">TOP</a>
-
 
82
				{else}
-
 
83
					<span class="aktuell">TOP</span>
-
 
84
				{/if}
-
 
85
				{foreach $pos as $dir}
-
 
86
					{if $dir@first} > {/if}
-
 
87
					{if !$dir@last} 
-
 
88
						<a class="nav" href="/backend/bildverwaltung/index/?folder={$dir.fullName}">{$dir.name}</a> >
-
 
89
					{else}
-
 
90
						<span class="aktuell">
-
 
91
							{$dir.name} 
-
 
92
						</span>
-
 
93
					{/if}
-
 
94
				{/foreach}
-
 
95
			</div>
-
 
96
			{foreach $folders as $f_id => $f_name}
-
 
97
				{if $f_name@first}
-
 
98
					<div class="break">&nbsp;</div>
-
 
99
				{/if}
-
 
100
				<img src="/backend/images/Online-Shop/directory/ordner.gif" />
-
 
101
				<a href="/backend/bildverwaltung/index/?folder={$f_name|urlencode}" class="nav">{$f_name}</a>
-
 
102
				{if !$f_name@last}
-
 
103
					<br>
-
 
104
				{/if}
-
 
105
			{/foreach}
-
 
106
			<div class="break">&nbsp;</div>
-
 
107
			{include file="pagination.tpl"}
-
 
108
			<table cellpadding="0" cellpadding="0" border="1" width="100%">
-
 
109
				<tr class="links">
-
 
110
					<td>
-
 
111
						<a href="/backend/bildverwaltung/index/?sort=document&dir={$sort.document.dir}">ID</a>
-
 
112
					</td>
-
 
113
					<td>
-
 
114
						<a href="/backend/bildverwaltung/index/?sort=document&dir={$sort.document.dir}">Name</a>
-
 
115
					</td>
-
 
116
					<td>Beschreibung</td>
-
 
117
					<td>
-
 
118
						<a href="/backend/bildverwaltung/index/?sort=typ&dir={$sort.document.dir}">Typ des Mediums</a>
-
 
119
					</td>
-
 
120
					<td>
-
 
121
						<a href="/backend/bildverwaltung/index/?sort=erstellt_am&dir={$sort.erstellt_am.dir}">Datum</a>
-
 
122
					</td>
-
 
123
					<td>
-
 
124
						<a href="/backend/bildverwaltung/index/?sort=erstellt_am&dir={$sort.erstellt_am.dir}">Zeit</a>
-
 
125
					</td>
-
 
126
					<td>
-
 
127
						<a href="/backend/bildverwaltung/index/?sort=erstellt_von&dir={$sort.erstellt_von.dir}">Ersteller</a>
-
 
128
					</td>
-
 
129
					<td>Anzahl Verknüpfungen</td>
-
 
130
				</tr>
-
 
131
				{foreach $medien as $id => $medium}
-
 
132
				<tr class="rechts">
-
 
133
					<td>{$medium.id}</td>
-
 
134
					<td>{$medium.name}</td>
-
 
135
					<td style="width:200px;">
-
 
136
						<div>
-
 
137
							<div style="float:left;">
-
 
138
								<button id="edit_desc__{$medium.id}" class="edit_desc tb_bv_button" title="Beschreibung ändern"></button>
-
 
139
							</div>
-
 
140
							<div style="float:left;" id="desc_{$medium.id}">{$medium.beschreibung|default:"&nbsp;"}</div>
-
 
141
						</div>
-
 
142
					</td>
-
 
143
					<td>
-
 
144
						<div>
-
 
145
							<div style="float:left;">
-
 
146
								<button id="edit_type__{$medium.id}" class="edit_type tb_bv_button" title="Medientyp ändern"></button>
-
 
147
							</div>
-
 
148
							<div style="float:left;" id="type_{$medium.id}">{$medium.typ}</div>
-
 
149
						</div>
-
 
150
					</td>
-
 
151
					<td>{$medium.erstellt_am|date_format:"%x"}</td>
-
 
152
					<td>{$medium.erstellt_am|date_format:"%X"}</td>
-
 
153
					<td>{$medium.erstellt_von}</td>
-
 
154
					<td>{$medium.anz.artikel} Artikel<br>{$medium.anz.directory} Kategorien</td>
-
 
155
				</tr>
-
 
156
				{/foreach}
-
 
157
			</table>
-
 
158
			{include file="pagination.tpl"}
-
 
159
		
-
 
160
		{include file="upload.tpl"}
-
 
161
		
-
 
162
		{else}
-
 
163
			<div class="error">Sie haben nicht das Recht dieses Tool zu benutzen!</div>
-
 
164
		{/if}
-
 
165
		
-
 
166
		<div title="Beschreibung des Mediums anpassen" id="edit_desc_dlg">
-
 
167
			<form id="edit_desc_form">
-
 
168
				<input type="hidden" name="id" value="" id="hidden_id" />
-
 
169
				Beschreibung:
-
 
170
				<input type="text" name="beschreibung" value="" id="input_desc" />
-
 
171
			</form>
-
 
172
		</div>
-
 
173
		<div title="Type des Mediums anpassen" id="edit_type_dlg">
-
 
174
			<form id="edit_type_form">
-
 
175
				<input type="hidden" name="id" value="" id="hidden_id_type" />
-
 
176
				Typ:
-
 
177
				{html_options options=$typen name="typ"}
-
 
178
			</form>
-
 
179
		</div>
-
 
180
 {include file="footer.tpl"}
-
 
181
1
<style>
-
 
2
.tb_bv_button
-
 
3
{
-
 
4
  height: 22px;
-
 
5
  width: 30px;
-
 
6
}
-
 
7
</style>
-
 
8
<script>
-
 
9
    $('.aehnlich').change(change_aehnlich);
-
 
10
    $('.del_image').css("cursor","pointer").click(del_image);
-
 
11
    $('.pic_up').css("cursor","pointer").click(move_pic);
-
 
12
    $('.pic_down').css("cursor","pointer").click(move_pic);
-
 
13
    $('.edit_desc').button({
-
 
14
        icons:{
-
 
15
            primary:"ui-icon-pencil"
-
 
16
        }
-
 
17
    }).css("cursor","pointer").click(edit_medium_desc);
-
 
18
    $('#edit_desc_dlg').dialog({
-
 
19
        autoOpen:false,
-
 
20
        modal:true,
-
 
21
        resizable:false,
-
 
22
        buttons:{
-
 
23
            "speichern": function()
-
 
24
            {
-
 
25
                url="/toolbox/editMedimDesc.php";
-
 
26
                $.get(url,$('#edit_desc_form').serialize(),function(html){
-
 
27
                    $('#desc_'+$('#hidden_id').val()).html(html);
-
 
28
                })
-
 
29
                $(this).dialog("close");
-
 
30
            },
-
 
31
            "abbrechen": function()
-
 
32
            {
-
 
33
                $(this).dialog("close");
-
 
34
            }
-
 
35
        }
-
 
36
    });
-
 
37
    function change_aehnlich()
-
 
38
    {
-
 
39
        aId=$(this).attr("id").split("_");
-
 
40
        l_id=aId[1];
-
 
41
        m_id=aId[2];
-
 
42
        l_type=aId[3];
-
 
43
        val=$(this).val();
-
 
44
        url="change_aehnlich.php?l_id="+l_id+"&m_id="+m_id+"&val="+val+"&l_type="+l_type
-
 
45
        $.get(url,function(html)
-
 
46
        {
-
 
47
            if(html==1)
-
 
48
            {
-
 
49
                meld="&Auml;nderung erfolgreich gespeichert!";
-
 
50
            }
-
 
51
            else
-
 
52
            {
-
 
53
                meld="Es ist leider ein Fehler aufgetreten!<br>"+html;
-
 
54
            }
-
 
55
            $('#change_aehnlich_meld').html(meld);
-
 
56
            $('#change_aehnlich_msg').dialog({
-
 
57
                modal:true,
-
 
58
                resizable:false,
-
 
59
                buttons:{
-
 
60
                    "ok":function()
-
 
61
                    {
-
 
62
                        $(this).dialog("close");
-
 
63
                    }
-
 
64
                }
-
 
65
            })
-
 
66
        })
-
 
67
    }
-
 
68
</script>
-
 
69
<table width="100%">
-
 
70
    <tr class="links">
-
 
71
        <td>Dateiname</td>
-
 
72
        <td>Vorschau</td>
-
 
73
        <td>&auml;hnlich?</td>
-
 
74
        <td>Beschreibung</td>
-
 
75
        <td>Gr&ouml;&szlig;e</td>
-
 
76
        <td>Type</td>
-
 
77
        <td>Aktionen</td>
-
 
78
    </tr>
-
 
79
    {foreach $medien as $medium}
-
 
80
    <tr>
-
 
81
        <td id="bild_name_{$medium.id}">{$medium.name|utf8_decode}</td>
-
 
82
        <td>
-
 
83
            {if $medium.typ==1||$medium.typ==5||$medium.typ==6||$medium.typ==7}
-
 
84
            <a href="{$medium.url}" target="_blank"><img src="{$medium.url_mini}" /></a>
-
 
85
            {elseif $medium.typ==3}
-
 
86
            <a href="{$medium.name}" target="_blank">
-
 
87
                <img src="{$medium.url_mini}" width="153" />
-
 
88
            </a>
-
 
89
            {else}
-
 
90
            Dies ist kein Bild!<br/>Daher gibt es keine Vorschau!
-
 
91
            {/if}
-
 
92
        </td>
-
 
93
        <td>
-
 
94
            <select id="aehnlich_{$smarty.get.l_id}_{$medium.id}_{$smarty.get.l_type}" class="aehnlich">
-
 
95
            {html_options selected=$medium.aehnlich options=$aehnlich}
-
 
96
            </select>
-
 
97
        </td>
-
 
98
        <td style="width:200px;">
-
 
99
            <div>
-
 
100
                <div style="float:left;">
-
 
101
                    <a class="edit_desc tb_bv_button" id="edit_desc__{$medium.id}" title="Beschreibung editieren"></a>
-
 
102
                </div>
-
 
103
                <div style="float:left;" id="desc_{$medium.id}">{$medium.beschreibung|default:"&nbsp;"}</div>
-
 
104
            </div>
-
 
105
        </td>
-
 
106
        <td>
-
 
107
            {$medium.size|fsize_format}
-
 
108
            {if $medium.typ==1||$medium.typ==5||$medium.typ==6||$medium.typ==3}
-
 
109
            ({$medium.img_size[0]} x {$medium.img_size[1]} Pixel)
-
 
110
            {/if}
-
 
111
        </td>
-
 
112
        <td>
-
 
113
            {$medium.typ_name}
-
 
114
 
-
 
115
 
-
 
116
        </td>
-
 
117
        <td>
-
 
118
            <table>
-
 
119
                <tr>
-
 
120
                    <td width="16">
-
 
121
                        {if !$medium@first}
-
 
122
                        <a class="pic_up" title="nach oben" id="up_{$smarty.get.l_id}_{$medium.id}_{$smarty.get.l_type}"><img src="/images/Icons/up.png"></a>
-
 
123
                        {/if}
-
 
124
                    </td>
-
 
125
                    <td width="16">
-
 
126
                        {if !$medium@last}
-
 
127
                        <a class="pic_down" title="nach unten" id="down_{$smarty.get.l_id}_{$medium.id}_{$smarty.get.l_type}"><img src="/images/Icons/down.png"></a>
-
 
128
                        {/if}
-
 
129
                    </td>
-
 
130
                    <td width="16">
-
 
131
                        <a title="l&ouml;schen" class="del_image" id="del_image_{$medium.id}_{$smarty.post.l_id}"><img src="/images/Icons/trashcan.png"></a>
-
 
132
                    </td>
-
 
133
                </tr>
-
 
134
            </table>
-
 
135
        </td>
-
 
136
    </tr>
-
 
137
    {/foreach}
-
 
138
    <input type="hidden" id="l_type" value="{$smarty.get.l_type}" />
-
 
139
</table>
-
 
140
 
-
 
141
<div title="Beschreibung des Mediums anpassen" id="edit_desc_dlg">
-
 
142
    <form id="edit_desc_form">
-
 
143
        <input type="hidden" name="id" value="" id="hidden_id" />
-
 
144
        Beschreibung:
-
 
145
        <input type="text" name="beschreibung" value="" id="input_desc" />
-
 
146
    </form>
-
 
147
</div>
-
 
148
 
-
 
149
<div id="change_aehnlich_msg" title="Ergebnis">
-
 
150
    <div id="change_aehnlich_meld"></div>
-
 
151
</div>
-
 
152