Total Complexity | 5 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | class CustomerNotesController extends Controller |
||
14 | { |
||
15 | |||
16 | 26 | public function __construct() |
|
19 | 26 | } |
|
20 | |||
21 | // Store a new customer note |
||
22 | 4 | public function store(CustomerNewNoteRequest $request) |
|
23 | { |
||
24 | 4 | (new SetCustomerNotes($request->cust_id))->createNote($request); |
|
25 | 4 | return response()->json(['success' => true]); |
|
26 | } |
||
27 | |||
28 | // Get the customer notes |
||
29 | 4 | public function show($id) |
|
32 | } |
||
33 | |||
34 | // Update a customer note |
||
35 | 4 | public function update(CustomerEditNoteRequest $request, $id) |
|
36 | { |
||
37 | 4 | (new SetCustomerNotes($request->cust_id))->updateNote($request, $id); |
|
38 | 4 | return response()->json(['success' => true]); |
|
39 | } |
||
40 | |||
41 | // Delete a customer note |
||
42 | 2 | public function destroy($id) |
|
46 | } |
||
47 | } |
||
48 |