Conjunto 79b6044 en sipes


Ignorar:
Fecha y hora:
09/03/2017 15:43:22 (hace 7 años)
Autor:
Cenditel <root@…>
Branches:
version-3.0
Children:
23a1098
Parents:
be00923
Mensaje:

se agrego un cambio en el js

Fichero:
1 editado

Leyenda

No modificado
Añadido
Eliminado
  • 0.3-modules/proyectos_reformulacion/js/proyectos_reformulacion.js

    r303fae2 r79b6044  
    5454    $(this).val(sign + $.number(valor, Drupal.settings.format_number.decimals, Drupal.settings.format_number.dec_point, Drupal.settings.format_number.thousands_sep));
    5555  });
     56
     57  var personas = Drupal.settings.unidadmpers;
     58  var valorundm = $('#edit-field-proyecto-unidadm').val();
     59  if (typeof(valorundm) != "undefined" && valorundm !== null && typeof personas[valorundm] == "undefined") {
     60    $('#meta-unidm-pers').hide();
     61  }
     62
     63  $("#edit-field-proyecto-unidadm").change(function() {
     64    valorundm = $(this).val();
     65    if (typeof personas[valorundm] == "undefined") {
     66      $("#edit-unidad-m").val(0);
     67      $("#edit-unidad-f").val(0);
     68      prsumaref('unidad-genero');
     69      prsumaref2('subtotal-unidad-m', 'genero', 'm');
     70      prsumaref2('subtotal-unidad-f', 'genero', 'f');
     71      prsumaref('subtotales-unidad');
     72      $('#meta-unidm-pers').hide();
     73    }
     74    else {
     75      $('#meta-unidm-pers').show();
     76    }
     77  });
     78
    5679  $(".number1").each(function() {
    5780    var valor = $(this).val();
     
    86109    return ;
    87110  });
    88   var financiera = Drupal.settings.proyectos_reformulacion['mfisicas']['financia'];
    89   if (typeof(financiera) != "undefined" && financiera !== null) {
    90     $.each( financiera, function( key, value ) {
    91       prsumaref2('subtotalff-' + key, 'financia', key);
    92     });
     111
     112  if (Drupal.settings.proyectos_reformulacion) {
     113    var financiera = Drupal.settings.proyectos_reformulacion['mfisicas']['financia'];
     114    if (typeof(financiera) != "undefined" && financiera !== null) {
     115      $.each( financiera, function( key, value ) {
     116        prsumaref2('subtotalff-' + key, 'financia', key);
     117      });
     118    }
     119    prsumaref('subtotalesf');
    93120  }
    94121}
Nota: Vea TracChangeset para ayuda en el uso del visor de conjuntos de cambios.