init commit
All checks were successful
build-api-image / build (push) Successful in 51s

This commit is contained in:
Antonio Lopes dos Santos
2026-08-04 16:52:02 -03:00
commit afec302c3e
11594 changed files with 1636728 additions and 0 deletions

View File

@@ -0,0 +1,94 @@
<?php
namespace App\Models\Farmacia\AltoCusto;
use App\Models\Cadastro\Estabelecimento\Unidade;
use App\Models\Cadastro\SujeitoAtencao\Paciente;
use App\Models\Cadastro\SujeitoAtencao\Usuario;
use App\Models\Cadastro\UnidadeMedida;
use App\Models\Model;
use App\Models\Sigtap\Cid;
class Processo extends Model
{
protected $table = 'farmacia_alto_custo_processo';
protected $casts = [
'solicitado_em' => 'datetime:d/m/Y',
];
protected $fillable = [
'paciente_id',
'peso',
'peso_unidade_medida_id',
'altura',
'altura_unidade_medida_id',
'tipo_id',
'subtipo_id',
'solicitado_em',
'unidade_solicitante_id',
'usuario_solicitante_id',
'cid_id',
'observacoes',
'observacoes_drs',
'processo_devolvido_em',
'motivo_processo_devolvido',
'medicamento_devolvido_em',
'motivo_medicamento_devolvido',
'numero_recebimento',
];
protected $hidden = [
'created_at',
'created_lotacao_id',
'created_centro_custo_id',
'updated_at',
'updated_lotacao_id',
'updated_centro_custo_id',
];
public function paciente()
{
return $this->belongsTo(Paciente::class);
}
public function pesoUnidadeMedida()
{
return $this->belongsTo(UnidadeMedida::class);
}
public function alturaUnidadeMedida()
{
return $this->belongsTo(UnidadeMedida::class);
}
public function tipo()
{
return $this->belongsTo(ProcessoTipo::class);
}
public function subtipo()
{
return $this->belongsTo(ProcessoSubtipo::class);
}
public function unidadeSolicitante()
{
return $this->belongsTo(Unidade::class);
}
public function usuarioSolicitante()
{
return $this->belongsTo(Usuario::class);
}
public function cid()
{
return $this->belongsTo(Cid::class);
}
public function itens()
{
return $this->hasMany(ProcessoItem::class);
}
}