drewroberts / media
Laravel Package for opinionated usage of Media (images & videos)
Fund package maintenance!
drewroberts
Installs: 45 441
Dependents: 1
Suggesters: 0
Security: 0
Stars: 2
Watchers: 3
Forks: 5
Open Issues: 18
Requires
- php: ^7.4|^8.0
- cloudinary/cloudinary_php: ^1.20
- silvanite/nova-field-cloudinary: ^1.3.2
- spatie/eloquent-sortable: ^3.11.0
- tipoff/authorization: ^2.8.0
- tipoff/laravel-google-api: ^2.0.0
- tipoff/support: ^2.0.0
Requires (Dev)
- php-mock/php-mock-mockery: ^1.3.0
- tipoff/test-support: ^2.0.0
This package is auto-updated.
Last update: 2024-12-09 22:27:45 UTC
README
This is where your description should go. Limit it to a paragraph or two. Consider adding a small example.
Installation
You can install the package via composer:
composer require drewroberts/media
You can publish the config file with:
php artisan vendor:publish --provider="DrewRoberts\Media\MediaServiceProvider" --tag="config"
Add the cloudinary disk to the filesystem config and set the environment variables for your Cloudinary account.
return [ ... 'disks' => [ ... 'cloudinary' => [ 'driver' => 'cloudinary', 'api_key' => env('CLOUDINARY_API_KEY'), 'api_secret' => env('CLOUDINARY_API_SECRET'), 'cloud_name' => env('CLOUDINARY_CLOUD_NAME'), ] ] ];
Models
The following models are included in this package:
List of Models
- Image
- Tag
- Video
For each of these models, this package implements an authorization policy that extends the roles and permissions approach of the tipoff/authorization package. The policies for each model in this package are registered through the package and do not need to be registered manually.
The models also have Laravel Nova resources in this package and they are also registered through the package and do not need to be registered manually.
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email packages@drewroberts.com instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.