lloricode / laravel-uploader
This package is abandoned and no longer maintained.
The author suggests using the spatie/laravel-medialibrary package instead.
Laravel Uploader
v1.0.4
2018-11-29 00:25 UTC
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.12
- orchestra/testbench: ~3.3.0|~3.4.2|^3.5.0
- phpunit/phpunit: ^5.7|6.2|^7.0
This package is auto-updated.
Last update: 2019-10-14 23:14:40 UTC
README
Install via composer.
composer require lloricode/laravel-uploader
Usage
Model
<?php // .... use Lloricode\LaravelUploader\Contract\UploaderContract; // <-------- add use Lloricode\LaravelUploader\UploaderOptions; // <-------- add use Lloricode\LaravelUploader\Traits\UploaderTrait; // <-------- add class Product extends Model implements UploaderContract // <-------- add { use UploaderTrait; // <-------- add public function uploaderRules() :UploaderOptions // <-------- add { return UploaderOptions::create() ->fileNamePrefix('file-') ->disk('local') // any disk in config/filesystems.disk ->maxSize(20000000); // byte in decimal = 20mb } // ...