「同じオカズでチェックイン」ボタンの追加

This commit is contained in:
shibafu
2018-06-02 23:33:16 +09:00
parent d224e6bba4
commit 503e8ba093
4 changed files with 8 additions and 1 deletions

View File

@@ -27,4 +27,9 @@ class Ejaculation extends Model
{
return $this->belongsToMany('App\Tag')->withTimestamps();
}
public function textTags()
{
return implode(' ', $this->tags->map(function ($v) { return $v->name; })->all());
}
}