Skip to content

Commit 8b380dc

Browse files
committed
Add WiFi info to client detail
1 parent 2dee80e commit 8b380dc

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

views/wifi_tab.php

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,25 @@
7171
rows = rows + '<tr><th>'+i18n.t('wifi.'+prop)+'</th><td>'+i18n.t('wifi.station')+'</td></tr>';
7272
}
7373
74+
else if (prop == 'ssid' || prop == 'bssid') {
75+
rows = rows + '<tr><th>'+i18n.t('wifi.'+prop)+'</th><td>'+d[prop]+'</td></tr>';
76+
77+
// Add the Wi-Fi network name to the client detail if Wi-Fi is the active primary service
78+
if ($('.machine-hostname').parent().parent().parent().text().includes("Wi-Fi")) {
79+
80+
if (prop == 'bssid'){
81+
d[prop] = d[prop].toUpperCase()
82+
}
83+
84+
$('.machine-hostname').parent().parent().parent()
85+
.append($('<tr>')
86+
.append($('<th>')
87+
.append('Wi-Fi '+i18n.t('wifi.'+prop)))
88+
.append($('<td>')
89+
.append(d[prop])))
90+
}
91+
}
92+
7493
else {
7594
rows = rows + '<tr><th style="width: 200px;">'+i18n.t('wifi.'+prop)+'</th><td style="max-width: 500px;">'+d[prop]+'</td></tr>';
7695
}

0 commit comments

Comments
 (0)