Skip to content

Releases: codinglabsau/laravel-roles

v2.5.1

11 Mar 04:25
Compare
Choose a tag to compare
  • Support Laravel 11

Full Changelog: v2.5.0...v2.5.1

v2.5.0

20 Feb 01:24
Compare
Choose a tag to compare

Changed

  • Dropped Laravel 9 compatibility due to complications managing PHPUnit 9 and 10

Full Changelog: v2.3.0...v2.5.0

Laravel 10 Support

16 Feb 00:17
Compare
Choose a tag to compare
Laravel 10 Support Pre-release
Pre-release

Full Changelog: v2.3.0...v2.4.0

v2.3.0

11 Mar 00:52
Compare
Choose a tag to compare

Added Laravel 9 support.

v2.2.0

07 Sep 01:20
Compare
Choose a tag to compare

Added the @role('role-name') blade directive.

v2.1.1

29 Jun 05:24
35a3005
Compare
Choose a tag to compare

Added PHP 8 support.

v2.1.0

22 Apr 02:22
Compare
Choose a tag to compare

Added

  • In the CheckRole middleware, a 401 exception will occur if the $request->user() is not set. This prevents a call to ->roles() on a non-object.
  • Added HTTP tests to ensure check roles is working

Changed

  • Refactored tests, added a new base test class, fixed namespace

v2.0.0

29 Jan 05:10
753d0fe
Compare
Choose a tag to compare

The following changes have been implemented for v2.0.0:

Optimised Role Check

Role check no longer queries the relationship every time it checks for a role. Instead the roles relationship is loaded and the collection is used to check for the existence of a role which only results in one query.

Migrations no longer automatically run

Initially in 1.x the migrations would run automatically using the packages migrations. This was restrictive as you couldn't publish them and customise the table columns. In v2 the migrations don't run automatically anymore and you must now publish the migrations to be able to use them. This gives greater control and flexibility over the roles and role_user table by allowing you to add new columns.

Configurable role model

There is now a config file that can be published in which you can reference your own role model to use for the roles relationships. This will have no impact on normal usage however the option is there if you need a custom Role model.

v1.2.0

16 Sep 23:54
Compare
Choose a tag to compare

Added Laravel 8 support

Gate can accept an array

09 Apr 07:26
Compare
Choose a tag to compare
  • Fix gate to accept an array of roles
  • add tests
  • add travis-ci config