Added function to get the date of a sub-booking.

This commit is contained in:
Lukas Halbritter
2018-09-09 09:56:08 +02:00
parent fe50b6eb85
commit cbaa9b9174
+9 -1
View File
@@ -6,5 +6,13 @@ use Illuminate\Database\Eloquent\Model;
class SubBooking extends Model class SubBooking extends Model
{ {
// /*
* Get the booking date for a sub-booking.
*
* @return string
*/
public function date()
{
return $this->belongsTo('\App\Booking', 'booking_id')->first()->date;
}
} }