]> jspc29.x-matter.uni-frankfurt.de Git - daqtools.git/commitdiff
fix CTS gui error with old designs after including downscale
authorJan Michel <michel@physik.uni-frankfurt.de>
Fri, 14 Apr 2023 14:52:22 +0000 (16:52 +0200)
committerJan Michel <michel@physik.uni-frankfurt.de>
Fri, 14 Apr 2023 14:52:22 +0000 (16:52 +0200)
web/htdocs/scripts/cts.js

index 59533e51733aa696346ee81cafca17c59494765b..e311efd9e62d0d4e51a87ff536873ceb8f16af8d 100644 (file)
@@ -446,6 +446,9 @@ var CTS = new Class({
          var reg = 'trg_input_config' + i;
          var areg = 'trg_input_mux' + (i-source_from);
          var source;
+         var downscaleparams = {'class': 'text autocommit autoupdate', 'slice': reg + '.downscale'};
+         if (noavail == " noavail")    downscaleparams = {'class': 'text'};
+                    
          $('inputs-tab')
          .adopt(
             new Element('tr', {'class': i%2?'':'alt', 'flashgroup': 'itc-' + (i + parseInt(this.defs.properties.trg_input_itc_base))})
@@ -483,7 +486,7 @@ var CTS = new Class({
                ),
                new Element('td', {'class': 'downscale'+noavail})
                .adopt([
-                  new Element('input', {'class': 'text autocommit autoupdate', 'slice': reg + '.downscale'})
+                  new Element('input', downscaleparams)
                ]),
             ])
          );