connection between docs or transactions added to recurring messages part #1pbthq3
This commit is contained in:
@ -140,6 +140,11 @@ class Document extends Model
|
||||
return $this->totals()->orderBy('sort_order');
|
||||
}
|
||||
|
||||
public function parent()
|
||||
{
|
||||
return $this->belongsTo('App\Models\Document\Document', 'parent_id');
|
||||
}
|
||||
|
||||
public function scopeLatest(Builder $query)
|
||||
{
|
||||
return $query->orderBy('issued_at', 'desc');
|
||||
|
Reference in New Issue
Block a user