You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
382 B
PHTML

6 years ago
<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Tag extends Model
{
/**
* Get threads that have this tag.
*/
public function threads() {
return $this->belongsToMany('App\Thread');
}
/**
* Get creator of this tag.
*/
public function creator() {
return $this->belongsTo('App\User', 'creator_id');
}
6 years ago
}