webapp: Code cleanup
This commit is contained in:
parent
fbedd75e0e
commit
0c7078febd
@ -14,9 +14,9 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import WifiStationInfo from "./partials/WifiStationInfo.vue";
|
import WifiStationInfo from "./partials/WifiStationInfo.vue";
|
||||||
import WifiApInfo from "./partials/WifiApInfo.vue"
|
import WifiApInfo from "./partials/WifiApInfo.vue";
|
||||||
import InterfaceStationInfo from "./partials/InterfaceStationInfo.vue"
|
import InterfaceStationInfo from "./partials/InterfaceStationInfo.vue";
|
||||||
import InterfaceApInfo from "./partials/InterfaceApInfo.vue"
|
import InterfaceApInfo from "./partials/InterfaceApInfo.vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@ -5,8 +5,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
<table id="wifi_sta" class="table table-hover table-condensed">
|
<table class="table table-hover table-condensed">
|
||||||
<tbody id="wifi_sta-data">
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th>IP Address</th>
|
<th>IP Address</th>
|
||||||
<td>{{ networkDataList.ap_ip }}</td>
|
<td>{{ networkDataList.ap_ip }}</td>
|
||||||
@ -38,19 +38,6 @@ export default {
|
|||||||
.then((response) => response.json())
|
.then((response) => response.json())
|
||||||
.then((data) => (this.networkDataList = data));
|
.then((data) => (this.networkDataList = data));
|
||||||
},
|
},
|
||||||
getRSSIasQuality(rssi) {
|
|
||||||
var quality = 0;
|
|
||||||
|
|
||||||
if (rssi <= -100) {
|
|
||||||
quality = 0;
|
|
||||||
} else if (rssi >= -50) {
|
|
||||||
quality = 100;
|
|
||||||
} else {
|
|
||||||
quality = 2 * (rssi + 100);
|
|
||||||
}
|
|
||||||
|
|
||||||
return quality;
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -5,8 +5,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
<table id="wifi_sta" class="table table-hover table-condensed">
|
<table class="table table-hover table-condensed">
|
||||||
<tbody id="wifi_sta-data">
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th>IP Address</th>
|
<th>IP Address</th>
|
||||||
<td>{{ networkDataList.sta_ip }}</td>
|
<td>{{ networkDataList.sta_ip }}</td>
|
||||||
@ -54,19 +54,6 @@ export default {
|
|||||||
.then((response) => response.json())
|
.then((response) => response.json())
|
||||||
.then((data) => (this.networkDataList = data));
|
.then((data) => (this.networkDataList = data));
|
||||||
},
|
},
|
||||||
getRSSIasQuality(rssi) {
|
|
||||||
var quality = 0;
|
|
||||||
|
|
||||||
if (rssi <= -100) {
|
|
||||||
quality = 0;
|
|
||||||
} else if (rssi >= -50) {
|
|
||||||
quality = 100;
|
|
||||||
} else {
|
|
||||||
quality = 2 * (rssi + 100);
|
|
||||||
}
|
|
||||||
|
|
||||||
return quality;
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -5,8 +5,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
<table id="wifi_sta" class="table table-hover table-condensed">
|
<table class="table table-hover table-condensed">
|
||||||
<tbody id="wifi_sta-data">
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Status</th>
|
<th>Status</th>
|
||||||
<td
|
<td
|
||||||
@ -51,19 +51,6 @@ export default {
|
|||||||
.then((response) => response.json())
|
.then((response) => response.json())
|
||||||
.then((data) => (this.networkDataList = data));
|
.then((data) => (this.networkDataList = data));
|
||||||
},
|
},
|
||||||
getRSSIasQuality(rssi) {
|
|
||||||
var quality = 0;
|
|
||||||
|
|
||||||
if (rssi <= -100) {
|
|
||||||
quality = 0;
|
|
||||||
} else if (rssi >= -50) {
|
|
||||||
quality = 100;
|
|
||||||
} else {
|
|
||||||
quality = 2 * (rssi + 100);
|
|
||||||
}
|
|
||||||
|
|
||||||
return quality;
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -5,8 +5,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="table-responsive">
|
<div class="table-responsive">
|
||||||
<table id="wifi_sta" class="table table-hover table-condensed">
|
<table class="table table-hover table-condensed">
|
||||||
<tbody id="wifi_sta-data">
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Status</th>
|
<th>Status</th>
|
||||||
<td
|
<td
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user