From a212b1506839fd1491b3257e29aa4ed1ec19655a Mon Sep 17 00:00:00 2001 From: drkthunder02 Date: Mon, 8 Jul 2019 22:09:33 -0500 Subject: [PATCH] fuel gauage modification --- app/Charts/StructureFuelGauge.php | 21 ++++++++++ .../Controllers/Logistics/FuelController.php | 13 ++++-- config/app.php | 2 + config/charts.php | 15 +++++++ .../logistics/display/fuelgauge.blade.php | 4 +- resources/views/logistics/layout/b4.blade.php | 41 +++++++++++++++++++ 6 files changed, 91 insertions(+), 5 deletions(-) create mode 100644 app/Charts/StructureFuelGauge.php create mode 100644 config/charts.php create mode 100644 resources/views/logistics/layout/b4.blade.php diff --git a/app/Charts/StructureFuelGauge.php b/app/Charts/StructureFuelGauge.php new file mode 100644 index 000000000..e525218c0 --- /dev/null +++ b/app/Charts/StructureFuelGauge.php @@ -0,0 +1,21 @@ + $id])->first(); @@ -71,12 +73,15 @@ class FuelController extends Controller ->addRow(['Liquid Ozone', $liquidOzone]); $lava->GaugeChart('Liquid Ozone', $gauge, [ 'width' => 400, - 'redFrom' => 0, - 'redTo' => 75000, + 'greenFrom' => 0, + 'greenTo' => 75000, + 'greenColor' => '#DC3912', 'yellowFrom' => 75000, 'yellowTo' => 150000, - 'greenFrom' => 150000, - 'greenTo' => 1000000, + 'yellowColor' => '#FF9900', + 'redFrom' => 150000, + 'redTo' => 1000000, + 'redColor' => '#109618', 'majorTicks' => [ 'Empty', 'Ok', diff --git a/config/app.php b/config/app.php index 454dc03ef..6de212f42 100644 --- a/config/app.php +++ b/config/app.php @@ -154,6 +154,7 @@ return [ //nullx27\Socialite\EveOnline\Providers\EveOnlineServiceProvider::class, Laravel\Socialite\SocialiteServiceProvider::class, Khill\Lavacharts\Laravel\LavachartsServiceProvider::class, + ConsoleTVs\Charts\ChartsServiceProvider::class, /* @@ -218,6 +219,7 @@ return [ 'Html' => Collective\Html\HtmlFacade::class, 'Socialite' => Laravel\Socialite\Facades\Socialite::class, 'Lava' => Khill\Lavacharts\Laravel\LavachartsFacade::class, + 'Charts' => ConsoleTVs\Charts\Charts::class, ], ]; diff --git a/config/charts.php b/config/charts.php new file mode 100644 index 000000000..b1a19c4e5 --- /dev/null +++ b/config/charts.php @@ -0,0 +1,15 @@ + 'Chartjs', +]; diff --git a/resources/views/logistics/display/fuelgauge.blade.php b/resources/views/logistics/display/fuelgauge.blade.php index 60f539b5b..b979ea651 100644 --- a/resources/views/logistics/display/fuelgauge.blade.php +++ b/resources/views/logistics/display/fuelgauge.blade.php @@ -1,5 +1,6 @@ -@extends('layouts.b4') +@extends('logistics.layouts.b4') @section('content') +
@@ -11,4 +12,5 @@
+
@endsection \ No newline at end of file diff --git a/resources/views/logistics/layout/b4.blade.php b/resources/views/logistics/layout/b4.blade.php new file mode 100644 index 000000000..008bd9897 --- /dev/null +++ b/resources/views/logistics/layout/b4.blade.php @@ -0,0 +1,41 @@ + + + + + + + + {{ config('app.name', 'W4RP Services') }} + + + + + + + + + + + + + @include('layouts.navbar') +
+ @include('inc.messages') +
+ @yield('content') + + + + + + + + \ No newline at end of file