Commit 1abc2526 authored by alissonalbuquerque's avatar alissonalbuquerque
Browse files

Merge branch 'anexoB'

parents a50a5b26 4f3b5fc0
...@@ -36,7 +36,7 @@ class GestaoMembroComissaoController extends Controller ...@@ -36,7 +36,7 @@ class GestaoMembroComissaoController extends Controller
} }
public function create(Request $request) public function create(Request $request)
{ {
$planejamento = Planejamento::initQuery()->whereCodDimensao('G-1')->first(); $planejamento = Planejamento::initQuery()->whereCodDimensao('G-1')->first();
$ch_min = $planejamento->ch_semanal; $ch_min = $planejamento->ch_semanal;
...@@ -67,7 +67,7 @@ class GestaoMembroComissaoController extends Controller ...@@ -67,7 +67,7 @@ class GestaoMembroComissaoController extends Controller
{ {
$avaliacao = new Avaliacao([ $avaliacao = new Avaliacao([
'tarefa_id' => $model->id, 'tarefa_id' => $model->id,
'type' => UtilAvaliacao::ENSINO_AULA, 'type' => UtilAvaliacao::GESTAO_MEMBRO_COMISSAO,
'status' => Status::PENDENTE, 'status' => Status::PENDENTE,
]); ]);
......
...@@ -463,6 +463,23 @@ class PadController extends Controller ...@@ -463,6 +463,23 @@ class PadController extends Controller
$avaliacoes_ensino = Avaliacao::whereIn('id', $avaliacoes_ensino_ids)->orderBy('status'); $avaliacoes_ensino = Avaliacao::whereIn('id', $avaliacoes_ensino_ids)->orderBy('status');
// //
//- - - Correção - - -
$tarefaIds = Avaliacao::whereType(AvaliacaoUtil::ENSINO_AULA)->get()->map(function($model) {
return $model->tarefa_id;
});
foreach($tarefaIds as $tarefaId)
{
$avas = Avaliacao::whereType(AvaliacaoUtil::ENSINO_AULA)->whereTarefaId($tarefaId)->get();
if(count($avas) == 2) {
$ava = Avaliacao::whereType(AvaliacaoUtil::ENSINO_AULA)->whereTarefaId($tarefaId)->first();
$ava->type = 23;
$ava->save();
}
}
//- - - Correção - - -
} }
if (in_array(Dimensao::PESQUISA, $dimensoes)) { if (in_array(Dimensao::PESQUISA, $dimensoes)) {
......
...@@ -158,15 +158,3 @@ class Avaliacao extends Model ...@@ -158,15 +158,3 @@ class Avaliacao extends Model
return Status::listStatus($this->status); return Status::listStatus($this->status);
} }
} }
/**
*
*
*
*
*
*
*
*
*/
\ No newline at end of file
...@@ -32,5 +32,4 @@ class Avaliacao ...@@ -32,5 +32,4 @@ class Avaliacao
CONST GESTAO_REPRESENTANTE_UNIDADE_EDUCACAO = 22; CONST GESTAO_REPRESENTANTE_UNIDADE_EDUCACAO = 22;
CONST GESTAO_MEMBRO_COMISSAO = 23; CONST GESTAO_MEMBRO_COMISSAO = 23;
CONST GESTAO_OUTROS = 24; CONST GESTAO_OUTROS = 24;
}
}
\ No newline at end of file
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AlterAnexoRemakeTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::dropIfExists('anexo_b');
Schema::create('anexo_b', function (Blueprint $table) {
$table->id();
$table->foreignId('user_pad_id');
$table->foreignId('campus_id')->nullable();
$table->foreignId('curso_id')->nullable();
$table->tinyInteger('semestre')->nullable();
$table->string('matricula')->nullable();
$table->time('carga_horaria')->nullable();
$table->tinyInteger('categoria_nivel')->nullable();
$table->boolean('afastamento_total')->nullable();
$table->string('afastamento_total_desc')->nullable();
$table->boolean('afastamento_parcial')->nullable();
$table->string('afastamento_parcial_desc')->nullable();
$table->boolean('direcao_sindical')->nullable();
$table->string('licenca')->nullable();
$table->timestamps();
$table->softDeletes();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('anexo_b');
}
}
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
</h3> </h3>
</div> </div>
<div class="d-flex"> <div class="d-flex">
@foreach($userPads as $userPad) @foreach($userPads as $userPad)
@if($userPad->pad->status === Status::ATIVO) @if($userPad->pad->status === Status::ATIVO)
<div class="card mx-2" style="width: 12rem;"> <div class="card mx-2" style="width: 12rem;">
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
<div class="col-sm-4"> <div class="col-sm-4">
<div class="mb-3"> <div class="mb-3">
<label for="matricula"> MATRÍCULA </label> <label for="matricula"> MATRÍCULA </label>
<input type="text" id="matricula" name="matricula" class="form-control" value=""> <input type="text" id="matricula" name="matricula" class="form-control" value="" disabled>
</div> </div>
</div> </div>
...@@ -145,21 +145,20 @@ ...@@ -145,21 +145,20 @@
$('#document').mask('###.###.###-##') $('#document').mask('###.###.###-##')
$('#carga_horaria').mask('') $('#carga_horaria').mask('000:00');
$('#carga_horaria').keypress(() => {
$('#carga_horaria').mask('')
})
//Config : select2 //Config : select2
$('#campus_id').select2( $('#campus_id').select2(
{ {
placeholder: 'Unidade - Campus', placeholder: 'Unidade - Campus',
allowClear: true, allowClear: true,
ajax: { ajax: {
url: '{{ route("campus_search") }}', url: '{{ route("campus_search") }}',
dataType: 'json' dataType: 'json'
} }
}).on('change', () => {
$('#curso_id').empty()
}); });
$('#curso_id').select2( $('#curso_id').select2(
......
...@@ -67,23 +67,14 @@ ...@@ -67,23 +67,14 @@
</div> </div>
</div> </div>
</div> {{-- <div class="card mx-2" style="width: 10rem;">
<div class="mx-2">
<div class="mb-3">
<!-- <h3 class="h3"> ANEXOS </h3> -->
</div>
</div>
<div class="d-flex my-2">
<!-- <div class="card mx-2" style="width: 10rem;">
<div class="card-body"> <div class="card-body">
<h2 class="text-center"> <i class="bi bi-file-earmark-text-fill"></i> </h2> <h2 class="text-center"> <i class="bi bi-file-earmark-text-fill"></i> </h2>
<h3 class="text-center"> Anexo B </h3> <h3 class="text-center"> Anexo B </h3>
<a class="stretched-link" href="{{-- route('') --}}" class="btn-pad-dimensao"></a> <a class="stretched-link" href="{{ route('edit_anexo', ['user_pad_id' => $user_pad_id]) }}" class="btn-pad-dimensao"></a>
</div> </div>
</div> --> </div> --}}
</div> </div>
@endsection @endsection
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment