65 lines
1.5 KiB
PHP
65 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace App\Models\ExameLaboratorial\Parametrizacao;
|
|
|
|
use App\Models\Cadastro\Estabelecimento\Infraestrutura;
|
|
use App\Models\Cadastro\Estabelecimento\Unidade;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class CotaTransferencia extends Model
|
|
{
|
|
|
|
protected $table = 'exame_laboratorial_parametrizacao_cota_transferencia';
|
|
|
|
protected $fillable = [
|
|
'id',
|
|
'cota_id',
|
|
'laboratorio_unidade_id',
|
|
'laboratorio_infraestrutura_id',
|
|
'origem_unidade_id',
|
|
'origem_infraestrutura_id',
|
|
'origem_inicio',
|
|
'origem_fim',
|
|
'origem_cota_quantidade',
|
|
'origem_cota_valor',
|
|
'destino_unidade_id',
|
|
'destino_infraestrutura_id',
|
|
'destino_inicio',
|
|
'destino_fim',
|
|
'destino_cota_quantidade',
|
|
'destino_cota_valor',
|
|
'unidade_tipo_id',
|
|
'cota_tipo_id',
|
|
];
|
|
|
|
public function laboratorioUnidade()
|
|
{
|
|
return $this->belongsTo(Unidade::class);
|
|
}
|
|
|
|
public function laboratorioInfraestrutura()
|
|
{
|
|
return $this->belongsTo(Infraestrutura::class);
|
|
}
|
|
|
|
public function origemUnidade()
|
|
{
|
|
return $this->belongsTo(Unidade::class);
|
|
}
|
|
|
|
public function origemInfraestrutura()
|
|
{
|
|
return $this->belongsTo(Infraestrutura::class);
|
|
}
|
|
|
|
public function destinoUnidade()
|
|
{
|
|
return $this->belongsTo(Unidade::class);
|
|
}
|
|
|
|
public function destinoInfraestrutura()
|
|
{
|
|
return $this->belongsTo(Infraestrutura::class);
|
|
}
|
|
}
|