]> glassweightruler.freedombox.rocks Git - Ventoy.git/blobdiff - Plugson/www/plugson_auto_install.html
issue template update
[Ventoy.git] / Plugson / www / plugson_auto_install.html
index a8137bf6283554e3d3dea507357902cbda0d4be9..4b3066c090fc83f60f32a7e92d9eb0c4b8bb4016 100644 (file)
     var id = $(this).attr('id');\r
     var value = $(this).val();\r
     var intval;\r
-    \r
-    if (id.length <= 16) {\r
+\r
+    if (typeof(id) == 'undefined' || id.length <= 16) {\r
       return;\r
     }\r
 \r
     var id = $(this).attr('id');\r
     var checked = $(this).is(':checked');\r
 \r
-    if (id.length <= 14) {\r
+    if (typeof(id) == 'undefined' || id.length <= 14) {\r
       return;\r
     }\r
 \r
     if (id.startsWith('id_timeout_en_')) {\r
       textid = 'input[id=id_text_timeout_' + index + ']';\r
       value = data.timeout;\r
+      data.timeouten = checked;\r
     } else {\r
       textid = 'input[id=id_text_autosel_' + index + ']';\r
       value = data.autosel;\r
+      data.autoselen = checked;\r
     }\r
     \r
     if (checked) {\r
 \r
     $('input[type=text]').each(function (){\r
       var id = $(this).attr('id');\r
-      \r
+      if (typeof(id) == 'undefined') {\r
+        return;\r
+      }\r
       if (id.startsWith('id_text_timeout_') || id.startsWith('id_text_autosel_')) {\r
         $(this).change(OnInputTextChange);\r
       }\r
 \r
     $('input[type=checkbox]').each(function (){\r
       var id = $(this).attr('id');\r
+      if (typeof(id) == 'undefined') {\r
+        return;\r
+      }\r
       if (id.startsWith('id_timeout_en_') || id.startsWith('id_autosel_en_')) {\r
         $(this).click(OnCheckBoxChange);\r
       }\r