Преглед изворни кода

Limit toggle selector to visible input fields

Saria Hajjar пре 6 година
родитељ
комит
07a1baef13
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      netbox/project-static/js/forms.js

+ 1 - 1
netbox/project-static/js/forms.js

@@ -7,7 +7,7 @@ $(document).ready(function() {
 
     // "Toggle" checkbox for object lists (PK column)
     $('input:checkbox.toggle').click(function() {
-        $(this).closest('table').find('input:checkbox[name=pk]').prop('checked', $(this).prop('checked'));
+        $(this).closest('table').find('input:checkbox[name=pk]:visible').prop('checked', $(this).prop('checked'));
 
         // Show the "select all" box if present
         if ($(this).is(':checked')) {