Commit Graph

2441 Commits

Author SHA1 Message Date
B.Fatih KOZ
4985da991b
Remove Scripts (#1200)
* 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
2021-05-23 20:47:15 -04:00
Nabeel Shahzad
c94358350a Add queue worker setting so those aren't run in cron if there's a worker 2021-05-21 12:31:32 -04:00
Nabeel S
d3ec0f4de3
5 char ICAO support #1052 (#1198) 2021-05-21 10:52:47 -04:00
Nabeel S
ede5b74383
Make fuel_used an optional field in PIREP file (#1197) 2021-05-21 10:02:07 -04:00
Nabeel S
e7bbd6cccb
Use queues for notifications #1154 (#1174)
* Use queues for notifications #1154

* Styles

* Update defaults

* Include queueworker
2021-05-20 11:54:07 -04:00
Nabeel S
edcea258ce
Remove the autoupdater #1133 (#1195)
* Remove the autoupdater #1133

* Remove self-updater package

* Package still needed :|
2021-05-20 11:37:27 -04:00
Nabeel Shahzad
5adc0b4072 Remove unused import 2021-05-20 09:20:12 -04:00
Nabeel Shahzad
fe7120e21a Add PHP 7.4 polyfill 2021-05-20 08:55:55 -04:00
B.Fatih KOZ
30be7c245c
Fix Advanced Fuel Calculations (#1190)
* 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 !
2021-05-19 19:01:33 -04:00
Nabeel S
7cb9ae4ec3
intl dependency/polyfill updates (#1194) 2021-05-19 13:57:28 -04:00
Olli
6f1a5f1dc2
Update Flight Controller to fix an issue (#1192)
Closes #1180 and #1156. But now the script isn't beeing loaded

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-05-19 13:42:40 -04:00
Nabeel Shahzad
e3c3c81d19 Include missing scripts in flight create 2021-05-19 13:33:13 -04:00
Nabeel S
352f1ee9f8
Days::in should use in_mask; tests coverage #1180 (#1193) 2021-05-19 11:20:50 -04:00
Nabeel Shahzad
dff4273c72 Force empty to be 0 for in_mask #1180 2021-05-19 10:22:15 -04:00
Nabeel S
77a4acb569
Update dependencies (#1188) 2021-05-14 13:02:47 -04:00
B.Fatih KOZ
ff6827b368
Fix Installer Completed Blade (#1185)
We do not have a config.php anymore, page should refer to env.php for base level configuration.
2021-05-14 12:31:24 -04:00
B.Fatih KOZ
594d0eb222
Check Aircraft Availability (#1177)
* 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.
2021-05-13 15:26:53 -04:00
Nabeel S
ee61de62fa
Update to PHP 8 (#1118)
* Update to PHP 8

* Update composer file

* Remove PHP 8 incompatible library

* Remove PHP 8 incompatible library
2021-05-11 18:46:21 -04:00
B.Fatih KOZ
f2be14402f
PirepCancelled Event (Cron Expired Pirep Deletion) (#1178)
* 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.
2021-05-09 18:30:50 -04:00
B.Fatih KOZ
a186bfae2a
Fix AirportController (Frontend) (#1176)
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.
2021-05-08 15:42:18 -04:00
Nabeel S
6e6ba85080
Fix for duplicated/wrong expenses being applied #915 (#1173)
* Fix for duplicated/wrong expenses being applied #915

* Style fixes
2021-05-06 12:42:56 -04:00
B.Fatih KOZ
d2272e32a6
100LL and MOGAS Fuel Cost (#1172)
* Add defaults for 100LL and MOGAS prices

Add missing defaults for 100LL and MOGAS Fuel prices.

* Calculate Fuel Cost according to Fuel Type

Calculate pirep fuel costs according to aircraft (subfleet) fuel type, use JetA as fail safe default.

* Fix for Failing AwardTest

At least attempting to fix

* Fix fuel types logic

* Style

* Invert the logic

Co-authored-by: Nabeel Shahzad <nabeel@nabeel.sh>
2021-05-06 08:16:33 -04:00
Nabeel S
b6c0946795
Delete users without PIREPS; pilot leave fix (#1171)
* Delete users without PIREPS; pilot leave fix

* Style fixes
2021-05-05 09:56:28 -04:00
Andrew Roberts
fca04e6b0c
Allow session lifetime to be set in env variables (#1170)
* Allow session lifetime to be set in env variables

Currently the session live time defaults to 2 hours, adding an env variable will allow us to change this on a per site basis

* Add whitespace for consistency
2021-05-05 08:51:18 -04:00
Andrew Roberts
5094fce4b0
Disable autocomplete on admin email field (#1169)
* Disable autocomplete on admin email field

Fixes #1165

* Disable autocomplete on admin name and password

For sake of completeness and due to some over zealous autocompleters, also disable it on name and password fields
2021-05-04 13:26:16 -04:00
Nabeel S
fe0ef60b6c
Block refiling of PIREPs (#1167)
* Block refiling of PIREPs

* Style fixes

* Package updates
2021-05-03 10:00:10 -04:00
B.Fatih KOZ
5094375e13
Fixes For GDPR/Deleted Users (#1164)
* Fix DeletedUsers being displayed at Homepage

Deleted users should not be displayed at homepage / newest pilots list. PR fixes that problem.

* Do Not Display Deleted Users with LatestPireps

As the main page, Latest Pilots widget should not display GDPR/Soft deleted users too.

* StyleFix
2021-05-03 08:46:21 -04:00
Nabeel Shahzad
ec6cb42bfd User guard for null 2021-04-23 13:47:54 -04:00
Nabeel S
14d0e99a37
Delete the user in a GDPR compatible way (#1151)
* Delete the user in a GDPR compatible way

* Block user from calls

* Style fix
2021-04-23 10:33:13 -04:00
B.Fatih KOZ
f8c7bc31f5
Add Airline ICAO to Subfleet selectBoxList (#1153)
* Add Airline ICAO to Subfleet selectBoxList

Subfleet dropdown at flight search will look like `Boeing B737-800 WL | THY`

* StyleFix
2021-04-23 09:44:37 -04:00
Nabeel Shahzad
2545328233 Fix APP_URL being called SITE_URL 2021-04-20 23:28:57 -04:00
Russell West
61739ce266
Pirep delete confirmation (#1143)
* adds 100ll option to airport admin

* Adds mogas field too

* adds basic confirmation when deleting pirep
2021-04-15 08:39:42 -04:00
Nabeel S
bffc4f911c
Add tests for the cron jobs (#1141) 2021-04-14 08:37:48 -04:00
Nabeel Shahzad
d18925f473 Add tests for 0 results METAR 2021-04-14 06:45:35 -04:00
Russell West
f5e83461a3
adds 100ll option to airport admin (#1138)
* adds 100ll option to airport admin

* Adds mogas field too

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-04-13 12:03:03 -04:00
Nabeel S
bfddb2c84d
Make sure all dates are in UTC (#1139) 2021-04-13 09:25:38 -04:00
B.Fatih KOZ
7e9eb08135
Use where iso whereTime (#1137)
Using whereTime may present a problem for flights conducted during utc midnight and some active/live flights may be deleted with whereTime.

Scenario;

now = today-01:00  utc
setting = 2 hours
date = yesterday-23:00 utc

Any live pireps will/may be deleted with whereTime 'cause their last updated TIME will be maximum 00:59 which is smaller than 23:00.
2021-04-13 09:08:50 -04:00
B.Fatih KOZ
3d55336823
Fix default value for Captcha setting (#1136) 2021-04-12 16:55:38 -04:00
Nabeel Shahzad
68ed2355ad Add GRAVATAR_DEFAULT_AVATAR to config 2021-04-11 18:42:51 -04:00
Nabeel S
fdab4ee530
Fix email for news not going out (#1131) 2021-04-11 14:32:58 -04:00
Nabeel Shahzad
648e7a261d Add APP_NAME to env stub 2021-04-11 13:46:52 -04:00
Nabeel Shahzad
9cb0a0cf36 Change the default driver to use mail 2021-04-11 12:36:37 -04:00
B.Fatih KOZ
2c8372d484
Read Captcha Settings From ENV (#1130)
* Read Captcha Settings From ENV

* Update captcha.php
2021-04-11 11:35:14 -04:00
Nabeel Shahzad
498d5bfaf0 Slugify cache prefix and quote it in the env 2021-04-10 21:13:34 -04:00
Nabeel Shahzad
2202c5b479 Change default env to prod for fresh install 2021-04-10 18:00:03 -04:00
Nabeel S
ac64a5db75
Migrate all configs into the env.php file #1075 (#1128)
* Migrate all configs into the env.php file #1075

* Style fixes

* Fix config names in CreateConfig

* Fix installer/installer error messages
2021-04-10 17:19:45 -04:00
B.Fatih KOZ
6c3992e781
Fix for Hourly Crons (#1127)
* Fix for Hourly Cron

We should be using whereTime instead of whereDate

https://laravel.com/docs/8.x/queries#additional-where-clauses
`The whereDate method may be used to compare a column's value against a date`

* Fix for RemoveExpiredBids

I used where to do check 'cause people may set 48 hours to remove a bid, thus neither whereDate nor whereTime will give a correct results.

* Fix for DeletePireps

I used where to do check 'cause people may set 48 hours to delete cancelled or rejected pireps, thus neither whereDate nor whereTime will give a correct results.
2021-04-09 19:15:22 -04:00
B.Fatih KOZ
344edde0fb
Alphanumeric Callsign For Flights (#1124)
* Alphanumeric Callsign For Flights

PR adds ability to define alphanumeric callsigns to flights, display them and use them during SimBrief OFP generation (if pilot ident as callsign option is not enabled)

Translations for en/es/it/pt-br added.

* Change db table name

* Change db column name, fix rules

* Change db column name

* Another db column name change

* Just another one more

* Last one from anumeric_callsign to callsign

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-04-05 18:00:50 -04:00
Maximiliano Fallico
7502c053bf
Show Airline logo / icao to subfleets table (#1121)
Will show the subfleet airline logo or icao in the admin flight create page table.

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-04-05 17:05:28 -04:00
Maximiliano Fallico
dbfaed0ecc
Adds Airline Icao to Subfleet Select in Flight Create (#1123)
* Adds Airline Icao to Subfleet Select in Flight Create

* Fix Style

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-04-05 16:55:50 -04:00