Total Complexity | 3 |
Total Lines | 45 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
20 | class RequestsCommand extends Command |
||
21 | { |
||
22 | protected $signature = 'concord:requests'; |
||
23 | |||
24 | protected $description = 'List Form Requests'; |
||
25 | |||
26 | protected $headers = ['Name', 'Contract', 'Concrete']; |
||
27 | |||
28 | public function handle(Concord $concord) |
||
29 | { |
||
30 | $bindings = $concord->getRequestBindings(); |
||
31 | |||
32 | if ($bindings->count()) { |
||
33 | $this->showBindings($bindings); |
||
34 | } else { |
||
35 | $this->line('No requests have been registered.'); |
||
36 | } |
||
37 | } |
||
38 | |||
39 | /** |
||
40 | * Displays the list of enum bindings on the output |
||
41 | * |
||
42 | * @param Collection $bindings |
||
43 | */ |
||
44 | protected function showBindings(Collection $bindings) |
||
65 | } |
||
66 | } |
||
67 |