c4tech / upload
A basic package for handling uploaded files.
1.0.1
2015-10-07 12:46 UTC
Requires
- php: >=5.4.0
- c4tech/support: ^3.0.0
- illuminate/support: ^5.0.0
Requires (Dev)
- mockery/mockery: 0.9.*
- phpunit/phpunit: ^4.0.0
This package is not auto-updated.
Last update: 2024-11-23 19:06:02 UTC
README
File uploads are nice. We were processing uploaded files in so many applications, that it became easier to make a single, polymorphic relation for reuse across applications and entities.
What's in the box?
The Upload model is simple enough. It comes paired with traits, for both Models and Repositories, to provide the necessary functionality to relate to uploads.
Installation and setup
- Add
"c4tech/upload": "1.x"
to your composer requirements and runcomposer update
. - Add
C4tech\Upload\ServiceProvider
to your service providers config array. - Run
php artisan vendor:publish
to get the migrations. - Run
php artisan migrate
to set up the migrations. - (Optional) Edit
config/upload.php
and change entries inmodels
andrepos
to match your class names. - (Optional) Map the Repository Facades in your facades config array for fast access:
a.
"Upload" => "C4tech\Upload\Facade"