Game-Jaming/Backend/Models/Group.php

25 lines
395 B
PHP
Raw Normal View History

2021-03-03 10:48:34 +00:00
<?php
2021-04-19 07:15:15 +00:00
2021-03-03 11:56:14 +00:00
namespace Backend\Models;
2021-04-19 07:15:15 +00:00
2021-03-03 10:48:34 +00:00
use Illuminate\Database\Eloquent\Model as Eloquent;
2021-04-19 07:15:15 +00:00
2021-03-03 11:48:49 +00:00
class Group extends Eloquent
2021-03-03 10:48:34 +00:00
{
protected $fillable = [
2021-03-08 12:09:50 +00:00
'group_name', 'group_amount', 'votes'
2021-03-03 10:48:34 +00:00
];
2021-03-04 09:19:58 +00:00
2021-04-19 07:15:15 +00:00
public function password()
{
2021-03-05 10:23:10 +00:00
return $this->hasOne(Password::class);
2021-03-04 09:19:58 +00:00
}
2021-04-19 07:15:15 +00:00
public function registrations()
{
return $this->hasMany(Registration::class);
2021-03-05 12:00:07 +00:00
}
2021-03-03 10:48:34 +00:00
}