<?php
 namespace App\Models; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\BelongsTo; class ClientProductTrial extends Model { protected $fillable = [ 'client_id', 'product_id', 'client_product_id', 'trial_mode', 'started_at', 'ends_at', 'status', 'ending_soon_sent_at', ]; protected $casts = [ 'started_at' => 'datetime', 'ends_at' => 'date', 'ending_soon_sent_at' => 'datetime', ]; public function client(): BelongsTo { return $this->belongsTo(Client::class); } public function product(): BelongsTo { return $this->belongsTo(Product::class); } public function clientProduct(): BelongsTo { return $this->belongsTo(ClientProduct::class); } } 