Пример #1
0
 public static function countOrphanDocuments()
 {
     return Document::doesntHave('object')->count();
 }
Пример #2
0
 public function orphans()
 {
     $documents = Document::doesntHave('object')->simplePaginate(50);
     return view('document.orphans', ['documents' => $documents]);
 }