Listen events on parent model with eloquent
<p>I have common class for all my models.</p>

<p>class Base extends Model;</p>

<p>class A extends Base;</p>

<p>class B extends Base;</p>

<p>I can listen <code>saving</code> on each model, <code>A::saving(callback()</code> but it does not seem to work to listen on Base. <code>Base::saving(callback)</code>.</p>

<pre><code>&lt;?php


class BaseModel extends \Illuminate\Database\Eloquent\Model
{


}


class A extends BaseModel
{
    protected $table = 'a';
}

class B extends BaseModel
{

    protected $table = 'b';
}


class BusinessLogicProvider extends \Illuminate\Support\ServiceProvider
{

    /**
     * Register the service provider.
     *
     * @return void
     */
    public function register()
    {
        A::updating(function () {
            //this fires
        });

        BaseModel::updating(function(){
            //this never fires
        });
    }
}
</code></pre>