Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search by properties?? #210

Closed
Albvadi opened this issue Jun 23, 2017 · 1 comment
Closed

Search by properties?? #210

Albvadi opened this issue Jun 23, 2017 · 1 comment

Comments

@Albvadi
Copy link

Albvadi commented Jun 23, 2017

Hi,
thanks for this super usefull package!

It´s possible search by a extra property??
For example:

activity()->withProperties(['special_code' => 123456])->log(':causer.username modify something...');

And now, get all logs with the same code, something like:

Activity::whereProperty('special_code', 123456)-get();

Thanks again!

@freekmurze
Copy link
Member

The extra properties are stored as json. So you could just use the Eloquent query builder for that: https://laravel.com/docs/5.4/queries#json-where-clauses

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants