* Update helpers.php
Looks like php8 is not liking numeric strings as we like them.
Fixes#1229
* StyleFix
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
* New Language: German
* Update German K
* Fixed German Translation
Co-authored-by: derrobin154 <derrobin154@gmail.com>
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
* Discord notifications for events #433
* Style fixes
* Check for blank webhook urls and disable
* Cleanup items after review
* Changes and fixes
* Style fixes
* Don't load env for testing
* Fix status text
* Refactor saving fields/fares so events get the latest data
* Cleanup
* Style fixes
* Block Aircraft with SimBrief
Changes aim to have the ability to block an aircraft's usage if it is used to generate a SimBrief OFP.
Unused/Expired briefings will be deleted by cron like before but will now be checked by HourlyCron, so admins can define more precise restrictions for them (and the blockage period of their aircraft)
Owner of the SimBrief OFP will be able to start a flight with acars using that particular aircraft, but pilots will get an Aircraft Not Available error (similar to Aircraft State check)
To prevent SimBrief OFP packs being marked as expired/unused, during pirep prefile, pirep_id will be saved to SimBrief model along with flight_id.
And when a flight is finished (pirep file), flight_id will be removed from SimBrief model as before. Only pirep_id will remain and aircraft will be available for another OFP generation.
* Update PirepController
In case a pirep is being saved/submitted with manual entry (but the va is using simbrief effectively) same logic should be applied during save/submit button selection.
Save will act like a pirep prefile , Submit will be pirep file.
* Manual Pirep Checks
Manual pireps, prefiled from a generated simbrief should be checked too. Also pirep.show blade's submit button should provide the same simbrief checks.
* Update PirepService.php
* Change settings and move sb cron to hourly
* StyleFix (SimBriefService)
* Another StyleFix (SimBriefService)
* Update SimBriefController
Removed null check of pirep_id for aircraft list generation to prevent live flights' aircraft being listed for another ofp generation.
( Active acars flights will have both flight_id and pirep_id at simbrief table)
* Update PirepService.php
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
* Update PirepController
Frontend : Use `$subfleet->type` instead of `name` for grouping aircraft list.
* Update PirepController (Admin)
Use `$subfleet->type` instead of `name` here too , for grouping aircraft list according to their subfleets.
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
* Fix removeExpiredEntires()
* Fix SimBriefTest
No need to add `'pirep_id' => ''` , just let it be `null` (like the core code does) and no need to convert Carbon to DateTimeString.
* Update Flight Controller
Show only used flight types in the search form instead of all IATA Flight Types.
* PrePR StyleFix
* StyleFix
* Use Model instead of DB
Also used the same $where array
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
* Edit Search Form
Add ability to search via flight/route code (technically it was possible but the field was not present in the blade)
* Add Code (EN)
* Add Code (ES)
* Add Code (IT)
* Add Code (PT-BR)
* FlightCode => Code
* FlightCode => Code
* FlightCode => Code
* FlightCode => Code
* FlightCode => Code
* Fix Admin / UserController
Use Role Repository and `selectBoxList` method instead of the model itself.
* Fix Flight Fields
Added empty/blank option for clearing out the days when needed
* StyleFix
* Handle Route and Level fields too during import.
* Also removed the check for `visible => true` from `firstorNew` 'cause va admin may be importing to update not visible flights too.
(by default all new flights are visible, so no affect on new flights)
Closes#1201
* Remove Scripts
Remove scripts from create blade which are designed for edit blade in the first place (thus looking for flight object and its properties).
No need to have an eyecandy date picker or a days selector, previous working version of create.blade was more than enough to manually add fights.
* Add placeholder for date fields
* Fix Advanced Fuel Calculations
Current code works fine with a fresh submitted pirep but when a re-calculation is needed, fuel amount will not be correct if the aircraft was flown later on.
Commit provides fix for such re-calculation scenarios.
* StyleFix for the Comment Line !
* Check Aircraft Availability before Prefile
Check if the aircraft is available for flight (State : Parked / On Ground). If not throw new exception AircraftNotAvailable
* Add Exception
AircraftNotAvailable exception, used by PirepService during prefile checks.
* PirepCancelled Event (Cron Expired Pirep Deletion)
While deleting frozen in progress pireps we should at least send a PirepCancelled event for those who are listening.
(or we may have a new PirepDeleted event to be issued in such cases, I think PirepCancelled is enough though)
* StyleFix
* Another StyleFix
* Missing Log
Of course it will not be possible to write log entries without the Log itself.
1. Inbound and Outbound flights were displaying all flights (active and inactive) , fixed to fetch only active flights.
2. Flash message and redirect to Dashboard was not working, instead we were getting 404 Not Found error.