first commit

This commit is contained in:
Doar Mihai
2026-04-28 16:10:27 +03:00
commit b73f568d90
107 changed files with 18067 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class Favorite extends Model
{
protected $fillable = [
'user_id',
'city_id',
];
/**
* Get the user that owns this favorite
*/
public function user(): BelongsTo
{
return $this->belongsTo(User::class);
}
/**
* Get the city that was favorited
*/
public function city(): BelongsTo
{
return $this->belongsTo(City::class);
}
}