This commit is contained in:
57
api/app/Models/TransportePaciente/Destino/Destino.php
Normal file
57
api/app/Models/TransportePaciente/Destino/Destino.php
Normal file
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models\TransportePaciente\Destino;
|
||||
|
||||
use App\Models\Cadastro\Localizacao\LogradouroTipo;
|
||||
use App\Models\Intranet\Municipio;
|
||||
use App\Models\Model;
|
||||
|
||||
class Destino extends Model
|
||||
{
|
||||
protected $table = 'transporte_paciente_destino';
|
||||
|
||||
protected $fillable = [
|
||||
'id',
|
||||
'descricao_destino',
|
||||
'numero_telefone_fax',
|
||||
'data_inclusao',
|
||||
'destino_tipo_id',
|
||||
'numero_cnpj',
|
||||
'numero_cpf',
|
||||
'nome_logradouro',
|
||||
'numero_logradouro',
|
||||
'nome_complemento',
|
||||
'nome_bairro',
|
||||
'numero_cep',
|
||||
'numero_telefone_comercial',
|
||||
'observacao',
|
||||
'cnes',
|
||||
'bloqueado',
|
||||
'tipo_prestador',
|
||||
'distancia',
|
||||
'cadastro_logradouro_tipo_id',
|
||||
'documento_tipo_id',
|
||||
'usuario_id',
|
||||
'estado_id',
|
||||
'municipio_id',
|
||||
];
|
||||
|
||||
protected $hidden = [
|
||||
'created_at',
|
||||
'created_lotacao_id',
|
||||
'created_centro_custo_id',
|
||||
'updated_at',
|
||||
'updated_lotacao_id',
|
||||
'updated_centro_custo_id',
|
||||
];
|
||||
|
||||
public function municipio()
|
||||
{
|
||||
return $this->belongsTo(Municipio::class);
|
||||
}
|
||||
|
||||
public function tipo()
|
||||
{
|
||||
return $this->belongsTo(LogradouroTipo::class, 'cadastro_logradouro_tipo_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user