Comments (5)
You're right, it isn't ideal and I haven't foreseen this situation.
On first thought it would be better if I named those methods loggedActivity
and causedActivity
. For now I'd only use one of the two trait on your model and add your own loggedActivity
and causedActivity
methods.
I'll fix this in the next major release.
from laravel-activitylog.
I ran into this issue as well with the same use case (a user who causes & logs activity). I'll use the recommended solution but it'd be nice if the package handled this out of the box.
By the way, I really appreciate all the many contributions by spatie. Great packages!
from laravel-activitylog.
I think for now I'm not actually using the CausesActivity trait relationships at all, so I'll just remove it entirely. Thanks!
from laravel-activitylog.
@freekmurze Does this have something that can be tracked to see when it would be implemented? I have hit a scenario where I want to monitor activity against a model as well as monitor any activity it causes. Thanks!
from laravel-activitylog.
Just keep an eye on this repo, our my blog. This problem alone does not warrant an new major version in my mind, so it might take a while until a new major version will be released.
from laravel-activitylog.
Related Issues (20)
- Update logs empty nulls HOT 3
- Wrong minimal Laravel version in package.json HOT 3
- Phone number field is not checked as a string and does not update correctly HOT 2
- Delete method not resulting in log HOT 2
- Nested null relation throws TypeError HOT 1
- Configure more than one auth driver HOT 1
- I want only manual update value log not automatic update value log HOT 2
- Update documentation website HOT 3
- Object of class Illuminate\Support\Carbon could not be converted to int HOT 1
- Laravel-activitylog not installing HOT 5
- Documentation for V3 and V4 missing from Spatie website HOT 1
- Not saving Auth user information when I use with model operations. HOT 1
- Bulk Update Logging Not working
- Properties empty []
- Properties empty [] HOT 1
- updateOrCreate() does not log anything HOT 1
- Log many to many doesn't work
- Log Activity not working from inside Model boot method
- Laravel 11 didnt register activity HOT 1
- Version 4.8.0 Call to undefined method App\Models\User::getStorableEnumValue() HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-activitylog.