Commit Graph

331 Commits

Author SHA1 Message Date
Nabeel S
1287766a46
Fix aircraft retrieval for Simbrief (#1089)
* Fix full aircraft retrieval for simbriefs

* F off StyleCI
2021-03-19 18:25:19 -04:00
B.Fatih KOZ
bbd02bf5c7
Fix For GH Costs (#1088)
* Fix For GH Costs.

PR aims to fix the problem where Airport GH cost is not defined but recored to db as 0.00 or 0 (default value for airports table)
In such cases settings/default apt gh cost will be used.

* Updated logic for JetA1 cost check

* Remove default costs being used during import
2021-03-19 16:42:36 -04:00
exciler
9bb192b97f
Add disable activity check option on certain roles #1078 (#1087)
* Add boolean field "disable activity checks" to role, check for this field inside PilotLeave-Check, add tests

* fix checkbox on form

* CS fixes

* CS fixes again :-)

Co-authored-by: Andreas Palm <ap@ewsp.de>
2021-03-19 13:09:29 -04:00
B.Fatih KOZ
7072428218
Fix Finance Memo (Ground Handling) (#1083)
PR fixes issue #1082
2021-03-18 20:04:13 -04:00
B.Fatih KOZ
1d83b85d8b
Fix for Fuel and Ground Handling Costs (#1050)
* Fix for Fuel and Ground Handling Costs

PR aims to fix issue #1048  and implements the feature request #1049 

If no fuel cost is defined for departure airport, settings / airport fuel price will be used.
If no ground handling cost is defined for airports, settings / airport ground handling cost will be used.

Ground handling prices of both departure and arrival airport will be used for calculations.

* Resolve conflict with latest dev

PR will still fail checks due to double ground handling fares and will work on it to have two records at transactions for dep/arr

* Remove Double GH Costs / Fix The Bug Only

Removed double GH costs for now, pr aims only fixing the current issue (general settings not being read for fuel and ground handling costs)

* Add departure and arrival airports to ground handling

* Style fix

* Fix tests

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
Co-authored-by: Nabeel Shahzad <nabeel@nabeel.sh>
2021-03-18 11:32:40 -04:00
Nabeel S
950c7788be
Restrict Simbrief to user who generated it (#1064)
* Restrict simbrief to user

* Style fixes

* Add tests

* Style fix
2021-03-06 13:49:42 -05:00
Nabeel S
922e754c9e
Check for valid reference object in recurring finance (#1056) 2021-03-02 16:19:54 -05:00
Nabeel S
936cd2efd3
Implement PIREP deletion #1014 (#1055)
* Implement PIREP deletion #1014

* Style fixes

* Add delete button to PIREP listing page

* Remove extra import
2021-03-02 15:43:34 -05:00
Nabeel S
e22d6d5996
Refactoring Simbrief fares and aircraft (#1054)
* Refactoring simbrief fares and aircraft

* Hide user full name/email

* Sort PIREP fields desc; fix cargo counts

* Change the sorting

* Extra logs

* Fix tests

* Return fare information through the API

* Style fixes

* Test fix

* Another test fix

* More fixes

* Set aircraft and fares in prefile

* Formatting
2021-03-02 12:29:04 -05:00
B.Fatih KOZ
efcb7e8895
Fix Advanced Fuel Calculations (#1053)
Due to an error on the settings check advanced fuel calculations was not working and defaulting to fuel used always.
2021-03-01 15:03:27 -05:00
B.Fatih KOZ
4fe323a763
Advanced Fuel Calculations (#1044)
* Advanced Fuel Calculations

PR aims to have realistic fuel debit calculations as in the real ops. When enabled, remaining fuel amounts from previous flight will be reduced from block fuel and airline will only pay for uplifted fuel amount.

If onboard fuel is enough for the flight or exceeds the required amount no fuel debit will be issued.

If this is the first flight of the aircraft or the tanks are dry, full block fuel will be treated as uplifted.

Disabled / uses current default (fuel_used will be debited)

Aircraft table also will hold the fuel_onboard value (not needed for calculations, just saving for displaying purposes)

* Style Fix

* Another Style Fix

Love StyleCi

* Fix Settings

Moved new setting under other pirep settings

* Fix Setting Check

* Fix EOF settings.yml

* Fix Settings
2021-02-24 12:22:52 -05:00
Nabeel Shahzad
a4c431d39f Set missing value from default 2021-02-23 11:25:06 -05:00
Nabeel Shahzad
a52e0410a7 Force default to the value when syncing settings 2021-02-23 11:23:40 -05:00
B.Fatih KOZ
baf63361a0
Fix findUsersOnleave Function (#1042)
Query was checking status field instead of state field to find active users.
2021-02-22 11:23:50 -05:00
B.Fatih KOZ
b4d5c0fbcd
Weather METAR/TAF enhancements (#964)
* Update AviationWeather.php

Added the ability to fetch latest TAF report of given icao from ADDS/NOAA

* Update Weather.php

Used updated Metar\AviationWeather service to improve the widget ability and provide raw TAF data for the view

* Style Fix 1

* Update weather.blade.php

Updated blade to match updated Metar\AviationWeather service and the Weather widget controller.

Also fixed the order of temp - dewpoint - humidity - visibility display according to aviation usage.

Widget now displays raw TAF data just below raw METAR data.

* Update Metar inferface and wrap TAF retrieval in cache

* Styles fix

* Add call to getTaf. Don't call AviationWeather directly

* Fix cache lookup strings

* Fix recursion error

* Update weather.blade.php

Used latest weather.blade , added $taf['raw'] after raw metar.

* Compatibility Update

Updated the widget controller to match latest dev (added raw_only to config)

* Update Weather Widget Blade

Made the widget blade compatible with the TAF reports, widget will display raw metar and taf after the decoder, if no metar or taf recieved it will be displayed in its own row. Also added the new option of raw_only to blade, if it is true, metar decoding will be skipped and only raw values will be displayed. ( Useful when displaying multiple wx widgets at the same page for departure, destination and alternate etc )

Co-authored-by: Nabeel Shahzad <nshahzad@live.com>
Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-02-19 12:45:39 -05:00
B.Fatih KOZ
6b7eab05e2
Assign subfleets from ranks when there are no subfleets on a flight
If no subfleets are assigned to a flight, vmsacars was not allowing the flight to be loaded and used 'cause the subfleets was returning null. With this pr, users will be able to use the aircrafts which they have access to by their ranks. ( Same logic was used in SimBrief Controller to populate the aircraft list for flight plan generation )

Co-authored-by: Nabeel S <nabeelio@users.noreply.github.com>
2021-02-19 08:20:17 -05:00
Nabeel Shahzad
bd85a04530 Fix internal event for ON_LEAVE 2021-02-17 18:57:16 -05:00
Nabeel S
cbb7d6e274
Fix pilot leave calculation #1022 (#1035)
* Fix pilot leave calculation #1022

* Remove unused imports

* Add logging where fares are being saved
2021-02-17 18:54:18 -05:00
Nabeel Shahzad
a6f62045c4 Extend cron check for 12 hours 2021-02-13 15:17:16 -05:00
Nabeel Shahzad
5821067231 Default settings to false 2021-01-25 07:06:27 -05:00
Nabeel S
fc7ad7eb6a
Simbrief attachment not working #1005 (#1006)
* Refactoring for Simbrief not working #1005

* Style fixes

* Update tests for new briefing URL

* Check the OFP user

* Comment out user check temporarily
2021-01-25 06:54:17 -05:00
Nabeel Shahzad
7e9196c7e6 Check if simbrief is valid 2021-01-21 11:57:44 -05:00
Nabeel Shahzad
2e0f0b00ef Ensure simbrief id is assigned 2021-01-21 09:21:39 -05:00
Andrew Roberts
0068b1215a
Remove existing fares when importing (#988)
Delete all existing fares and overwrite with new import when Delete Existing Data is checked/true.
2021-01-16 13:09:56 -05:00
Daniel Ortez
ad8b8e8945
Fix for deleting flights when importing (#984) 2021-01-14 07:07:35 -05:00
Nabeel Shahzad
f62c607138 Change fuel calculation to fuel used #807 2020-12-07 09:46:07 -05:00
Nabeel S
6b5cf38224
Calculate percentage properly instead of adding to the base value #925 (#942)
* Calculate percentage properly instead of adding to the base value #925
2020-11-26 16:44:57 -05:00
Nabeel S
2ecf366670
Add missing columns from subfleet export #926 (#941) 2020-11-26 13:34:04 -05:00
Nabeel S
dc7efc981c
Refactor fares inheritance #905 (#906) 2020-10-27 18:46:15 -04:00
Nabeel Shahzad
aaaf2e7c00 Make sure capacity is an integer 2020-10-24 16:04:09 -04:00
Nabeel S
1be68d1e63
Flight/Subfleet fares not returning in API #899 (#900)
Make sure proper fares are returned from the API #899
2020-10-24 15:11:08 -04:00
Nabeel Shahzad
b83f7dcac8 Updated seed data for dev 2020-10-24 09:26:14 -04:00
Nabeel Shahzad
1c9d1c1733 Extra logs/skip module seed pending 2020-10-21 14:12:38 -04:00
Nabeel S
cd18442207
Fixes for installer/modules race condition (#883) 2020-10-21 13:28:54 -04:00
Yash Govekar
716ba38b6d
Default values for automatically added airports #829 (#878) 2020-10-20 15:25:13 -04:00
Yash Govekar
c0514b381b
Fixed exporting expenses (#877) 2020-10-19 15:22:06 -04:00
Yash Govekar
5803487d51
Installing and managing modules from admin panel (#847) 2020-10-19 10:10:28 -04:00
Nabeel Shahzad
75a0a4c87a Update FareService.php 2020-10-13 18:12:52 -04:00
Nabeel Shahzad
bf878a98a4 Extra logging around fares 2020-10-13 18:10:31 -04:00
Nabeel S
dc007f6d9e
Bids are missing subfleets in API response #867 (#868)
Bids are missing subfleets in API response #867
2020-10-12 12:49:11 -04:00
Nabeel S
69d89511be
Inherited value can't be removed #811 (#863)
Inherited value can't be removed #811
2020-10-10 15:24:10 -04:00
Nabeel S
95a40d3565
Make sure proper subfleets are returned as part of the user profile #848 (#849)
* Make sure proper subfleets are returned as part of the user profile #848

* Formatting
2020-09-30 12:58:45 -04:00
Nabeel S
98aa362935
Fix subfleets not returning proper fare counts #831 (#846)
Fix subfleets not returning proper fare counts #831
2020-09-29 13:21:24 -04:00
Nabeel Shahzad
ac7a5a65e5 Update cron path 2020-09-11 16:57:50 -04:00
Nabeel Shahzad
c5ab0978db Force visible flag to true for imports #818 2020-09-11 09:18:27 -04:00
Nabeel S
cdf7b13b5b
Allow any airport to be flown from #783 (#788)
Allow any airport to be flown from #783
2020-08-17 17:06:02 -04:00
Nabeel S
51186bed7c
Fix for aircraft not being detected at departure airport #781 (#789)
Aircraft not being checked/detected at departure airport #781
2020-08-17 16:44:31 -04:00
Nabeel S
bbb5f1d13c
Check for null values when checking pilot ID #760 (#768) 2020-07-14 22:02:35 -04:00
Nabeel S
3e2b1fe42b
Add spacing to fare labels #763 (#766) 2020-07-10 09:51:33 -04:00
Nabeel Shahzad
df15053b75 Remove trailing comma 2020-06-04 14:05:51 -04:00