Last active
February 16, 2017 06:20
-
-
Save Mombuyish/3075d466e187fa142418ec0b3c40c427 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http\Controllers; | |
use App\Services\CollectionService; | |
use Illuminate\Http\Request; | |
class CollectionsController extends Controller | |
{ | |
/** | |
* @var CollectionService | |
*/ | |
private $collectionService; | |
public function __construct(CollectionService $collectionService) | |
{ | |
$this->collectionService = $collectionService; | |
} | |
/** | |
* Display a listing of the resource. | |
* | |
* @return \Illuminate\Http\Response | |
*/ | |
public function index() | |
{ | |
$collections = $this->collectionService->all(); | |
return view('collections.index', compact('collections')); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment