Fix PIREP field and non-existant airport errors when editing PIREPs

This commit is contained in:
Nabeel Shahzad
2018-07-12 21:20:10 -05:00
parent 85615300e0
commit 9cc640b866
18 changed files with 138 additions and 65 deletions

View File

@@ -298,7 +298,8 @@ class PirepController extends Controller
# set the custom fields
foreach ($pirep->fields as $field) {
$pirep->{$field->slug} = $field->value;
$field_name = 'field_'.$field->slug;
$pirep->{$field_name} = $field->value;
}
# set the fares