www/js/inv_yeasts.js

changeset 727
08f91a68e757
parent 725
30346e5b9e12
child 729
eabc100b3d6b
equal deleted inserted replaced
726:872a3635e4ef 727:08f91a68e757
394 $('#pitch_lo').val(dataRecord.gr_hl_lo + '@' + parseFloat(dataRecord.sg_lo).toFixed(3)); 394 $('#pitch_lo').val(dataRecord.gr_hl_lo + '@' + parseFloat(dataRecord.sg_lo).toFixed(3));
395 $('#gr_hl_hi').val(dataRecord.gr_hl_hi); 395 $('#gr_hl_hi').val(dataRecord.gr_hl_hi);
396 $('#sg_hi').val(parseFloat(dataRecord.sg_hi)); 396 $('#sg_hi').val(parseFloat(dataRecord.sg_hi));
397 $('#pitch_hi').val(dataRecord.gr_hl_hi + '@' + parseFloat(dataRecord.sg_hi).toFixed(3)); 397 $('#pitch_hi').val(dataRecord.gr_hl_hi + '@' + parseFloat(dataRecord.sg_hi).toFixed(3));
398 $('#short_desc').val(dataRecord.short_desc); 398 $('#short_desc').val(dataRecord.short_desc);
399 if (dataRecord.form == 'Droog') {
400 $('.yeast_wet').hide();
401 $('.yeast_dry').show();
402 } else {
403 $('.yeast_wet').show();
404 $('.yeast_dry').hide();
405 }
399 calcTotal(); 406 calcTotal();
400 // show the popup window. 407 // show the popup window.
401 $('#popupWindow').jqxWindow('open'); 408 $('#popupWindow').jqxWindow('open');
402 } 409 }
403 } 410 }
417 calcTotal(); 424 calcTotal();
418 }); 425 });
419 $('#form').on('select', function(event) { 426 $('#form').on('select', function(event) {
420 dataRecord.form = $('#form').val(); 427 dataRecord.form = $('#form').val();
421 calcTotal(); 428 calcTotal();
429 if (dataRecord.form == 'Droog') {
430 $('.yeast_wet').hide();
431 $('.yeast_dry').show();
432 } else {
433 $('.yeast_wet').show();
434 $('.yeast_dry').hide();
435 }
422 }); 436 });
423 437
424 // initialize the popup window and buttons. 438 // initialize the popup window and buttons.
425 $('#pitchloWindow').jqxWindow({ 439 $('#pitchloWindow').jqxWindow({
426 theme: theme, 440 theme: theme,

mercurial