GithubHelp home page GithubHelp logo

tappnetwork / filament-auditing Goto Github PK

View Code? Open in Web Editor NEW
76.0 5.0 20.0 77 KB

A Filament plugin for Laravel Auditing package.

PHP 95.80% Blade 4.20%
audit auditing filament laravel php plugin hacktoberfest2022 hacktoberfest

filament-auditing's People

Contributors

amendozaaguiar avatar andreia avatar aseriousdeveloper avatar corean avatar haringsrob avatar husam-tariq avatar joshembling avatar loanbesson avatar logicsatinn avatar nekoding avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

filament-auditing's Issues

Policy not fully working

PHP 8.1
Laravel 10

I've created a policy with audit() and restoreAudit():

public function audit(User $user, Site $site): bool
{
    return $user->can('view audits');
}

public function restoreAudit(User $user, Site $site): bool
{
    return $user->can('restore audits');
}

However, only audit() is working correctly. I'm not able to get restoreAudit() working because anyone can restore an audit. What am I missing here? Thanks.

Undocumented requirement on Laravel 9.x

Running legacy Laravel v8 application, Filament v2, Laravel Auditing v13; This plugin can be installed and configured correctly, and displays the Audit tab for the resource, however selecting the tab throws an exception.

Method Illuminate\Support\Arr::map does not exist.

From the Laravel documentation Arr::map was not introduced until Laravel 9 (https://laravel.com/docs/9.x/helpers#method-array-map).

AuditsRelationManager.php references this method:

protected static function extraColumns()
    {
        return Arr::map(config('filament-auditing.audits_extend'), function ($buildParameters, $columnName) {
            return collect($buildParameters)->pipeThrough([
            // etc

Auditing v13 looks to support Laravel v7 onwards.

Call to undefined method App\Models\User::audits()

Just installed this Filament plugin and followed the instructions. When I add it to the getRelations() array and I refresh the page I do get the follow error:

Call to undefined method App\Models\User::audits()

Filament: 3.0.37
Laravel: 10.10

Call to a member function can() on null in AuditsRelationManager.php --> canViewForRecord()

I'm getting this error when using this package.

I'm using multiple guards. and stancl/tenancy package.

here is my error stack:

https://flareapp.io/share/87n9jj6P#stack

when i dump()

public static function canViewForRecord(Model $ownerRecord, string $pageClass): bool
    {
        dump( auth()->user()->can('audit') );
        return auth()->user()->can('audit', $ownerRecord);
    }

then i see two times on the page:

true // vendor/tapp/filament-auditing/src/RelationManagers/AuditsRelationManager.php:25

But when livewire/update ajax request gives a response the auth()->user()->can('audit') gives back the error...

Filament v3 - Upgrade

I would like to complete my upgrade to Filament v3. Do you plan to make this wonderful package of yours compatible with Filament v3?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.