Questions tagged [laravel-auditing]

This tag should be used for questions about the Laravel Auditing package.

Information on the Laravel Auditing package is available at http://www.laravel-auditing.com/. Documentation is available at http://www.laravel-auditing.com/docs/.

22 questions
3
votes
1 answer

How to audit new custom data in Laravel Auditing's table?

I want to store new data in the Laravel Auditing logs and register new field in the automatic logs used by Laravel Auditing. I'm trying to add a new field in the Laravel Auditing's table so I can log custom data when the auditing is done. I am using…
2
votes
3 answers

Non-static method Cartalyst\Sentinel\Sentinel::getUser() should not be called statically

Hi I am using laravel Sentinel as my Auth, also I am trying to use laravel auditing I am getting "Non-static method Cartalyst\Sentinel\Sentinel::getUser() should not be called statically". In my user model I have added a static function resolveId()…
2
votes
1 answer

Invalid User resolver, callable or UserResolver FQCN expected error [Laravel Auditing 4.1]

I am using Laravel 5.4 and Laravel Auditing 4.1. I want to record the price changes on Variant model, I installed the Auditing 4.1 package. See my code, config/audit.php 'implementation' => OwenIt\Auditing\Models\Audit::class, 'user' => [ …
Vinod VT
  • 6,946
  • 11
  • 51
  • 75
1
vote
1 answer

Laravel how to access the relation data on a custom pivot class

I wan't to store updates in pivot tables inside a separate table called audits_pivot. To do that I need to sort of hook into the attached event on the model (State), which as I found out doesn't really exist. What I can do is to listen on the custom…
Tom
  • 4,070
  • 4
  • 22
  • 50
1
vote
1 answer

Laravel Auditable History Tables - Pro & Cons of SQL History or an auditing package?

My problem is that I'm not sure what to do. I'm thinking to build a similar database structure like this (source): However, while researching I found out that there are auditing packages like this. So I wonder, what are the pro and cons? My…
Philipp Mochine
  • 4,351
  • 10
  • 36
  • 68
1
vote
1 answer

Laravel Auditing AuditableTransitionException Error on Morphmap on transitionTo()

I am able to successfully record changes to classes, and return what has been changed (not including many-to-many). However, I am unable to revert back any change using the built-in new transitionTo() method. I get the following error on all…
Watercayman
  • 7,970
  • 10
  • 31
  • 49
0
votes
1 answer

Laravel Auditing update event not working

Laravel auditing on update does not work in my laravel eloquent application in few models. except for the user model. following is the audit.php events 'events' => [ 'created', 'updated', 'deleted', 'restored', ], 'strict' =>…
Mohamed Raza
  • 818
  • 7
  • 24
0
votes
1 answer

Laravel Audit and UUIDS?

I am using laravel auditing it shows an error on UUIDs I think, I have installed and configure the laravel auditing from http://www.laravel-auditing.com/docs/9.0/installation and change the user_id and id to UUIDs where the default types are…
ismail khan
  • 287
  • 1
  • 3
  • 16
0
votes
1 answer

Is there any way to specify a specific user when auditing a Model?

Expected Behaviour I'm auditing the Product model currently but I just want to audit the model when a specific user makes any change, is there any way I could achieve this? Possible Solutions It would be great if the Developer get the control to set…
Mudit Gulgulia
  • 1,131
  • 7
  • 21
0
votes
0 answers

Does Laravel Audit Works for Mass Insertion

Laravel Audit APplied on My project is working for single insertion, update delete etc, but when doing Mass insert, its not Auditing, Does Laravel audit works for Mass insert / delete?
vrnair24
  • 85
  • 1
  • 9
0
votes
1 answer

How to add prefix/suffix or modify user_agent value of Audit - laravel?

Need to add some detail with the user_agent in audit table, sometime need to reduce the length of user_agent. How to configure or override it. using - owen-it/laravel-auditing
OutForCode
  • 381
  • 9
  • 26
0
votes
1 answer

Why laravel auditing not functioning?

I have done my coding but the laravel audit seems not catch the data for update. The data i try to update is on the column of value, but on the database the value are not be catch on audit table for auditing the update changes . below is the…
0
votes
1 answer

User type and user Id is NULL in Laravel Auditing table

I use Laravel auditing for tracking model changes in my system. I see the admin type track user type and Id but for staff users, user_type and user_id is NULL and here is my code: config/audit.php
Khalil DaNish
  • 547
  • 5
  • 18
0
votes
0 answers

Laravel whereJsonContains getting records with jsonContains and does not contains

Sample data: 13 => {#531 ▼ +"id": 956 +"user_type": "App\User" +"user_id": 35 +"event": "updated" +"auditable_type": "App\Video" +"auditable_id": 136 +"old_values": "{"video_status_ids":"[4,…
Prafulla Kumar Sahu
  • 9,321
  • 11
  • 68
  • 105
0
votes
0 answers

laravel whereJson Contains on laravel audits

In new values column for auditable_id=2239, new_values is {"video_status_ids":"[4,10]"} I am getting correct data for In tinker App\Video::find(2239)->audits()->get() Collection contains OwenIt\Auditing\Models\Audit {#3140 id: 322113, …
Prafulla Kumar Sahu
  • 9,321
  • 11
  • 68
  • 105
1
2