From 4026fe914960699bb043693251131ef63a2fec49 Mon Sep 17 00:00:00 2001 From: Andrew Roberts Date: Sun, 3 Jan 2021 12:39:02 +0000 Subject: [PATCH 01/16] Fix location of configservice (#977) Pointing to wrong location of file which is throwing errors as a result --- app/Console/Commands/DevInstall.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Console/Commands/DevInstall.php b/app/Console/Commands/DevInstall.php index ad19570b..39b34e48 100644 --- a/app/Console/Commands/DevInstall.php +++ b/app/Console/Commands/DevInstall.php @@ -3,7 +3,7 @@ namespace App\Console\Commands; use App\Contracts\Command; -use Modules\Installer\Services\ConfigService; +use App\Services\Installer\ConfigService; /** * Create a fresh development install From a037597a21503d7043c901a1381aed64e6fcf675 Mon Sep 17 00:00:00 2001 From: "B.Fatih KOZ" <74361521+FatihKoz@users.noreply.github.com> Date: Sun, 3 Jan 2021 16:05:48 +0300 Subject: [PATCH 02/16] Airline > Subfleet Relationship (#970) --- app/Models/Airline.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/Models/Airline.php b/app/Models/Airline.php index 1f95855a..994a79b5 100644 --- a/app/Models/Airline.php +++ b/app/Models/Airline.php @@ -97,6 +97,11 @@ class Airline extends Model $this->attributes['icao'] = strtoupper($icao); } + public function subfleets() + { + return $this->hasMany(Subfleet::class, 'airline_id'); + } + public function flights() { return $this->belongsTo(Flight::class, 'airline_id'); From 319a9fc8e1dcda0a55576a0dac4e9dc3dfed4a2f Mon Sep 17 00:00:00 2001 From: "B.Fatih KOZ" <74361521+FatihKoz@users.noreply.github.com> Date: Thu, 7 Jan 2021 17:09:05 +0300 Subject: [PATCH 03/16] Weather widget additions/fixes (#981) Fixed the problem where values are not displayed when the reported wind,temp and dewpoint are 0 (zero). Fixed the hPa number formatting, there is no need to add 2 more digits to it, it is a plain 4 digit value always (like 1013 or 1024, it is never reported nor used as 1013,58 or 1024,35 etc). Corrected the display order, as it should be read (or say decoded). Also added decoded Current and Recent Weather Situations, RVR and Runway Condition reports. RVR report needs improvement in the Support / Metar.php too, it only reports nmi as the distance as far as i saw but it should be able to report meters too. --- .../layouts/default/widgets/weather.blade.php | 114 ++++++++++-------- 1 file changed, 65 insertions(+), 49 deletions(-) diff --git a/resources/views/layouts/default/widgets/weather.blade.php b/resources/views/layouts/default/widgets/weather.blade.php index 92ee46f8..3ee2abdc 100644 --- a/resources/views/layouts/default/widgets/weather.blade.php +++ b/resources/views/layouts/default/widgets/weather.blade.php @@ -10,71 +10,87 @@ https://api.checkwx.com/#metar-decoded - + - - - - - @if($metar['clouds']) - - - - - @endif + @if($metar['visibility']) - - + + + @endif + @if($metar['runways_visual_range']) + + + + + @endif + @if($metar['present_weather_report'] <> 'Dry') + + + + + @endif + @if($metar['clouds'] || $metar['cavok']) + + + + + @endif + + + + + + + + + @if($metar['recent_weather_report']) + + + + + @endif + @if($metar['runways_report']) + + + + + @endif @if($metar['remarks']) - + @endif + + + +
@lang('widgets.weather.conditions') - {{ $metar['category'] }} - {{ $metar['temperature'][$unit_temp] }} - °{{strtoupper($unit_temp)}} - @if($metar['visibility']) - , @lang('widgets.weather.visibility') {{ $metar['visibility'][$unit_dist] }} {{$unit_dist}} - @endif - @if($metar['humidity']) - , {{ $metar['humidity'] }}% @lang('widgets.weather.humidity') - @endif - @if($metar['dew_point']) - , @lang('widgets.weather.dewpoint') - {{ $metar['dew_point'][$unit_temp] }} - °{{strtoupper($unit_temp)}} - @endif - {{ $metar['category'] }}
@lang('widgets.weather.barometer') - {{ number_format($metar['barometer']['hPa'], 2) }} hPa - / {{ number_format($metar['barometer']['inHg'], 2) }} inHg -
@lang('widgets.weather.clouds') - @if($unit_alt === 'ft') - {{$metar['clouds_report_ft']}} - @else - {{ $metar['clouds_report'] }} - @endif -
@lang('widgets.weather.wind') - {{$metar['wind_speed']}} kts @lang('common.from') {{$metar['wind_direction_label']}} - ({{$metar['wind_direction']}}°) - @if($metar['wind_gust_speed']) - @lang('widgets.weather.guststo') {{ $metar['wind_gust_speed'] }} - @endif + @if($metar['wind_speed'] < '1') Calm @else {{ $metar['wind_speed'] }} kts @lang('common.from') {{ $metar['wind_direction_label'] }} ({{ $metar['wind_direction']}}°) @endif + @if($metar['wind_gust_speed']) @lang('widgets.weather.guststo') {{ $metar['wind_gust_speed'] }} @endif
@lang('common.metar') -
- {{ $metar['raw'] }} -
-
Visibility{{ $metar['visibility'][$unit_dist] }} {{$unit_dist}}
Runway Visual Range + @foreach($metar['runways_visual_range'] as $rvr) + RWY{{ $rvr['runway'] }}; {{ $rvr['report'] }}
+ @endforeach +
Phenomena{{ $metar['present_weather_report'] }}
@lang('widgets.weather.clouds') + @if($unit_alt === 'ft') {{ $metar['clouds_report_ft'] }} @else {{ $metar['clouds_report'] }} @endif + @if($metar['cavok'] == 1) Ceiling and Visibility OK @endif +
Temperature + @if($metar['temperature'][$unit_temp]) {{ $metar['temperature'][$unit_temp] }} @else 0 @endif °{{strtoupper($unit_temp)}} + @if($metar['dew_point']), @lang('widgets.weather.dewpoint') @if($metar['dew_point'][$unit_temp]) {{ $metar['dew_point'][$unit_temp] }} @else 0 @endif °{{strtoupper($unit_temp)}} @endif + @if($metar['humidity']), @lang('widgets.weather.humidity') {{ $metar['humidity'] }}% @endif +
@lang('widgets.weather.barometer'){{ number_format($metar['barometer']['hPa']) }} hPa / {{ number_format($metar['barometer']['inHg'], 2) }} inHg
Recent Phenomena{{ $metar['recent_weather_report'] }}
Runway Condition + @foreach($metar['runways_report'] as $runway) + RWY{{ $runway['runway'] }}; {{ $runway['report'] }}
+ @endforeach +
@lang('widgets.weather.remarks') - {{ $metar['remarks'] }} - {{ $metar['remarks'] }}
@lang('widgets.weather.updated') {{$metar['observed_time']}} ({{$metar['observed_age']}})
@lang('common.metar'){{ $metar['raw'] }}
@endif From 2b0056b7c5caa3167ec564fa551ad314441a4519 Mon Sep 17 00:00:00 2001 From: "B.Fatih KOZ" <74361521+FatihKoz@users.noreply.github.com> Date: Tue, 12 Jan 2021 16:24:50 +0300 Subject: [PATCH 04/16] Added the ability to enable/disable flight table display below the map (#983) * LiveMap Widget Upgrade Added the ability to enable/disable flight table display below the map. Default is on * Update LiveMap.php * Update LiveMap.php * Update live_map.blade.php --- app/Widgets/LiveMap.php | 1 + resources/views/layouts/default/widgets/live_map.blade.php | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/Widgets/LiveMap.php b/app/Widgets/LiveMap.php index 514c6a8e..dcfaf780 100644 --- a/app/Widgets/LiveMap.php +++ b/app/Widgets/LiveMap.php @@ -14,6 +14,7 @@ class LiveMap extends Widget protected $config = [ 'height' => '800px', 'width' => '100%', + 'table' => true, ]; /** diff --git a/resources/views/layouts/default/widgets/live_map.blade.php b/resources/views/layouts/default/widgets/live_map.blade.php index 2a54ba83..35f08f0e 100644 --- a/resources/views/layouts/default/widgets/live_map.blade.php +++ b/resources/views/layouts/default/widgets/live_map.blade.php @@ -64,6 +64,7 @@ +@if($config['table'] === true)
{{-- @@ -95,7 +96,7 @@ and being mindful of the rivets bindings {{-- Show the full airport name on hover --}} { pirep.dpt_airport.icao } { pirep.arr_airport.icao } - { pirep.aircraft.name } + { pirep.aircraft.registration } { pirep.position.altitude } { pirep.position.gs } { pirep.position.distance.{{setting('units.distance')}} | fallback 0 } / @@ -107,6 +108,7 @@ and being mindful of the rivets bindings +@endif @section('scripts')