backend/app/models/Answer.php
2024-07-09 16:08:50 +03:00

14 lines
298 B
PHP

<?php
namespace app\models;
use \Illuminate\Database\Eloquent\Model;
class Answer extends Model {
protected $table = 'AnswerController';
protected $fillable = ['answer','user_id','question_id'];
public function upvotes()
{
return $this->hasMany('\Models\Upvote');
}
}