Support the ongoing development of Laravel.io →
posted 9 years ago
Database
Last updated 2 years ago.
0

Is it a realy mindless question or a hard nut to crack? I Googled this topic a lot, but I can not find any direction.

Last updated 9 years ago.
0

Finally I did a workout, a really ugly one, but functional.

I found out that, the Builder.php in the folder /vendor/laravel/framework/src/Illuminate/Database/Query does the update queries in the public function update (array $values){...

So in this function befor returning the $this-connection->update(...) i did my logic and works fine.

Now if a record updated, I look up my notification table and if there is any notification for that table that record, and the reference value is different than the updated value, I delet the notification.

I keep this thread unsolved, because this is not what I want, but now I can move to the next stage.

0

i dont think that is what he is looking for..

http://laravel.com/docs/5.1/database#listening-for-query-events is more appropriate...

0

This is exactly what I needed! You made my day shez1983!

Thanks for all guys, this is a great place for Laravel developers, I will come back regularly! :)

0

Sign in to participate in this thread!

Eventy

Your banner here too?

svolenszki svolenszki Joined 21 Oct 2015

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.