Commit e2c7430444f72a4474d5936d8e1c0d650c8ca9dc

Authored by Wilmer
1 parent e0a26ff6f5
Exists in master

validado que si el formulario tiener error, no cierre las opciones seleccionadas al refrescar.

app/Resources/views/solicitudes/ascenso.html.twig
... ... @@ -138,6 +138,10 @@
138 138 {{ parent() }}
139 139 <script type="text/javascript" src="{{ asset('assets/vendor/chosen/chosen.jquery.min.js') }}"></script>
140 140 <script type="text/javascript">
  141 +
  142 +
  143 +
  144 +
141 145  
142 146  
143 147 $('#ascenso_tipoTrabajoInvestigacion').click(function() {
... ... @@ -248,6 +252,19 @@
248 252  
249 253 $("#ascenso_tutores_ascenso").on("chosen:ready", function() {
250 254 $("#ascenso_tutores_ascenso_chosen").hide();
  255 + if($('#ascenso_tipoTrabajoInvestigacion').val() === 'investigacion'){
  256 + $('.esc_investigacion').show();
  257 + $('.esc_tesis').hide();
  258 + $("#ascenso_tutores_ascenso_chosen").show();
  259 + }else if($('#ascenso_tipoTrabajoInvestigacion').val() === 'tesis') {
  260 + $('.esc_investigacion').hide();
  261 + $('.esc_tesis').show();
  262 + if ($('#ascenso_tesisUbv').prop("checked")) {
  263 + $("#ascenso_tutores_ascenso_chosen").show();
  264 + }else{
  265 + $("#ascenso_tutores_ascenso_chosen").hide();
  266 + }
  267 + }
251 268 });
252 269  
253 270  
... ...