<input type="hidden" name="kmdm" id="kmdm"/>
<a href="javascript:void(0);" onclick="selectAll()">全选</a> / <a href="javascript:void(0);" onclick="selectNone()">清空</a>
<td><input type="checkbox" name="kmchk" value="11"/>平均成绩</td>
<td><input type="checkbox" name="kmchk" value="12"/>总成绩</td>
<td><input type="checkbox" name="kmchk" value="13"/>赋分总成绩</td>
<td><input type="checkbox" name="kmchk" value="14"/>单科排名</td>
<button class="btn btn-primary" onclick="importXs();">查询</button>
<script type="text/javascript">var kmdm = "";
function importXs(){
layer.closeAll();
kmdm = "";
$("input[name='kmchk']:checked").each(function(){
if(kmdm!=""){
kmdm+=",";
}
kmdm+=$(this).val();
});
if(kmdm==""){
layer.alert("请先选择。",{icon:2});
return;
}
$("#kmdm").val(kmdm);
$("#uploadform").submit();
}
function selectAll(){
$("input[name='kmchk']").prop("checked",true)
}
function selectNone(){
$("input[name='kmchk']").prop("checked",false);
}
</script>