smskin/identity-service-nova3-tool

dev-main 2022-05-31 17:10 UTC

This package is auto-updated.

Last update: 2024-10-29 06:46:57 UTC


README

This is Nova Tool for manage Identity service (https://github.com/smskin/laravel-idenity-service)

Installation

  1. composer require smskin/identity-service-nova3-tool
  2. Delete default User resource (app/Nova/User.php)
  3. Add SMSkin\IdentityServiceNova3Tool\IdentityServiceNova3Tool to App\Providers\NovaServiceProvider.php

Example of NovaServiceProvider

...
public function tools()
{
    return [
        new IdentityServiceNova3Tool
    ];
}
...

Customization

You can extend default Nova Resource and pass it to Tool

...
public function tools()
{
    return [
        (new IdentityServiceNova3Tool)
            ->setScopeGroupResource(ScopeGroup::class)
            ->setScopeResource(Scope::class)
            ->setUserEmailCredentialResource(UserEmailCredential::class)
            ->setUserPhoneCredentialResource(UserPhoneCredential::class)
            ->setUserOAuthCredentialResource(UserOAuthCredential::class)
            ->setUserResource(User::class)
    ];
}
...