Mehrere Tickets 49, 50, 51, 52, 53
This commit is contained in:
parent
ae70577289
commit
e3495be8b8
61 changed files with 1904 additions and 344 deletions
|
|
@ -79,6 +79,7 @@ class BookingRepository extends BaseRepository {
|
|||
'travel_country_id' => $data['travel_country_id'] ? $data['travel_country_id'] : null,
|
||||
'travelagenda_id' => $data['travelagenda_id'] ? $data['travelagenda_id'] : null,
|
||||
'travel_category_id' => $data['travel_category_id'] ? $data['travel_category_id'] : null,
|
||||
'comfort' => isset($data['travel_comfort']) ? true : false,
|
||||
'start_date' => $data['start_date'] ? _reformat_date($data['start_date']) : null,
|
||||
'end_date' => $data['end_date'] ? _reformat_date($data['end_date']) : null,
|
||||
'title' => $data['title'],
|
||||
|
|
@ -88,7 +89,8 @@ class BookingRepository extends BaseRepository {
|
|||
'paying_out_status' => $data['paying_out_status'],
|
||||
'branch_id' => $data['branch_id'],
|
||||
'travel_company_id' => $data['travel_company_id'],
|
||||
'airline_id' => $data['airline_id'],
|
||||
//'airline_id' => $data['airline_id'],
|
||||
'airline_ids' => isset($data['airline_ids']) ? $data['airline_ids'] : null,
|
||||
'refund' => $data['refund'],
|
||||
'refund_date' => _reformat_date($data['refund_date']),
|
||||
'lawyer_date' => _reformat_date($data['lawyer_date']),
|
||||
|
|
@ -103,6 +105,13 @@ class BookingRepository extends BaseRepository {
|
|||
];
|
||||
$this->model->fill($fill);
|
||||
$this->model->save();
|
||||
|
||||
if($this->model->booking_draft_items){
|
||||
foreach($this->model->booking_draft_items as $booking_draft_item){
|
||||
$booking_draft_item->comfort = isset($data['travel_comfort']) ? true : false;
|
||||
$booking_draft_item->save();
|
||||
}
|
||||
}
|
||||
return $this->model;
|
||||
}
|
||||
|
||||
|
|
@ -199,6 +208,7 @@ class BookingRepository extends BaseRepository {
|
|||
if($Participant->booking_id !== $this->model->id){
|
||||
abort(500);
|
||||
}
|
||||
$fill['participant_pass'] = isset($fill['participant_pass']) ? true : false;
|
||||
$fill['participant_child'] = isset($fill['participant_child']) ? true : false;
|
||||
$fill['participant_birthdate'] = isset($fill['participant_birthdate']) ? _reformat_date($fill['participant_birthdate']) : null;
|
||||
$Participant->fill($fill);
|
||||
|
|
@ -211,6 +221,8 @@ class BookingRepository extends BaseRepository {
|
|||
$this->model->participant_firstname = isset($data['participant_firstname']) ? $data['participant_firstname'] : null;
|
||||
$this->model->nationality_id = isset($data['nationality_id']) ? $data['nationality_id'] : null;
|
||||
$this->model->participant_birthdate = isset($data['participant_birthdate']) ? _reformat_date($data['participant_birthdate']) : null;
|
||||
$this->model->participant_pass = isset($data['participant_pass']) ? true : false;
|
||||
|
||||
|
||||
$this->model->save();
|
||||
return $this->model;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue