@@ -165,7 +165,7 @@ |
||
165 | 165 | * Method downloads the requested file from the API and saves it to the local machine. |
166 | 166 | * Method respects authentication and access rules. |
167 | 167 | * |
168 | - * @param integer|File $file the ID of the file, or the [[File]] model. |
|
168 | + * @param File $file the ID of the file, or the [[File]] model. |
|
169 | 169 | * When model is passed, no additional query will be performed. |
170 | 170 | * @param bool $overrideCache whether the cache must be invalidated |
171 | 171 | * @return string full path to the file. File is located under the [[directory]] |
@@ -14,10 +14,8 @@ |
||
14 | 14 | use hipanel\components\FileStorage; |
15 | 15 | use hipanel\helpers\ArrayHelper; |
16 | 16 | use hipanel\models\File; |
17 | -use hipanel\widgets\filePreview\FilePreviewFactory; |
|
18 | 17 | use hipanel\widgets\filePreview\FilePreviewFactoryInterface; |
19 | 18 | use hipanel\widgets\filePreview\Dimensions; |
20 | -use hipanel\widgets\filePreview\OutboundDimensions; |
|
21 | 19 | use hipanel\widgets\filePreview\types\PdfPreviewGenerator; |
22 | 20 | use hipanel\widgets\filePreview\UnsupportedMimeTypeException; |
23 | 21 | use hipanel\widgets\filePreview\InsetDimensions; |
@@ -143,6 +143,9 @@ |
||
143 | 143 | return ['/file/view', 'id' => $this->file->id]; |
144 | 144 | } |
145 | 145 | |
146 | + /** |
|
147 | + * @param string $ext |
|
148 | + */ |
|
146 | 149 | private function getExtIcon($ext) |
147 | 150 | { |
148 | 151 | $defaultIcon = 'fa-file-text-o'; |