Files
nala 250ac35fd1
tests / ci (push) Canceled after 0s
first commit
2026-09-28 10:01:09 +02:00

36 lines
785 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\Relations\HasMany;
/**
* @property string|null $investor_id
* @property string $status
*/
class Lead extends CrmRecord
{
protected $table = 'leads';
protected $casts = ['estimated_amount' => 'decimal:2'];
/** @return BelongsTo<Investor, $this> */
public function investor(): BelongsTo
{
return $this->belongsTo(Investor::class);
}
/** @return BelongsTo<User, $this> */
public function owner(): BelongsTo
{
return $this->belongsTo(User::class, 'owner_user_id');
}
/** @return HasMany<CrmTask, $this> */
public function tasks(): HasMany
{
return $this->hasMany(CrmTask::class);
}
}