-
Notifications
You must be signed in to change notification settings - Fork 232
Closed
Description
This is actually just a question.
I have created a Base Pivot Model which use laravel-model-caching like this:
<?php
namespace App;
use Illuminate\Database\Eloquent\Relations\Pivot;
use GeneaLabs\LaravelModelCaching\Traits\Cachable;
abstract class BasePivot extends Pivot
{
use Cachable;
}Then, from it I extend my Pivot Models.
<?php
namespace App;
use App\BasePivot;
class UserPermission extends BasePivot
{
//
}It seems that every time the Pivot Model is called in a relationship, data is not cached as seen from debugbar.
public function permissions()
{
return $this->belongsToMany('App\Permission')->using('App\UserPermission');
}What am I missing? Thanks.