This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
<table class="assinatura text-center {{ $props['class'] ?? '' }}" style="padding: {{ $props['height'] ?? '45' }}px 0 0 0;">
|
||||
<tr>
|
||||
<td></td>
|
||||
</tr>
|
||||
@foreach($data['info'] as $info)
|
||||
<tr><td class="font-small">{!! $info !!}</td></tr>
|
||||
@endforeach
|
||||
</table>
|
||||
199
api/resources/views/impressoes/components/campo.blade.php
Normal file
199
api/resources/views/impressoes/components/campo.blade.php
Normal file
@@ -0,0 +1,199 @@
|
||||
|
||||
<!--
|
||||
|
||||
[
|
||||
'props' => [
|
||||
'class' => ''
|
||||
],
|
||||
'data' => [
|
||||
'campos' => [
|
||||
[
|
||||
'label' => 'Nome',
|
||||
'value' => 'Décio Stenico'
|
||||
],
|
||||
[
|
||||
'label' => 'Nome',
|
||||
'value' => '',
|
||||
'value_class' => 'manual-line',
|
||||
],
|
||||
[
|
||||
'label' => 'Nome',
|
||||
'value' => '',
|
||||
'value_class' => 'manual-area',
|
||||
'value_style' => 'height: 100px',
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
]
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
],
|
||||
'options_outro' => 'Teste' // Label default: 'Outro'
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
],
|
||||
'options_outro' => '', // Label default: 'Outro'
|
||||
'options_outro_value_class' => 'manual-line',
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
],
|
||||
'options_outro' => [
|
||||
'label' => 'Outra',
|
||||
'value' => 'Teste'
|
||||
]
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
],
|
||||
'options_outro' => [
|
||||
'label' => 'Outra',
|
||||
'value' => '',
|
||||
'value_class' => 'manual-line',
|
||||
]
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Sexo',
|
||||
'value' => [
|
||||
'type' => 'radio',
|
||||
'options' => [
|
||||
['Masculino', true],
|
||||
['Feminino'],
|
||||
]
|
||||
],
|
||||
'class' => 'campo-option-inline'
|
||||
],
|
||||
[
|
||||
'label' => 'Comidas favoritas',
|
||||
'value' => [
|
||||
'type' => 'checkbox',
|
||||
'options' => [
|
||||
['Lasanha', true],
|
||||
['Feijoada', true],
|
||||
['Tofu']
|
||||
]
|
||||
],
|
||||
],
|
||||
[
|
||||
'label' => 'Comidas favoritas',
|
||||
'value' => [
|
||||
'type' => 'checkbox',
|
||||
'per_column' => 2,
|
||||
'options' => [
|
||||
['Lasanha', true],
|
||||
['Feijoada', true],
|
||||
['Tofu']
|
||||
]
|
||||
],
|
||||
],
|
||||
]
|
||||
]
|
||||
]
|
||||
|
||||
-->
|
||||
|
||||
<table class="campo grid {{ $props['class'] ?? '' }}" style="{{ $props['style'] ?? '' }}">
|
||||
<tr>
|
||||
@foreach($data['campos'] as $campo)
|
||||
<td class="{{ $campo['class'] ?? '' }}" style="{{ $campo['style'] ?? '' }}">
|
||||
<div class="label">
|
||||
<strong>{{ $campo['label'] ?? '' }}</strong>
|
||||
</div>
|
||||
|
||||
@if(is_array($campo['value']))
|
||||
@if(isset($campo['value']['per_column']))
|
||||
<table>
|
||||
<tr>
|
||||
@for($i = 0; $i < count($campo['value']['options']); $i++)
|
||||
@if($i === 0 || $i % $campo['value']['per_column'] === 0)
|
||||
<td>
|
||||
@endif
|
||||
|
||||
<div class="campo-option {{ $campo['value']['type'] }}">
|
||||
<div class="option {{ isset($campo['value']['options'][$i][1]) && $campo['value']['options'][$i][1] ? 'checked' : '' }}">
|
||||
<i></i> <span>{{ $campo['value']['options'][$i][0] }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@if($i === (count($campo['value']['options']) - 1) || ($i + 1) % $campo['value']['per_column'] === 0)
|
||||
</td>
|
||||
@endif
|
||||
@endfor
|
||||
</tr>
|
||||
</table>
|
||||
@else
|
||||
<div class="campo-option {{ $campo['value']['type'] }}">
|
||||
@foreach($campo['value']['options'] as $option)
|
||||
<div class="option {{ isset($option[1]) && $option[1] ? 'checked' : '' }}">
|
||||
<i></i> <span>{{ $option[0] }}</span>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if(isset($campo['value']['options_outro']))
|
||||
<table>
|
||||
<tr>
|
||||
@if(is_array($campo['value']['options_outro']))
|
||||
<td class="col-min">{{ $campo['value']['options_outro']['label'] }}:</td>
|
||||
<td>
|
||||
<div class="{{ $campo['value']['options_outro']['value_class'] ?? '' }}">
|
||||
{{ $campo['value']['options_outro']['value'] }}
|
||||
</div>
|
||||
</td>
|
||||
@else
|
||||
<td class="col-min">Outro:</td>
|
||||
<td>
|
||||
<div class="{{ $campo['value']['options_outro_value_class'] ?? '' }}">
|
||||
{{ $campo['value']['options_outro'] }}
|
||||
</div>
|
||||
</td>
|
||||
@endif
|
||||
</tr>
|
||||
</table>
|
||||
@endif
|
||||
@else
|
||||
<div class="value {{ $campo['value_class'] ?? '' }}" style="{{ $campo['value_style'] ?? '' }}">
|
||||
@if($campo['is_html'] ?? false)
|
||||
{!! $campo['value'] ?? '' !!}
|
||||
@else
|
||||
{{ $campo['value'] ?? '' }}
|
||||
@endif
|
||||
</div>
|
||||
@endif
|
||||
</td>
|
||||
@endforeach
|
||||
</tr>
|
||||
</table>
|
||||
@@ -0,0 +1 @@
|
||||
{{ strlen($texto) > ($limite ?? 65) ? substr($texto, 0, ($limite ?? 65)) : $texto }}
|
||||
@@ -0,0 +1,2 @@
|
||||
<span>{{ $nome }}@if(!empty($nomeSocial))@if($prefereNomeSocial) <strong>({{ $nomeSocial }})</strong>@else {{ "({$nomeSocial})" }}@endif
|
||||
@endif</span>
|
||||
25
api/resources/views/impressoes/components/paciente.blade.php
Normal file
25
api/resources/views/impressoes/components/paciente.blade.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<div id="paciente" class="fieldset {{ $props['class'] ?? '' }}">
|
||||
<div class="legend"><strong>Paciente</strong></div>
|
||||
<table class="grid">
|
||||
<tr>
|
||||
<td class="col-6"></td>
|
||||
<td class="col-6"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><strong>Prontuário {{ $data['paciente']['prontuario'] ?? '' }}</strong></td>
|
||||
<td>Data do atendimento: {{ $data['paciente']['data_atendimento'] ?? '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Nome: {{ $data['paciente']['nome'] ?? '' }}</td>
|
||||
<td>Sexo: {{ $data['paciente']['sexo'] ?? '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Data de nascimento: {{ $data['paciente']['data_nascimento'] ?? '' }}</td>
|
||||
<td>Idade: {{ $data['paciente']['idade'] ?? '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>CNS: {{ $data['paciente']['cns'] ?? '' }}</td>
|
||||
<td>CPF: {{ $data['paciente']['cpf'] ?? '' }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
@@ -0,0 +1,37 @@
|
||||
<div class="area {{ $props['class'] ?? '' }}">
|
||||
<div class="area">
|
||||
@foreach($data['filtro'] as $row)
|
||||
<table class="grid">
|
||||
<tr>
|
||||
@foreach($row as $col)
|
||||
<td class="{{ $col[2] ?? '' }}">
|
||||
<div><strong>{{ $col[0] }}:</strong></div>
|
||||
<div>{{ $col[1] }}</div>
|
||||
</td>
|
||||
@endforeach
|
||||
</tr>
|
||||
</table>
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
<div class="area pt-0">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
@foreach($data['resultado']['thead'] as $col)
|
||||
<th class="{{ is_array($col) ? $col[1] : '' }}">{{ is_array($col) ? $col[0] : $col }}</th>
|
||||
@endforeach
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($data['resultado']['tbody'] as $row)
|
||||
<tr>
|
||||
@foreach($row as $col)
|
||||
<td class="{{ is_array($col) ? $col[1] : '' }}">{{ is_array($col) ? $col[0] : $col }}</td>
|
||||
@endforeach
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user