laravel-learn-bbs/app/Models/Category.php

22 lines
313 B
PHP
Raw Permalink Normal View History

<?php
namespace App\Models;
2018-06-10 10:04:03 +00:00
/**
* Class Category
* @property int $id
* @property string $name
* @property string $description
* @package App\Models
*/
2018-01-01 07:22:14 +00:00
class Category extends Model
{
protected $guarded = ['id'];
2018-01-01 06:51:46 +00:00
public function topics()
{
return $this->hasMany(Topic::class);
}
}