diff --git a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoAtendimentoDiscenteController.php b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoAtendimentoDiscenteController.php index 731fc47e7e1c03fda945bcac58a773c29f280f4e..4b55782577e5ad3e94329e712001ab08165c9227 100644 --- a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoAtendimentoDiscenteController.php +++ b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoAtendimentoDiscenteController.php @@ -88,7 +88,7 @@ class EnsinoAtendimentoDiscenteController extends Controller if($validator->fails()) { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $request->user_pad_id,]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $request->user_pad_id,]) ->withErrors($validator) ->withInput(); } @@ -109,16 +109,16 @@ class EnsinoAtendimentoDiscenteController extends Controller if(!$avaliacao->save()) { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao cadastrar Atividade!'); } return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('success', 'Cadastro realizado com sucesso!'); } else { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao cadastrar Atividade!'); } @@ -147,15 +147,15 @@ class EnsinoAtendimentoDiscenteController extends Controller if($validator->fails()) { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao atualizar Atividade!'); } if($model->save()) { - return redirect()->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + return redirect()->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('success', 'Atualizado com sucesso!'); } else { - return redirect()->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + return redirect()->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao atualizar a Atividade!'); } } @@ -168,11 +168,11 @@ class EnsinoAtendimentoDiscenteController extends Controller if($model->delete()) { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('success', 'Atividade removida com Sucesso!'); } else { return redirect() - ->route('atendimento_discente_index', ['user_pad_id' => $user_pad_id]) + ->route('ensino_atendimento_discente_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao remover atividade!'); } } diff --git a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoOrientacaoController.php b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoOrientacaoController.php index 24be859b65cdcfce0f554ab36564762e6aa41b1d..9244b7324b938a657a27cd228842f2aeb8baadda 100644 --- a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoOrientacaoController.php +++ b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoOrientacaoController.php @@ -54,7 +54,7 @@ class EnsinoOrientacaoController extends Controller $orientacoes = Orientacao::listOrientacao(); $planejamentos = EnsinoOrientacao::listPlanejamentos(); - return view('pad.components.templates.dimensao.ensino.aulas.form_update', [ + return view('pad.components.templates.dimensao.ensino.orientacao.form_update', [ 'model' => $model, 'niveis' => $niveis, 'orientacoes' => $orientacoes, @@ -75,6 +75,8 @@ class EnsinoOrientacaoController extends Controller */ public function create(Request $request) { + $ch_semanal_temp = $request->ch_semanal; + if($request->cod_dimensao) { $planejamento = Planejamento::initQuery()->whereCodDimensao($request->cod_dimensao)->first(); @@ -82,10 +84,12 @@ class EnsinoOrientacaoController extends Controller $ch_min = $planejamento->ch_semanal; $ch_max = $planejamento->ch_maxima; - $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max); + $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max, ['field' => 'Qtd. Participantes', 'value' => $request->numero_orientandos]); + + $request->merge(['ch_semanal' => $request->ch_semanal * ($request->numero_orientandos?? 1)]); $validator = Validator::make( - $request->all(), + $request->all(), array_merge(EnsinoOrientacao::rules(), $cargaHoraria->rules()), array_merge(EnsinoOrientacao::messages(), $cargaHoraria->messages()) ); @@ -99,6 +103,7 @@ class EnsinoOrientacaoController extends Controller if($validator->fails()) { + $request->merge(['ch_semanal' => $ch_semanal_temp]); return redirect() ->route('ensino_orientacao_index', ['user_pad_id' => $request->user_pad_id,]) ->withErrors($validator) @@ -106,12 +111,13 @@ class EnsinoOrientacaoController extends Controller } $user_pad_id = $request->user_pad_id; + $request->merge(['ch_semanal' => $ch_semanal_temp]); $model = new EnsinoOrientacao($request->all()); $model->dimensao = Dimensao::ENSINO; if($model->save()) - { + { $avaliacao = new Avaliacao([ 'tarefa_id' => $model->id, 'type' => UtilAvaliacao::ENSINO_ORIENTACAO, @@ -137,7 +143,11 @@ class EnsinoOrientacaoController extends Controller } public function update($id, Request $request) - { + { + $model = EnsinoOrientacao::find($id); + + $ch_semanal_temp = $request->ch_semanal; + if($request->cod_dimensao) { $planejamento = Planejamento::initQuery()->whereCodDimensao($request->cod_dimensao)->first(); @@ -145,10 +155,12 @@ class EnsinoOrientacaoController extends Controller $ch_min = $planejamento->ch_semanal; $ch_max = $planejamento->ch_maxima; - $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max); + $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max, ['field' => 'Qtd. Participantes', 'value' => $request->numero_orientandos]); + + $request->merge(['ch_semanal' => $request->ch_semanal * ($request->numero_orientandos?? 1)]); $validator = Validator::make( - $request->all(), + $request->all(), array_merge(EnsinoOrientacao::rules(), $cargaHoraria->rules()), array_merge(EnsinoOrientacao::messages(), $cargaHoraria->messages()) ); @@ -160,18 +172,19 @@ class EnsinoOrientacaoController extends Controller ); } - $model = EnsinoOrientacao::find($id); - $model->fill($request->all()); - $user_pad_id = $model->user_pad_id; if($validator->fails()) { + $request->merge(['ch_semanal' => $ch_semanal_temp]); return redirect() ->route('ensino_orientacao_index', ['user_pad_id' => $user_pad_id]) ->with('fail', 'Erro ao atualizar Atividade!'); } + $request->merge(['ch_semanal' => $ch_semanal_temp]); + $model->fill($request->all()); + if($model->save()) { return redirect()->route('ensino_orientacao_index', ['user_pad_id' => $user_pad_id]) ->with('success', 'Atualizado com sucesso!'); @@ -211,6 +224,8 @@ class EnsinoOrientacaoController extends Controller public function ajaxValidation(Request $request) { + $ch_semanal_temp = $request->ch_semanal; + if($request->cod_dimensao) { $planejamento = Planejamento::initQuery()->whereCodDimensao($request->cod_dimensao)->first(); @@ -218,10 +233,12 @@ class EnsinoOrientacaoController extends Controller $ch_min = $planejamento->ch_semanal; $ch_max = $planejamento->ch_maxima; - $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max); + $cargaHoraria = new CargaHorariaValidation($ch_min, $ch_max, ['field' => 'Qtd. Participantes', 'value' => $request->numero_orientandos]); + + $request->merge(['ch_semanal' => $request->ch_semanal * ($request->numero_orientandos?? 1)]); $validator = Validator::make( - $request->all(), + $request->all(), array_merge(EnsinoOrientacao::rules(), $cargaHoraria->rules()), array_merge(EnsinoOrientacao::messages(), $cargaHoraria->messages()) ); @@ -234,6 +251,7 @@ class EnsinoOrientacaoController extends Controller } if($validator->passes()) { + $request->merge(['ch_semanal' => $ch_semanal_temp]); return Response::json(['message' => true, 'status' => 200]); } diff --git a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoParticipacaoController.php b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoParticipacaoController.php index 706c8e8972eed5cde78b0f381e4923fad1b64801..0a521ee708a86cdce79621cabe8b6cd842c19ed2 100644 --- a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoParticipacaoController.php +++ b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoParticipacaoController.php @@ -32,7 +32,6 @@ class EnsinoParticipacaoController extends Controller $niveis = Nivel::listNivel(); - $modalidades = Modalidade::listModalidade(); $divs = PadTables::tablesEnsino($user_pad_id); return view('pad.components.templates.dimensao.ensino.participacao.form_create', [ @@ -40,7 +39,6 @@ class EnsinoParticipacaoController extends Controller 'divs' => $divs, 'niveis' => $niveis, - 'modalidades' => $modalidades, 'user_pad_id' => $user_pad_id, 'index_menu' => MenuItemsTeacher::PAD, ]); diff --git a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoProjetoController.php b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoProjetoController.php index cd82c461d55481dc24bcb8e7cbf7b1c7f70b8aae..b8cd4690b6b7f30967bb27aab19e5238239d3392 100644 --- a/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoProjetoController.php +++ b/app/Http/Controllers/Dimensao/Tabelas/Ensino/EnsinoProjetoController.php @@ -11,8 +11,10 @@ use App\Models\UserPad; use App\Models\Util\Avaliacao as UtilAvaliacao; use App\Models\Util\CargaHorariaValidation; use App\Models\Util\Dimensao; +use App\Models\Util\Funcao; use App\Models\Util\MenuItemsTeacher; use App\Models\Util\Modalidade; +use App\Models\Util\Natureza; use App\Models\Util\Nivel; use App\Models\Util\PadTables; use App\Models\Util\Status; @@ -30,32 +32,31 @@ class EnsinoProjetoController extends Controller ->orderBy('cod_atividade') ->get(); - - $niveis = Nivel::listNivel(); - $modalidades = Modalidade::listModalidade(); + $naturezas = Natureza::listNatureza(); + $funcoes = Funcao::listFuncaoProjeto(); $divs = PadTables::tablesEnsino($user_pad_id); return view('pad.components.templates.dimensao.ensino.projeto.form_create', [ 'atividades' => $atividades, 'divs' => $divs, - 'niveis' => $niveis, - 'modalidades' => $modalidades, + 'funcoes' => $funcoes, + 'naturezas' => $naturezas, 'user_pad_id' => $user_pad_id, 'index_menu' => MenuItemsTeacher::PAD, ]); } - public function edit($id) { - + public function edit($id) + { $model = EnsinoProjeto::find($id); - $niveis = Nivel::listNivel(); - $modalidades = Modalidade::listModalidade(); + $naturezas = Natureza::listNatureza(); + $funcoes = Funcao::listFuncaoProjeto(); return view('pad.components.templates.dimensao.ensino.projeto.form_update', [ 'model' => $model, - 'niveis' => $niveis, - 'modalidades' => $modalidades + 'funcoes' => $funcoes, + 'naturezas' => $naturezas, ]); } diff --git a/app/Models/Tabelas/Ensino/EnsinoAtendimentoDiscente.php b/app/Models/Tabelas/Ensino/EnsinoAtendimentoDiscente.php index fed4af101bb8e79587aed197f861ec64a9e3eaa8..c24fc3ed5d09aa58ffdf3309959b7314ff8cccce 100644 --- a/app/Models/Tabelas/Ensino/EnsinoAtendimentoDiscente.php +++ b/app/Models/Tabelas/Ensino/EnsinoAtendimentoDiscente.php @@ -26,6 +26,11 @@ class EnsinoAtendimentoDiscente extends Model */ protected $fillable = ['orientacao_id', 'user_pad_id', 'dimensao', 'cod_atividade', 'componente_curricular', 'curso', 'nivel', 'ch_semanal']; + public function nivelAsString() + { + return Nivel::listNivel($this->nivel); + } + public static function rules() { return [ diff --git a/app/Models/Tabelas/Ensino/EnsinoOrientacao.php b/app/Models/Tabelas/Ensino/EnsinoOrientacao.php index 376eea5c44609626df5337608ef7ccb15d0c68ef..c932cff34f3582a2fa4b703fcef0d595a498561f 100644 --- a/app/Models/Tabelas/Ensino/EnsinoOrientacao.php +++ b/app/Models/Tabelas/Ensino/EnsinoOrientacao.php @@ -23,7 +23,25 @@ class EnsinoOrientacao extends Model * * @var array */ - protected $fillable = ['orientacao_id', 'cod_dimensao', 'user_pad_id', 'dimensao', 'cod_atividade', 'atividade', 'curso_id', 'nivel', 'type_orientacao', 'numero_orientandos', 'ch_semanal', 'pad_id']; + protected $fillable = ['orientacao_id', 'cod_dimensao', 'user_pad_id', 'dimensao', 'cod_atividade', 'atividade', 'curso', 'nivel', 'type_orientacao', 'numero_orientandos', 'ch_semanal', 'pad_id']; + + /** @return string */ + public function nivelAsString() + { + return Nivel::listNivel($this->nivel); + } + + /** @return string */ + public function orientacaoAsString() + { + return Orientacao::listOrientacao($this->type_orientacao); + } + + /** @return string */ + public function chSemanal() + { + return sprintf('%s (x%s)', $this->ch_semanal, $this->numero_orientandos); + } /** * @return array @@ -36,7 +54,7 @@ class EnsinoOrientacao extends Model 'curso' => ['required', 'string', 'max:255'], 'nivel' => ['required', 'integer', Rule::in(array_keys(Nivel::listNivel()))], 'type_orientacao' => ['required', 'integer', Rule::in(array_keys(Orientacao::listOrientacao()))], - 'numero_orientandos' => ['integer'], + 'numero_orientandos' => ['required', 'integer', 'min:1'], 'cod_dimensao' => ['required', 'string', Rule::in(array_keys(self::listPlanejamentos()))], ]; } @@ -67,7 +85,9 @@ class EnsinoOrientacao extends Model 'type_orientacao.integer' => 'O campo "Orientação" deve cónter um inteiro!', //'numero_orientandos' - 'numero_orientandos' => 'O campo "Número de Orientandos" deve cónter um inteiro!', + 'numero_orientandos.required' => 'O campo "Qtd. Participantes" é obrigatório!', + 'numero_orientandos.integer' => 'O campo "Qtd. Participantes" deve cónter um inteiro!', + 'numero_orientandos.min' => 'O valor minímo de "Qtd. Participantes" é 1 (um) participante', //'cod_dimensao' 'cod_dimensao.required' => 'O campo "Resolução" é obrigatório', diff --git a/app/Models/Tabelas/Ensino/EnsinoParticipacao.php b/app/Models/Tabelas/Ensino/EnsinoParticipacao.php index 5a9dc05b511b3dfd549dfc8be8ab1d62f7c9393c..36fc1c639751019c38312e526c09fc8cabc91cff 100644 --- a/app/Models/Tabelas/Ensino/EnsinoParticipacao.php +++ b/app/Models/Tabelas/Ensino/EnsinoParticipacao.php @@ -24,6 +24,13 @@ class EnsinoParticipacao extends Model */ protected $fillable = ['orientacao_id', 'user_pad_id', 'dimensao', 'cod_atividade', 'curso', 'nivel', 'ch_semanal']; + + /** @return string|array */ + public function nivelAsString() + { + return Nivel::listNivel($this->nivel); + } + public static function rules() { return [ @@ -40,12 +47,12 @@ class EnsinoParticipacao extends Model 'cod_atividade.required' => 'O campo "Cod. Atividade" é obrigatório!', //curso - 'curso.required' => 'O campo "Curso" é obrigatório!', + 'curso.required' => 'O campo "Nome do Curso" é obrigatório!', //nivel - 'nivel.required' => 'O campo "Nível" é obrigatório!', - 'nivel.in' => 'Selecione uma opção da lista de "Nível"!', - 'nivel.integer' => 'O campo "Nível" deve cónter um inteiro!', + 'nivel.required' => 'O campo "Nível do Curso" é obrigatório!', + 'nivel.in' => 'Selecione uma opção da lista de "Nível do Curso"!', + 'nivel.integer' => 'O campo "Nível do Curso" deve cónter um inteiro!', ]; } diff --git a/app/Models/Tabelas/Ensino/EnsinoProjeto.php b/app/Models/Tabelas/Ensino/EnsinoProjeto.php index 33935488e536f76f329d9b90079b7c700107ea88..4b05f756d798a547c565da2dedce349a3583853e 100644 --- a/app/Models/Tabelas/Ensino/EnsinoProjeto.php +++ b/app/Models/Tabelas/Ensino/EnsinoProjeto.php @@ -25,6 +25,18 @@ class EnsinoProjeto extends Model */ protected $fillable = ['orientacao_id', 'user_pad_id', 'dimensao', 'cod_atividade', 'titulo', 'curso', 'natureza', 'funcao', 'ch_semanal']; + /** @return string|array */ + public function naturezaAsString() + { + return Natureza::listNatureza($this->natureza); + } + + /** @return string|array */ + public function funcaoAsString() + { + return Funcao::listFuncaoProjeto($this->funcao); + } + public static function rules() { return [ @@ -43,7 +55,7 @@ class EnsinoProjeto extends Model 'cod_atividade.required' => 'O campo "Cod. Atividade" é obrigatório!', //titulo - 'titulo.required' => 'O campo "Componente Curricular" é obrigatório!', + 'titulo.required' => 'O campo "Título do Projeto" é obrigatório!', //curso 'curso.required' => 'O campo "Curso" é obrigatório!', diff --git a/app/Models/Util/CargaHorariaValidation.php b/app/Models/Util/CargaHorariaValidation.php index c69f328bec217b39180cdce8021a028741c2d82b..5b40e4a123c4946d91be054d2613e2a5b321850c 100644 --- a/app/Models/Util/CargaHorariaValidation.php +++ b/app/Models/Util/CargaHorariaValidation.php @@ -13,10 +13,14 @@ class CargaHorariaValidation /** @var integer|null */ public $ch_max; - public function __construct($ch_min, $ch_max) + /** @var array */ + public $multiplier; + + public function __construct($ch_min, $ch_max, $multiplier = []) { $this->ch_min = $ch_min; $this->ch_max = $ch_max; + $this->multiplier = $multiplier; } public function rules() @@ -35,6 +39,11 @@ class CargaHorariaValidation $ch_min = $this->ch_min !== null && $this->ch_min > 1 ? sprintf('"CH. Semanal" miníma é de %d Hora(s)!', $this->ch_min) : '"CH. Semanal" miníma é de 1 Hora(s)!'; $ch_max = $this->ch_max !== null ? sprintf('"CH. Semanal" máxima para o preenchimento é de %d Hora(s)!', $this->ch_max) : ''; + + if($this->ch_max !== null && isset($this->multiplier['value']) && (integer) $this->multiplier['value'] > 1) + { + $ch_max = sprintf('"CH. Semanal" máxima para o preenchimento é de %d Hora(s)! Valor multiplicado pelo campo "%s" está acima da "CH. Semanal" máxima!', $this->ch_max, $this->multiplier['field']); + } return [ 'ch_semanal.required' => 'O campo "CH. Semanal" é obrigatório!', diff --git a/app/Models/Util/Orientacao.php b/app/Models/Util/Orientacao.php index af7440117aa6daa4ad0aedb3d10529af0778d6e0..1dafa9a432bba01baacef0c2bb832533b6df5a75 100644 --- a/app/Models/Util/Orientacao.php +++ b/app/Models/Util/Orientacao.php @@ -2,7 +2,6 @@ namespace App\Models\Util; - class Orientacao { const GRUPO = 1; diff --git a/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_create.blade.php b/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_create.blade.php index 3e3e1ecf575c06ec2a872a537a6fecdb70290556..1c2c268b695bb6810f322a09207b5fd5c3147ff7 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_create.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_create.blade.php @@ -42,6 +42,50 @@ +
+ + + + @include('components.divs.errors', [ + 'field' => 'componente_curricular_create', + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'nivel_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_create' + ]) +
@@ -61,6 +105,10 @@ Cód + Componente Curricular + Curso + Nível + CH. Semanal @@ -68,6 +116,10 @@ @foreach($atividades as $atividade) {{ $atividade->cod_atividade }} + {{ $atividade->componente_curricular }} + {{ $atividade->curso }} + {{ $atividade->nivelAsString() }} + {{ $atividade->ch_semanal }} @include('components.buttons.btn-edit-task', [ 'btn_class' => 'btn-edit_ensino_atendimento_discente', @@ -76,7 +128,7 @@ @include('components.buttons.btn-delete', [ 'id' => $atividade->id, - 'route' => route('ensino_atendimento_discente_delete', ['id' => $ensinoAula->id]) + 'route' => route('ensino_atendimento_discente_delete', ['id' => $atividade->id]) ]) diff --git a/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_update.blade.php b/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_update.blade.php index 823628acc519394f590fbd2a78ea350b22b6f9d9..380eb19b187a83f421a164ef238b6ca1d650d534 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_update.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/atendimento_discente/form_update.blade.php @@ -14,6 +14,51 @@
+
+ + + + @include('components.divs.errors', [ + 'field' => 'componente_curricular_create', + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'nivel_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_create' + ]) +
+
diff --git a/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_create.blade.php b/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_create.blade.php index 18548987ce6a95a788ae97dc2a4cd3b1f93e0aec..2f8d96a1e5ac90e9c406c7e6782e5845ff42244a 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_create.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_create.blade.php @@ -60,7 +60,7 @@ ])
-
+
@@ -95,6 +95,16 @@ 'field' => 'type_orientacao_create' ])
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'numero_orientandos_create' + ]) +
+
@@ -113,7 +123,7 @@ 'field' => 'cod_dimensao_create' ])
- +
@@ -122,6 +132,7 @@ 'field' => 'ch_semanal_create' ])
+
@@ -158,7 +169,7 @@ {{ $ensinoOrientacao->curso }} {{ $ensinoOrientacao->nivelAsString() }} {{ $ensinoOrientacao->orientacaoAsString() }} - {{ $ensinoOrientacao->ch_semanal }} + {{ $ensinoOrientacao->chSemanal() }} @include('components.buttons.btn-edit-task', [ 'btn_class' => 'btn-edit_ensino_orientacao', @@ -214,4 +225,7 @@ 'route' => route('view_ensino_orientacao_resolucao'), 'btn_class' => 'show_resolucao', ]) + + @include('pad.components.templates.dimensao.ensino.orientacao.numero_orientandos', ['form_id' => 'ensino_orientacao-form']) + @endsection diff --git a/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_update.blade.php b/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_update.blade.php index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d1abb1b238467aaf69022829fab6a3f2e2f52f37 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_update.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/orientacao/form_update.blade.php @@ -0,0 +1,133 @@ + +
+
+
+

Ensino - Orientações

+
+
+ @csrf + +
+ +
+ + +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'atividade_update', + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'nivel_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'type_orientacao_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'numero_orientandos_update' + ]) +
+ + +
+ + + + @include('components.divs.errors', [ + 'field' => 'cod_dimensao_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_update' + ]) +
+ +
+ +
+ +
+ +
+
+ +
+ +@include('pad.components.scripts.ajaxValidation', [ + 'btn_submit_id' => 'btn-submit_ensino_orientacao-update', + 'form_id' => 'ensino_orientacao_update-form', + 'form_type' => 'update', + 'route' => route('ensino_orientacao_validate'), +]) + +@include('pad.components.templates.dimensao.ensino.orientacao.numero_orientandos', ['form_id' => 'ensino_orientacao_update-form']) diff --git a/resources/views/pad/components/templates/dimensao/ensino/orientacao/numero_orientandos.blade.php b/resources/views/pad/components/templates/dimensao/ensino/orientacao/numero_orientandos.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..6593e91b95d10d7652b1c7c2f27adba6261757c6 --- /dev/null +++ b/resources/views/pad/components/templates/dimensao/ensino/orientacao/numero_orientandos.blade.php @@ -0,0 +1,28 @@ +{{-- + @include('pad.components.templates.dimensao.ensino.orientacao.numero_orientandos', ['form_id' = '']) +--}} + +@php + use App\Models\Util\Orientacao; + + $orientacao_grupo = Orientacao::GRUPO; +@endphp + + \ No newline at end of file diff --git a/resources/views/pad/components/templates/dimensao/ensino/participacao/form_create.blade.php b/resources/views/pad/components/templates/dimensao/ensino/participacao/form_create.blade.php index 179767238d8ab623b62fecfae00f9813f026745d..05411ee604bf755a7127af9f52b99cc66c6f9471 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/participacao/form_create.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/participacao/form_create.blade.php @@ -42,6 +42,42 @@
+
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'nivel_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_create' + ]) +
+
@@ -61,6 +97,9 @@ Cód + Nome do Curso + Nível do Curso + CH. Semanal @@ -68,6 +107,9 @@ @foreach($atividades as $atividade) {{ $atividade->cod_atividade }} + {{ $atividade->curso }} + {{ $atividade->nivelAsString() }} + {{ $atividade->ch_semanal }} @include('components.buttons.btn-edit-task', [ 'btn_class' => 'btn-edit_ensino_participacao', @@ -76,7 +118,7 @@ @include('components.buttons.btn-delete', [ 'id' => $atividade->id, - 'route' => route('ensino_participacao_delete', ['id' => $ensinoAula->id]) + 'route' => route('ensino_participacao_delete', ['id' => $atividade->id]) ]) @@ -89,7 +131,7 @@ @include('components.modal', [ 'size' => 'modal-lg', - 'header' => 'Ensino - Membro Participação', + 'header' => '', ])
@endsection diff --git a/resources/views/pad/components/templates/dimensao/ensino/participacao/form_update.blade.php b/resources/views/pad/components/templates/dimensao/ensino/participacao/form_update.blade.php index 6e7e5d7c8fee9aaad42980fcadae87b0c0ee0a72..c3ff670c773a7ef7ef7193c602b0929f3184808e 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/participacao/form_update.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/participacao/form_update.blade.php @@ -14,6 +14,41 @@ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'nivel_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_update' + ]) +
diff --git a/resources/views/pad/components/templates/dimensao/ensino/projeto/form_create.blade.php b/resources/views/pad/components/templates/dimensao/ensino/projeto/form_create.blade.php index 80cfc4fd22a83d7b50dadda92586c6277ecd425a..1bf6ff12f41466726290bd4012468b9250b7388a 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/projeto/form_create.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/projeto/form_create.blade.php @@ -42,6 +42,68 @@
+
+ + + + @include('components.divs.errors', [ + 'field' => 'titulo_create', + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'natureza_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'funcao_create' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_create' + ]) +
@@ -60,7 +122,12 @@ - Cód + Cód ´ + Título do Projeto + Curso + Natureza + Função + CH. Semanal @@ -68,6 +135,11 @@ @foreach($atividades as $atividade) {{ $atividade->cod_atividade }} + {{ $atividade->titulo }} + {{ $atividade->curso }} + {{ $atividade->naturezaAsString() }} + {{ $atividade->funcaoAsString() }} + {{ $atividade->ch_semanal }} @include('components.buttons.btn-edit-task', [ 'btn_class' => 'btn-edit_ensino_projeto', @@ -76,7 +148,7 @@ @include('components.buttons.btn-delete', [ 'id' => $atividade->id, - 'route' => route('ensino_projeto_delete', ['id' => $ensinoAula->id]) + 'route' => route('ensino_projeto_delete', ['id' => $atividade->id]) ]) @@ -89,7 +161,7 @@ @include('components.modal', [ 'size' => 'modal-lg', - 'header' => 'Ensino - Projeto', + 'header' => '', ])
@endsection diff --git a/resources/views/pad/components/templates/dimensao/ensino/projeto/form_update.blade.php b/resources/views/pad/components/templates/dimensao/ensino/projeto/form_update.blade.php index 77056aa7bc786374b3d87f6742eb3b3300441bbc..4689ba85459a9739c0eec4e2ecf07d2eb9853aa8 100644 --- a/resources/views/pad/components/templates/dimensao/ensino/projeto/form_update.blade.php +++ b/resources/views/pad/components/templates/dimensao/ensino/projeto/form_update.blade.php @@ -14,6 +14,69 @@ +
+ + + + @include('components.divs.errors', [ + 'field' => 'titulo_update', + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'curso_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'natureza_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'funcao_update' + ]) +
+ +
+ + + + @include('components.divs.errors', [ + 'field' => 'ch_semanal_update' + ]) +
+