Enth\u00e4lt gemischt: Laravel-10-Upgrade + Phase 1 (Contacts-Modul, Duplicats-Commands, Soft-Delete+Merge-Fields) + Phase 2 Code-Umstellungen (inquiry_id, $table='contacts'/'inquiries') + Offers-Modul (Migrationen, Models, offer_id in Booking, offer-Disk in filesystems.php). Phase 2 + Offers werden im folgenden Commit nach dev/backups/phase2-offers-2026-04-17/ verschoben, damit der Workspace auf Phase-1-only (= Test-System-Stand) reduziert ist und direkt auf Live deploybar wird. Tarball-Backup zus\u00e4tzlich unter: ../backups-safety/workspace-pre-phase1-rollback-2026-04-17.tar.gz Made-with: Cursor
78 lines
2.5 KiB
PHP
78 lines
2.5 KiB
PHP
<?php
|
|
|
|
/**
|
|
* Created by Reliese Model.
|
|
*/
|
|
|
|
namespace App\Models;
|
|
|
|
use Carbon\Carbon;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* Class LeadParticipant
|
|
*
|
|
* @property int $id
|
|
* @property int $lead_id
|
|
* @property string $participant_name
|
|
* @property string $participant_firstname
|
|
* @property Carbon $participant_birthdate
|
|
* @property int $participant_salutation_id
|
|
* @property Lead $lead
|
|
* @property Salutation $salutation
|
|
* @package App\Models
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant newModelQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant newQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant query()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereLeadId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantBirthdate($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantFirstname($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantName($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantSalutationId($value)
|
|
* @property int|null $participant_child
|
|
* @property int|null $nationality_id
|
|
* @property-read \App\Models\TravelNationality|null $travel_nationality
|
|
* @method static \Illuminate\Database\Eloquent\Builder|LeadParticipant whereNationalityId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|LeadParticipant whereParticipantChild($value)
|
|
* @mixin \Eloquent
|
|
*/
|
|
class LeadParticipant extends Model
|
|
{
|
|
protected $connection = 'mysql';
|
|
|
|
protected $table = 'lead_participant';
|
|
public $timestamps = false;
|
|
|
|
protected $casts = [
|
|
'lead_id' => 'int',
|
|
'participant_salutation_id' => 'int',
|
|
'participant_birthdate' => 'datetime',
|
|
];
|
|
|
|
|
|
protected $fillable = [
|
|
'lead_id',
|
|
'participant_name',
|
|
'participant_firstname',
|
|
'participant_birthdate',
|
|
'participant_salutation_id',
|
|
'participant_child',
|
|
'nationality_id'
|
|
];
|
|
|
|
public function lead()
|
|
{
|
|
return $this->belongsTo(Lead::class);
|
|
}
|
|
|
|
public function salutation()
|
|
{
|
|
return $this->belongsTo(Salutation::class, 'participant_salutation_id');
|
|
}
|
|
|
|
public function travel_nationality()
|
|
{
|
|
return $this->belongsTo(TravelNationality::class, 'nationality_id');
|
|
}
|
|
}
|