not showing all checkedbox function

not showing all checkedbox function

Hi
I have a table with checkboxes, there are 3rows (including heading) & 4 columns (including checkbox). when I checked the checkbox for a row, then it will show the dropdown list, else the dropdown list will be invisible. this works fine for me for each of them but when I try to "select all checkbox" from the top, it select all the checkboxes but does not show dropdown list. 
  1. function valueChanged()
    			{
    				if($(".checkezspeedkit").is(":checked"))   
    					$(".qtyezspeedkit ").show();
    				else
    					$(".qtyezspeedkit").hide();
    			}
    			
    			function valueChanged2()
    			{
    				if($(".checkezenergykit").is(":checked"))   
    					$(".qtyezenergykit").show();
    				else
    					$(".qtyezenergykit").hide();
    			}
    			
    			function toggle(source) {
    				var checkboxes = document.querySelectorAll('input[type="checkbox"]');
    				for (var i = 0; i < checkboxes.length; i++) {
    					if (checkboxes[i] != source)
    						checkboxes[i].checked = source.checked;
    				}
    			}
  2. <table id="mytable" class="table table-bordred table-striped">
  3. <thead>
  4. <th><input type="checkbox" id="checkall" class="checkall" onclick="toggle(this);"/></th>
  5. <th>Name</th>
  6. <th>Qty</th>
  7. <th>Option</th>
  8. </thead>
  9. <tbody>
  10. <tr>
  11. <td><input type="checkbox" class="checkezspeedkit checkboxitem" name="chkezspeedkit" onchange="valueChanged()"/></td>
  12. <td>EZSpeed Kit</td>
  13. <td>
  14. <select name="Select1" style="width: 50px" class="qtyezspeedkit" >
  15. <option>1</option>
  16. <option>2</option>
  17. </select>
  18. </td>
  19. <td>
  20. <select name="Select2" style="width: 137px" class="qtyezspeedkit">
  21. <option>Please select</option>
  22. <option>Required</option>
  23. <option>Option</option>
  24. </select>
  25. </td>
  26. </tr>
  27. <tr>
  28. <td><input type="checkbox" class="checkezenergykit checkboxitem" name="chkezspeedkitbluetooth" onchange="valueChanged2()"/></td>
  29. <td>EZEnergy Kit</td>
  30. <td>
  31. <select name="Select1" style="width: 50px" class="qtyezenergykit" >
  32. <option>1</option>
  33. <option>2</option>
  34. </select>
  35. </td>
  36. <td>
  37. <select name="Select2" style="width: 137px" class="qtyezenergykit" >
  38. <option>Please select</option>
  39. <option>Required</option>
  40. <option>Option</option>
  41. </select>
  42. </td>
  43. </tr>
  44. </tbody>
  45. </table>

thank you