FeWo Mail, Booking Services

This commit is contained in:
Kevin Adametz 2020-07-09 12:36:15 +02:00
parent 730832c8e1
commit e6cc042aee
62 changed files with 1766 additions and 284 deletions

View file

@ -159,7 +159,8 @@ class TravelUserBookingFewo extends Model
protected $dates = [
'booking_date',
'from_date',
'to_date'
'to_date',
'deleted_at'
];
protected $fillable = [
@ -190,6 +191,16 @@ class TravelUserBookingFewo extends Model
'status_text'
];
protected static function boot() {
parent::boot();
static::deleting(function($model) {
foreach ($model->customer_fewo_mails as $relation)
{
$relation->delete();
}
});
}
public static $customer_mail_dirs = [
11 => ['name' => 'Entwürfe', 'icon'=>'ion-md-create'],
12 => ['name' => 'Papierkorb', 'icon'=>'ion-md-trash'],