mirror of
https://github.com/henrywhitaker3/Speedtest-Tracker.git
synced 2025-12-21 13:23:04 +01:00
Fixed min setting bug
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
# Speedtest Tracker
|
# Speedtest Tracker
|
||||||
|
|
||||||
[](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [](https://github.com/henrywhitaker3/Speedtest-Tracker/commits)  [](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE)
|
[](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [](https://github.com/henrywhitaker3/Speedtest-Tracker/commits)  [](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE)
|
||||||
|
|
||||||
This program runs a speedtest check every hour and graphs the results. The back-end is written in [Laravel](https://laravel.com/) and the front-end uses [React](https://reactjs.org/). It uses the [Ookla's speedtest cli](https://www.speedtest.net/apps/cli) package to get the data and uses [Chart.js](https://www.chartjs.org/) to plot the results.
|
This program runs a speedtest check every hour and graphs the results. The back-end is written in [Laravel](https://laravel.com/) and the front-end uses [React](https://reactjs.org/). It uses the [Ookla's speedtest cli](https://www.speedtest.net/apps/cli) package to get the data and uses [Chart.js](https://www.chartjs.org/) to plot the results.
|
||||||
|
|
||||||
|
|||||||
@@ -144,7 +144,7 @@ class SpeedtestController extends Controller
|
|||||||
$response['maximum'] = $max;
|
$response['maximum'] = $max;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (SettingsHelper::get('show_average')) {
|
if (SettingsHelper::get('show_min')) {
|
||||||
$min = Speedtest::select(DB::raw('MIN(ping) as ping, MIN(download) as download, MIN(upload) as upload'))
|
$min = Speedtest::select(DB::raw('MIN(ping) as ping, MIN(download) as download, MIN(upload) as upload'))
|
||||||
->where('failed', false)
|
->where('failed', false)
|
||||||
->first()
|
->first()
|
||||||
|
|||||||
@@ -1,4 +1,10 @@
|
|||||||
{
|
{
|
||||||
|
"1.9.8": [
|
||||||
|
{
|
||||||
|
"description": "Fixed bug with minimum display setting.",
|
||||||
|
"link": ""
|
||||||
|
}
|
||||||
|
],
|
||||||
"1.9.7": [
|
"1.9.7": [
|
||||||
{
|
{
|
||||||
"description": "Added option to display minimum values on the top widgets.",
|
"description": "Added option to display minimum values on the top widgets.",
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ return [
|
|||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
'version' => '1.9.7',
|
'version' => '1.9.8',
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
|
|||||||
2
public/js/app.js
vendored
2
public/js/app.js
vendored
File diff suppressed because one or more lines are too long
6
resources/js/components/Graphics/Widget.js
vendored
6
resources/js/components/Graphics/Widget.js
vendored
@@ -30,7 +30,7 @@ export default class Widget extends Component {
|
|||||||
returnData.max = parseFloat(data.maximum.ping).toFixed(1);
|
returnData.max = parseFloat(data.maximum.ping).toFixed(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(window.config.widgets.show_max) {
|
if(window.config.widgets.show_min) {
|
||||||
returnData.min = parseFloat(data.minimum.ping).toFixed(1);
|
returnData.min = parseFloat(data.minimum.ping).toFixed(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -46,7 +46,7 @@ export default class Widget extends Component {
|
|||||||
returnData.max = parseFloat(data.maximum.upload).toFixed(1);
|
returnData.max = parseFloat(data.maximum.upload).toFixed(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(window.config.widgets.show_max) {
|
if(window.config.widgets.show_min) {
|
||||||
returnData.min = parseFloat(data.minimum.upload).toFixed(1);
|
returnData.min = parseFloat(data.minimum.upload).toFixed(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -62,7 +62,7 @@ export default class Widget extends Component {
|
|||||||
returnData.max = parseFloat(data.maximum.download).toFixed(1);
|
returnData.max = parseFloat(data.maximum.download).toFixed(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(window.config.widgets.show_max) {
|
if(window.config.widgets.show_min) {
|
||||||
returnData.min = parseFloat(data.minimum.download).toFixed(1);
|
returnData.min = parseFloat(data.minimum.download).toFixed(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user