我不能.trigger("change")
去上班。有谁知道为什么?
jQuery(document).ready(function () {
jQuery("select[id='DROPDOWNID']").change(function () {
var selectedIndex = jQuery("select[id='DROPDOWNID']").prop('selectedIndex');
switch (selectedIndex) {
case 0:
hideVarforProspekt();
break;
case 1:
hideOrdervarde();
break;
case 2:
break;
case 3:
hideSektor();
break;
}
});
** jQuery("select[id='DROPDOWNID']").trigger("change"); **
function hideVarforProspekt() {
jQuery("input[id='IDFROMSHAREPOINT']").closest('tr').hide();
}
function hideSektor() {
jQuery("table[id='IDFROMSHAREPOINT']").closest('tr').hide();
}
function hideUppskOrder() {
jQuery("input[id='IDFROMSHAREPOINT']").closest('tr').hide();
}
});