2017 © Pedro Peláez
 

library laravel-permission

Permission handling for Laravel 5.4 and up

image

spatie/laravel-permission

Permission handling for Laravel 5.4 and up

  • Monday, July 30, 2018
  • by Spatie
  • Repository
  • 137 Watchers
  • 4142 Stars
  • 1,082,302 Installations
  • PHP
  • 114 Dependents
  • 0 Suggesters
  • 558 Forks
  • 38 Open issues
  • 91 Versions
  • 23 % Grown

The README.md

Logo for laravel-permission

Associate users with permissions and roles

[![Latest Version on Packagist](https://img.shields.io/packagist/v/spatie/laravel-permission.svg?style=flat-square)](https://packagist.org/packages/spatie/laravel-permission) [![GitHub Tests Action Status](https://img.shields.io/github/actions/workflow/status/spatie/laravel-permission/run-tests-L8.yml?branch=main&label=Tests)](https://github.com/spatie/laravel-permission/actions?query=workflow%3ATests+branch%3Amain) [![Total Downloads](https://img.shields.io/packagist/dt/spatie/laravel-permission.svg?style=flat-square)](https://packagist.org/packages/spatie/laravel-permission)

Documentation, Installation, and Usage Instructions

See the documentation for detailed installation and usage instructions., (*1)

What It Does

This package allows you to manage user permissions and roles in a database., (*2)

Once installed you can do stuff like this:, (*3)

// Adding permissions to a user
$user->givePermissionTo('edit articles');

// Adding permissions via a role
$user->assignRole('writer');

$role->givePermissionTo('edit articles');

Because all permissions will be registered on Laravel's gate, you can check if a user has a permission with Laravel's default can function:, (*4)

$user->can('edit articles');

Support us

, (*5)

We invest a lot of resources into creating best in class open source packages. You can support us by buying one of our paid products., (*6)

We highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using. You'll find our address on our contact page. We publish all received postcards on our virtual postcard wall., (*7)

Changelog

Please see CHANGELOG for more information what has changed recently., (*8)

Contributing

Please see CONTRIBUTING for details., (*9)

Testing

bash composer test, (*10)

Security

If you discover any security-related issues, please email security@spatie.be instead of using the issue tracker., (*11)

Postcardware

You're free to use this package, but if it makes it to your production environment we highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using., (*12)

Our address is: Spatie, Kruikstraat 22, 2018 Antwerp, Belgium., (*13)

We publish all received postcards on our company website., (*14)

Credits

This package is heavily based on Jeffrey Way's awesome Laracasts lessons on permissions and roles. His original code can be found in this repo on GitHub., (*15)

Special thanks to Alex Vanderbist who greatly helped with v2, and to Chris Brown for his longtime support helping us maintain the package., (*16)

Special thanks to Caneco for the original logo., (*17)

Alternatives

License

The MIT License (MIT). Please see License File for more information., (*18)

The Versions

23/04 2018
07/02 2018

v1.x-dev

1.9999999.9999999.9999999-dev https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1 and up

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

26/10 2017
17/05 2017

dev-fix-guard-checks

dev-fix-guard-checks https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.4 and up

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

17/05 2017

dev-analysis-Xa5dYo

dev-analysis-Xa5dYo https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.4 and up

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

01/04 2017

dev-code-review-freek

dev-code-review-freek https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1 and up

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

31/03 2017

v2.x-dev

2.9999999.9999999.9999999-dev https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1 and up

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

22/02 2017
22/02 2017
20/02 2017
09/02 2017
23/01 2017
19/01 2017
27/12 2016
15/12 2016
26/08 2016
24/07 2016

1.5.1

1.5.1.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

24/07 2016

1.5.0

1.5.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

08/05 2016

1.4.0

1.4.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

27/02 2016

1.3.4

1.3.4.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

24/02 2016

1.3.3

1.3.3.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

23/02 2016

1.3.2

1.3.2.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

10/01 2016

1.3.1

1.3.1.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

25/12 2015

1.3.0

1.3.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

22/12 2015

1.2.1

1.2.1.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

28/10 2015

1.2.0

1.2.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

12/10 2015

1.1.0

1.1.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

11/10 2015

1.0.2

1.0.2.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

30/09 2015

1.0.1

1.0.1.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

16/09 2015

1.0.0

1.0.0.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie

15/09 2015

0.0.1

0.0.1.0 https://github.com/spatie/laravel-permission

Permission handling for Laravel 5.1

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel acl security permission spatie