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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
{{#systems}}
<div class="panel panel-default">
<div class="panel-heading">
<h4>{{title}}</h4>
</div>
<div class="panel-body" id="download-{{id}}">
<div class="input-group pull-right" style="max-width: 400px">
<span class="input-group-addon slx-ga">{{lang_desiredVersion}}</span>
<select id="versionbox" class="form-control" onchange="loadSystemList($('#versionbox').val())">
{{#versions}}
{{#selected}}
<option value="{{version}}" selected>{{version}}</option>
{{/selected}}
{{^selected}}
<option value="{{version}}">{{version}}</option>
{{/selected}}
{{/versions}}
</select>
</div>
{{#systemChanged}}
<p>
{{lang_canUpdate1}} <b>{{title}}</b> {{lang_canUpdate2}}
</p>
<p><span class="btn btn-primary" onclick="slxUpdateAll(this, 'download-{{id}}')">{{lang_update}}</span></p>
{{/systemChanged}}
{{^systemChanged}}
<p>{{lang_systemUpdated}}</p>
{{/systemChanged}}
<hr>
<p><b>{{lang_filesInVersion}} {{version}}</b></p>
<ul class="list-group">
{{#files}}
<li class="list-group-item" id="{{uid}}">
<div class="row">
<div class="col-sm-2">{{name}}</div>
<div class="col-xs-2">
{{^fileChanged}}<span class="glyphicon glyphicon-ok"></span> <b>{{lang_actual}}</b>{{/fileChanged}}
{{#fileChanged}}<span class="glyphicon glyphicon-exclamation-sign"></span> <b>{{lang_outdated}}</b>{{/fileChanged}}
</div>
<div class="col-xs-2">
{{#fileChanged}}<span class="btn btn-primary btn-xs update-button" onclick="slxUpdate('{{uid}}', '{{id}}', '{{name}}')">{{lang_update}}</span>{{/fileChanged}}
{{^fileChanged}}<span class="btn btn-default btn-xs" onclick="slxUpdate('{{uid}}', '{{id}}', '{{name}}')">{{lang_redownload}}</span>{{/fileChanged}}
</div>
</div>
{{{download}}}
</li>
{{/files}}
</ul>
</div>
</div>
{{/systems}}
{{^systems}}
<div class="row well well-sm">{{lang_configurationPackageNotFound}}</div>
{{/systems}}
<script type="text/javascript">
function slxUpdate(uid, id, name)
{
$('#' + uid).html('');
$('#' + uid).load('?do=MiniLinux',
{ action : "download", token : TOKEN, id : id, name : name, version : $('#versionbox').val() },
function(response, status, xhr) {
if (status === "error") {
var msg = "Fehler beim Abruf: ";
$('#' + uid).html(msg + xhr.status + " " + xhr.statusText);
} else {
setTimeout(tmInit, 100);
}
});
}
function slxUpdateAll(t, uid)
{
$(t).hide(0);
$('#' + uid).find('.update-button').click();
}
tmInit();
</script>
|