@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | /** |
| 81 | 81 | * Get json output. |
| 82 | 82 | * |
| 83 | - * @return array |
|
| 83 | + * @return string |
|
| 84 | 84 | */ |
| 85 | 85 | public function json(Request $request) |
| 86 | 86 | { |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | /** |
| 97 | 97 | * Get csv output. |
| 98 | 98 | * |
| 99 | - * @return array |
|
| 99 | + * @return string|null |
|
| 100 | 100 | */ |
| 101 | 101 | public function csv(Request $request) |
| 102 | 102 | { |
@@ -111,7 +111,7 @@ discard block |
||
| 111 | 111 | /** |
| 112 | 112 | * Get png output. |
| 113 | 113 | * |
| 114 | - * @return array |
|
| 114 | + * @return string|null |
|
| 115 | 115 | */ |
| 116 | 116 | public function png(Request $request) |
| 117 | 117 | { |
@@ -159,8 +159,8 @@ discard block |
||
| 159 | 159 | } |
| 160 | 160 | |
| 161 | 161 | /** |
| 162 | - * @param $cmd |
|
| 163 | - * @return mixed|string |
|
| 162 | + * @param string $cmd |
|
| 163 | + * @return string |
|
| 164 | 164 | */ |
| 165 | 165 | public function runRRDGraph($cmd) |
| 166 | 166 | { |
@@ -176,6 +176,7 @@ discard block |
||
| 176 | 176 | /** |
| 177 | 177 | * Run the RRD Xport query |
| 178 | 178 | * |
| 179 | + * @param string $query |
|
| 179 | 180 | * @return string |
| 180 | 181 | */ |
| 181 | 182 | public function runRRDXport($query) |
@@ -196,6 +197,7 @@ discard block |
||
| 196 | 197 | /** |
| 197 | 198 | * Run the RRD Xport query |
| 198 | 199 | * |
| 200 | + * @param string $response |
|
| 199 | 201 | * @return string |
| 200 | 202 | */ |
| 201 | 203 | public function parseRRDJson($response) |
@@ -224,6 +226,7 @@ discard block |
||
| 224 | 226 | /** |
| 225 | 227 | * Parse RRD output to csv |
| 226 | 228 | * |
| 229 | + * @param string $response |
|
| 227 | 230 | * @return string |
| 228 | 231 | */ |
| 229 | 232 | public function parseRRDCsv($response, $headers) |
@@ -23,13 +23,11 @@ |
||
| 23 | 23 | |
| 24 | 24 | namespace App\Graphs; |
| 25 | 25 | |
| 26 | +use App\Models\Device; |
|
| 26 | 27 | use Carbon\Carbon; |
| 27 | 28 | use Illuminate\Http\Request; |
| 28 | -use Symfony\Component\Process\Process; |
|
| 29 | -use Symfony\Component\Process\ProcessBuilder; |
|
| 30 | 29 | use Symfony\Component\Process\Exception\ProcessFailedException; |
| 31 | -use App\Models\Device; |
|
| 32 | -use Settings; |
|
| 30 | +use Symfony\Component\Process\Process; |
|
| 33 | 31 | |
| 34 | 32 | class BaseGraph |
| 35 | 33 | { |
@@ -23,11 +23,6 @@ |
||
| 23 | 23 | |
| 24 | 24 | namespace App\Graphs; |
| 25 | 25 | |
| 26 | -use Illuminate\Http\Request; |
|
| 27 | -use App\Models\Device; |
|
| 28 | -use Settings; |
|
| 29 | -use App\Models\Port; |
|
| 30 | - |
|
| 31 | 26 | class Device_bits extends BaseGraph |
| 32 | 27 | { |
| 33 | 28 | |
@@ -23,9 +23,7 @@ |
||
| 23 | 23 | |
| 24 | 24 | namespace App\Graphs; |
| 25 | 25 | |
| 26 | -use Illuminate\Http\Request; |
|
| 27 | 26 | use App\Models\Device; |
| 28 | -use App\Models\Processor; |
|
| 29 | 27 | use Settings; |
| 30 | 28 | |
| 31 | 29 | class Device_processor extends BaseGraph |
@@ -23,9 +23,7 @@ |
||
| 23 | 23 | |
| 24 | 24 | namespace App\Graphs; |
| 25 | 25 | |
| 26 | -use Illuminate\Http\Request; |
|
| 27 | 26 | use App\Models\Device; |
| 28 | -use Settings; |
|
| 29 | 27 | |
| 30 | 28 | class Device_storage extends BaseGraph |
| 31 | 29 | { |
@@ -5,7 +5,6 @@ |
||
| 5 | 5 | use Illuminate\Contracts\Auth\Guard; |
| 6 | 6 | use Dingo\Api\Http; |
| 7 | 7 | use Dingo\Api\Routing\Helpers; |
| 8 | -use Illuminate\Http\Request; |
|
| 9 | 8 | |
| 10 | 9 | class SetViewVariable |
| 11 | 10 | { |
@@ -3,10 +3,8 @@ |
||
| 3 | 3 | namespace App\Http\Controllers; |
| 4 | 4 | |
| 5 | 5 | use App\DataTables\DeviceDataTable; |
| 6 | -use App\DataTables\DeviceGroupDataTable; |
|
| 7 | 6 | use App\Models\Device; |
| 8 | 7 | use App\Models\DeviceGroup; |
| 9 | -use App\Models\Port; |
|
| 10 | 8 | use Dingo\Api\Http; |
| 11 | 9 | use Dingo\Api\Routing\Helpers; |
| 12 | 10 | use Illuminate\Http\Request; |
@@ -60,7 +60,6 @@ |
||
| 60 | 60 | /** |
| 61 | 61 | * Display the alerts widget. |
| 62 | 62 | * |
| 63 | - * @param AlertsDataTable $dataTable |
|
| 64 | 63 | * @param null $action |
| 65 | 64 | * @return \Illuminate\Http\JsonResponse|\Illuminate\View\View |
| 66 | 65 | */ |