Neues Update

This commit is contained in:
daniel committed 2013-11-09 21:23:58 +01:00
1 parent c17b699d1b
commit 114e658b7b
7 files changed
+157 -28

No files matched your search

+5 -1
View File
@@ -7,7 +7,11 @@ class Comment extends Eloquent {
return $this->belongsTo('User', 'user');
}
public function film() {
public function objekt() {
return $this->belongsTo('Film', 'film');
}
public function scopeNeueste($query) {
return $query->orderBy('updated_at', 'DESC')->take(5);
}
}