up
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Ajuste extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'referencia_type',
|
||||
'referencia_id',
|
||||
'user_id',
|
||||
'tipo',
|
||||
'cantidad',
|
||||
'notas',
|
||||
];
|
||||
|
||||
public function referencia()
|
||||
{
|
||||
return $this->morphTo();
|
||||
}
|
||||
|
||||
public function usuario()
|
||||
{
|
||||
return $this->belongsTo(User::class, 'user_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user