forked from hummypkg/webif
allow restart cancel, improve logfile list
git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@629 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
parent
75b31696c5
commit
c2ec779465
@ -8,6 +8,12 @@ puts "Content-Type: text/html"
|
|||||||
puts ""
|
puts ""
|
||||||
|
|
||||||
cgi_input
|
cgi_input
|
||||||
|
|
||||||
|
if {[cgi_get act] eq "cancel"} {
|
||||||
|
file delete /tmp/.restartpending
|
||||||
|
exit
|
||||||
|
}
|
||||||
|
|
||||||
if {[cgi_get now] eq "yes"} {
|
if {[cgi_get now] eq "yes"} {
|
||||||
# - Busybox reboot does sync the disk but may still not be clean enough.
|
# - Busybox reboot does sync the disk but may still not be clean enough.
|
||||||
puts "Restarting."
|
puts "Restarting."
|
||||||
|
@ -4,7 +4,7 @@ source /mod/var/mongoose/lib/setup
|
|||||||
require pretty_size
|
require pretty_size
|
||||||
|
|
||||||
foreach file [concat \
|
foreach file [concat \
|
||||||
[glob -nocomplain /tmp/*.log] \
|
[glob -nocomplain /var/log/*.log] \
|
||||||
[glob -nocomplain /mod/tmp/*.log] \
|
[glob -nocomplain /mod/tmp/*.log] \
|
||||||
] {
|
] {
|
||||||
puts "<a href=# class=log file=\"$file\">
|
puts "<a href=# class=log file=\"$file\">
|
||||||
|
@ -25,17 +25,23 @@ if {[system busy]} {
|
|||||||
}
|
}
|
||||||
|
|
||||||
puts {
|
puts {
|
||||||
|
<small><button id=restart_cancel>Hide</button></small>
|
||||||
</font>
|
</font>
|
||||||
</div>
|
</div>
|
||||||
<div style="width: 60%; height: 0.7em; margin-bottom: 2em;
|
<div style="width: 60%; height: 0.7em; margin-bottom: 2em;
|
||||||
background: url(/img/stripes.gif) repeat-x;"></div>
|
background: url(/img/stripes.gif) repeat-x;"></div>
|
||||||
</center>
|
</center>
|
||||||
<script type=text/javascript>
|
<script type=text/javascript>
|
||||||
$('#restart_humaxtv').button();
|
$('#restart_humaxtv').button()
|
||||||
$('#restart_humaxtv').click(function() {
|
.click(function() {
|
||||||
if (confirm('Are you sure you wish to perform a restart now?'))
|
if (confirm('Are you sure you wish to perform a restart now?'))
|
||||||
window.location = '/cgi-bin/restart.jim';
|
window.location = '/cgi-bin/restart.jim';
|
||||||
});
|
});
|
||||||
|
$('#restart_cancel').button()
|
||||||
|
.click(function() {
|
||||||
|
$.get('/cgi-bin/restart.jim?act=cancel');
|
||||||
|
$('#restart_block').slideUp('slow');
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user