modules/admin-full: rework wifi status templates
authorJo-Philipp Wich <jow@openwrt.org>
Thu, 20 Jan 2011 23:27:48 +0000 (23:27 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Thu, 20 Jan 2011 23:27:48 +0000 (23:27 +0000)
modules/admin-full/luasrc/view/admin_network/wifi_join.htm
modules/admin-full/luasrc/view/admin_network/wifi_overview.htm
modules/admin-full/luasrc/view/admin_network/wifi_status.htm

index 4dea9bacc83b7b96252748baf7b926345d669f5b..a1959a4ee211227d3c6699544688a63dcb209376 100644 (file)
@@ -114,7 +114,7 @@ $Id$
 
                                                <input type="hidden" name="clbridge" value="<%=iw.type == "wl" and 1 or 0%>" />
 
-                                               <input class="cbi-button-apply" type="submit" value="<%:Join Network%>" />
+                                               <input class="cbi-button-apply" type="submit" value="Join Network" />
                                        </form>
                                </td>
                        </tr>
index 615e766074e34b5afc49cffd7496b1205ab20e89..29de11cabc78aab0fee5a0c0a088f63c93492157 100644 (file)
@@ -167,7 +167,7 @@ $Id$
                                                {
                                                        if (is_assoc)
                                                                info.innerHTML = String.format(
-                                                                       '<strong><%:SSID%>:</strong> %s | ' +
+                                                                       '<strong><%:SSID%>:</strong> %h | ' +
                                                                        '<strong><%:Mode%>:</strong> %s<br />' +
                                                                        '<strong><%:BSSID%>:</strong> %s | ' +
                                                                        '<strong><%:Encryption%>:</strong> %s',
@@ -175,7 +175,12 @@ $Id$
                                                                                iw.encryption ? iw.encryption.description : '<%:None%>'
                                                                );
                                                        else
-                                                               info.innerHTML = '<em><%:Wireless is disabled or not associated%></em>';
+                                                               info.innerHTML = String.format(
+                                                                       '<strong><%:SSID%>:</strong> %h | ' +
+                                                                       '<strong><%:Mode%>:</strong> %s<br />' +
+                                                                       '<em><%:Wireless is disabled or not associated%></em>',
+                                                                               iw.ssid || '?', iw.mode
+                                                               );
                                                }
 
                                                var dev = document.getElementById(wifidevs[iw.id] + '-iw-devinfo');
index 01a49c43eb222c7a6a044c4c2f05ee80f41493ef..ba99acf199a976a725cae8b2b4263dc0845b7c8a 100644 (file)
@@ -37,7 +37,7 @@
                                        if (d && is_assoc)
                                                d.innerHTML = String.format(
                                                        '<strong><%:Mode%>:</strong> %s | ' +
-                                                       '<strong><%:SSID%>:</strong> %s<br />' +
+                                                       '<strong><%:SSID%>:</strong> %h<br />' +
                                                        '<strong><%:BSSID%>:</strong> %s | ' +
                                                        '<strong><%:Encryption%>:</strong> %s<br />' +
                                                        '<strong><%:Channel%>:</strong> %d (%.3f GHz) | ' +
                                                                iw.bitrate ? (iw.bitrate / 1000) : 0, iw.country
                                                );
                                        else if (d)
-                                               d.innerHTML = '<%:Wireless is disabled or not associated%>';
+                                               d.innerHTML = String.format(
+                                                       '<strong><%:SSID%>:</strong> %h | ' +
+                                                       '<strong><%:Mode%>:</strong> %s<br />' +
+                                                       '<em><%:Wireless is disabled or not associated%></em>',
+                                                               iw.ssid || '?', iw.mode
+                                               );
                                }
 
                                window.setTimeout(update_status, 5000);