Files
Intelligent-selection-of-co…/app/Models/PCBuild.php
dimon8 31b79d70c5 123
2026-01-07 06:44:07 +00:00

31 lines
598 B
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class PcBuild extends Model
{
use HasFactory;
protected $fillable = [
'user_id',
'name',
'description',
'is_ai_generated',
'ai_prompt',
];
protected $casts = [
'is_ai_generated' => 'boolean',
'created_at' => 'datetime',
'updated_at' => 'datetime',
];
// Связь с пользователем
public function user()
{
return $this->belongsTo(User::class);
}
}