Activate Wake on LAN (for CS) again (ybug 455)

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@418 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
yjogol
2010-02-26 05:59:54 +00:00
parent f4f390e550
commit 28dd71ff97
4 changed files with 11 additions and 6 deletions

View File

@@ -41,7 +41,7 @@ function goto_settings(){
<td>Wake on Lan MAC 3 ({=ini-get:/var/tuxbox/config/Y-Web.conf;wol_mac_3=}) {=ini-get:/var/tuxbox/config/Y-Web.conf;wol_desc_3=}</td>
<td><input id="wol3" type="button" name="wol_mac_3" value="wake up" title="wake up that MAC" onclick='do_wol(3)'/></td>
</tr>
<tr><td colspan="2"><a href="javascript:goto_settings()" class="inlink">Einstellungen</a></td></tr>
<tr><td colspan="2"><a href="javascript:goto_settings()" class="inlink">{=L:settings=}</a></td></tr>
</table>
</form>
<!--<a href="Y_Settings_yWeb.yhtm" title="WOL Settings">Einstellungen</a>-->

View File

@@ -99,7 +99,7 @@ function do_check(){
~
sLog_addRow(sLog_body, "green", "Programs: fcp is installed at: {=var-get:fcp=}. Image flashing is enabled.", "ok");
=}
{=var-set:etherwake={=if-file-exists:/bin/etherwake~/bin/etherwake~{=if-file-exists:/var/bin/etherwake~/var/bin/etherwake~false=}=}=}
{=var-set:etherwake={=if-equal:{=global-var-get:boxtype=}~coolstream~{=if-file-exists:/bin/ether-wake~/bin/ether-wake~{=if-file-exists:/var/bin/ether-wake~/var/bin/ether-wake~=}=}~{=if-file-exists:/bin/etherwake~/bin/etherwake~{=if-file-exists:/var/bin/etherwake~/var/bin/etherwake~=}=}=}=}
{=if-equal:{=var-get:etherwake=}~false~
sLog_addRow(sLog_body, "red", "Programs: etherwake is not installed. Wake on LAN is disabled. "+y_url("Help-Tools-Wake_on_LAN"), "failed");
~

View File

@@ -32,8 +32,7 @@ function init(){
</head>
{=var-set:automount={=if-file-exists:/sbin/automount~true~{=if-file-exists:/var/bin/automount~true~=}=}=}
{=var-set:management={=if-equal:{=func:get_request_data client_addr=}~{=ini-get:/var/tuxbox/config/Y-Web.conf;management_ip;{=func:get_request_data client_addr=}=}~1~=}{=if-equal:{=func:get_request_data client_addr=}~{=ini-get:/var/tuxbox/config/Y-Web.conf;management_ip2=}~1~=}=}
{=var-set:etherwake={=if-file-exists:/bin/etherwake~/bin/etherwake~{=if-file-exists:/var/bin/etherwake~/var/bin/etherwake~=}=}=}
{=var-set:etherwake={=if-equal:{=global-var-get:boxtype=}~coolstream~{=if-file-exists:/bin/ether-wake~/bin/ether-wake~{=if-file-exists:/var/bin/ether-wake~/var/bin/ether-wake~=}=}~{=if-file-exists:/bin/etherwake~/bin/etherwake~{=if-file-exists:/var/bin/etherwake~/var/bin/etherwake~=}=}=}=}
<body onload="init()">
<div class="y_menu_sec_box">
<div class="y_menu_sec_box_head"><h2>Tools</h2></div>
@@ -55,12 +54,12 @@ function init(){
<li><a target="work" title="organize file automounts" href="Y_Settings_automount_liste.yhtm">AutoMounts</a></li>
=}
<li><a target="work" title="organize file mounts" href="Y_Settings_mount_liste.yhtm">Mounts</a></li>
~=}
{=if-empty:{=var-get:etherwake=}~
<li class="disabled" title="Wake on LAN (etherwake not installed)" >Wake on LAN</li>
~
<li><a target="work" title="Wake on LAN" href="Y_Settings_wol.yhtm">Wake on LAN</a></li>
=}
~=}
=}
<li><a target="work" title="check Installation" href="Y_Tools_Check_Install.yhtm">Check Install</a></li>
</ul>

View File

@@ -436,7 +436,13 @@ proc()
# -----------------------------------------------------------
wol()
{
msg=`etherwake $1`
if [ -e /bin/etherwake ]; then
msg=`etherwake $1`
else
if [ -e /bin/ether-wake ]; then
msg=`ether-wake $1`
fi
fi
msg="<b>Wake on LAN $1</b><br><br>$msg"
y_format_message_html
}