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,70 @@
<?php
namespace App\Models\ExameLaboratorial\Jornada;
use App\Models\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use App\Models\Cadastro\Estabelecimento\Unidade;
use App\Models\ExameLaboratorial\Jornada\TipoJornada;
use App\Models\Cadastro\Estabelecimento\Infraestrutura;
class Jornada extends Model
{
use SoftDeletes;
protected $table = 'exame_laboratorial_jornada';
protected $fillable = [
'unidade_id',
'infraestrutura_id',
'semana_id',
'tipo_id',
'vagas',
'vagas_app',
'laboratorio_prestador_infraestrutura_id',
'data',
'hora_inicial',
'hora_fim',
'tempo_atendimento',
];
protected $casts = [
'data' => 'datetime:d/m/Y',
];
protected $hidden = [
'created_lotacao_id',
'created_centro_custo_id',
'updated_at',
'updated_lotacao_id',
'updated_centro_custo_id',
'deleted_at',
'deleted_lotacao_id',
'deleted_centro_custo_id',
];
public function unidade()
{
return $this->belongsTo(Unidade::class);
}
public function infraestrutura()
{
return $this->belongsTo(Infraestrutura::class);
}
public function tipo()
{
return $this->belongsTo(TipoJornada::class);
}
public function laboratorioPrestadorInfraestrutura()
{
return $this->belongsTo(Infraestrutura::class, 'laboratorio_prestador_infraestrutura_id');
}
public function getIsAllowedToDeleteAttribute()
{
return true;
}
}

View File

@@ -0,0 +1,19 @@
<?php
namespace App\Models\ExameLaboratorial\Jornada;
use Illuminate\Database\Eloquent\Model;
class SemanaJornada extends Model
{
protected $table = 'exame_laboratorial_jornada_semana';
protected $fillable = [
'nome'
];
protected $hidden = [
'created_at',
'updated_at',
];
}

View File

@@ -0,0 +1,27 @@
<?php
namespace App\Models\ExameLaboratorial\Jornada;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Factories\HasFactory;
class TipoJornada extends Model
{
use HasFactory;
protected $table = 'exame_laboratorial_jornada_tipo';
protected $fillable = [
'nome'
];
protected $hidden = [
'created_at',
'updated_at',
];
public function jornadaExameLaboratorial()
{
return $this->hasMany(Jornada::class);
}
}