1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace App\Http\Controllers\FrontEnd; |
4
|
|
|
|
5
|
|
|
use App\Http\Controllers\Controller; |
6
|
|
|
use App\Interfaces\MessageServiceInterface; |
7
|
|
|
use App\Models\Thread; |
8
|
|
|
use Illuminate\Http\Request; |
9
|
|
|
|
10
|
|
|
class ThreadController extends Controller |
11
|
|
|
{ |
12
|
|
|
/** |
13
|
|
|
* @var MessageServiceInterface |
14
|
|
|
*/ |
15
|
|
|
public MessageServiceInterface $service; |
16
|
|
|
|
17
|
|
|
/** |
18
|
|
|
* @param MessageServiceInterface $service |
19
|
|
|
*/ |
20
|
|
|
public function __construct(MessageServiceInterface $service) |
21
|
|
|
{ |
22
|
|
|
$this->service = $service; |
23
|
|
|
} |
24
|
|
|
|
25
|
|
|
/** |
26
|
|
|
* Display a listing of the resource. |
27
|
|
|
* |
28
|
|
|
* @return \Illuminate\Http\Response |
29
|
|
|
*/ |
30
|
|
|
public function index() |
31
|
|
|
{ |
32
|
|
|
// |
33
|
|
|
} |
34
|
|
|
|
35
|
|
|
/** |
36
|
|
|
* Show the form for creating a new resource. |
37
|
|
|
* |
38
|
|
|
* @return \Illuminate\Http\Response |
39
|
|
|
*/ |
40
|
|
|
public function create() |
41
|
|
|
{ |
42
|
|
|
// |
43
|
|
|
} |
44
|
|
|
|
45
|
|
|
/** |
46
|
|
|
* Store a newly created resource in storage. |
47
|
|
|
* |
48
|
|
|
* @param \Illuminate\Http\Request $request |
49
|
|
|
* @return \Illuminate\Http\Response |
50
|
|
|
*/ |
51
|
|
|
public function store(Request $request) |
|
|
|
|
52
|
|
|
{ |
53
|
|
|
// |
54
|
|
|
} |
55
|
|
|
|
56
|
|
|
/** |
57
|
|
|
* Display the specified resource. |
58
|
|
|
* |
59
|
|
|
* @param string $thread |
60
|
|
|
* @return \Illuminate\Http\Response |
61
|
|
|
*/ |
62
|
|
|
public function show(string $thread) |
63
|
|
|
{ |
64
|
|
|
$thread = $this->service->thread($thread); |
65
|
|
|
|
66
|
|
|
return view('thread', compact('thread')); |
|
|
|
|
67
|
|
|
} |
68
|
|
|
|
69
|
|
|
/** |
70
|
|
|
* Show the form for editing the specified resource. |
71
|
|
|
* |
72
|
|
|
* @param int $id |
73
|
|
|
* @return \Illuminate\Http\Response |
74
|
|
|
*/ |
75
|
|
|
public function edit($id) |
|
|
|
|
76
|
|
|
{ |
77
|
|
|
// |
78
|
|
|
} |
79
|
|
|
|
80
|
|
|
/** |
81
|
|
|
* Update the specified resource in storage. |
82
|
|
|
* |
83
|
|
|
* @param \Illuminate\Http\Request $request |
84
|
|
|
* @param int $id |
85
|
|
|
* @return \Illuminate\Http\Response |
86
|
|
|
*/ |
87
|
|
|
public function update(Request $request, $id) |
|
|
|
|
88
|
|
|
{ |
89
|
|
|
// |
90
|
|
|
} |
91
|
|
|
|
92
|
|
|
/** |
93
|
|
|
* Remove the specified resource from storage. |
94
|
|
|
* |
95
|
|
|
* @param int $id |
96
|
|
|
* @return \Illuminate\Http\Response |
97
|
|
|
*/ |
98
|
|
|
public function destroy($id) |
|
|
|
|
99
|
|
|
{ |
100
|
|
|
// |
101
|
|
|
} |
102
|
|
|
} |
103
|
|
|
|
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.