//公共效果
$(function(){
	insureSelectChange ('2');
});

function queryPartnerType(){
	var partnerType=$("#partnerType").val();
	var endDate = $("#endDate").val();
//	if(partnerType != '' || (endDate !='')){
//		SkipByPost("queryDirectPayAmtResult.do",{partnerType:partnerType,endDate:endDate});
//	}
	$("#list").html("");
	$.ajax({  
        type: "POST",  
        async: false, 
        url: "queryDirectPayAmtResult.do", 
        data: {"partnerType":partnerType,"endDate":endDate},  
        success: function(data){
        	for(var i = 0;i<data.length;i++){
        		var n = data[i];       		
        		$("#list").append("<tr><td  onclick=\"detailPage()\" style=\"cursor: pointer;\"  >"+n.partnerType+"</td><td>"+n.amtTotal+"</td></tr>");
        	}
        }  
    }); 	
}
function insureSelectChange (value){
	$("#partnerType").attr("value",value);
}
function detailPage(partnerType){
	var partnerType=$("#partnerType").val();
	var endDate = $("#endDate").val();
	SkipByPost("queryDirectPayAmtDetailResult.do",{partnerType:partnerType,endDate:endDate});
}