var commonGridObj_opseaetotal; var chartBarTeuObj; var chartPieTeuObj; var chartLineTeuObj; var chartBarProfitObj; var chartPieProfitObj; var chartLineProfitObj; var chartBarOrderObj; var chartPieOrderObj; var chartLineOrderObj; function $(id){ return document.getElementById(id); } function createGrid(){ //header var headerArgs_opseae = new Array("年","月","箱量","票数","毛利润"); //width var widthArgs_opseae = new Array("120","120","120","120","120"); //column align var colAlignArgs_opseae = new Array("center","center","center","center","center"); //column sort var colSortArgs_opseae = new Array("str","str","str","str","str"); //column type var colTypeArgs_opseae = new Array("ro","ro","ro","ro","ro"); commonGridObj_opseaetotal = new TGridCommon("mygrid_container_total","form1",headerArgs_opseae,widthArgs_opseae,colAlignArgs_opseae,colSortArgs_opseae,colTypeArgs_opseae); commonGridObj_opseaetotal.setResponseUrl("ChartGridSource.aspx"); var searchcacheName = $("h_searchcache").value; var searchStr = ""; if(searchcacheName.trim() != ""){ searchStr = "&searchcachename="+searchcacheName; } commonGridObj_opseaetotal.setRequest("ChartGridSource.aspx?handle=opseaetotal"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid()); commonGridObj_opseaetotal.setSourceType("json"); commonGridObj_opseaetotal.setSkin("xp"); commonGridObj_opseaetotal.setImageUrl("../images/"); commonGridObj_opseaetotal.initGrid(); commonGridObj_opseaetotal.bind(); //commonGridObj_opseaetotal.initPageByHandle("opseaetotal"); } function initTeuChart(typeName){ var searchcacheName = $("h_searchcache").value; var searchStr = ""; if(searchcacheName.trim() != ""){ searchStr = "&searchcachename="+searchcacheName; } switch(typeName){ case "bar": switchDisplay("chartTeuBarContainer",true); switchDisplay("chartTeuPieContainer",false); switchDisplay("chartTeuLineContainer",false); var chartBarTeuObj = new dhtmlXChart({ view:"bar", container:"chartTeuBarContainer", value:"#teu#", label:"#yearmonth#" }) chartBarTeuObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "pie": switchDisplay("chartTeuBarContainer",false); switchDisplay("chartTeuPieContainer",true); switchDisplay("chartTeuLineContainer",false); var chartPieTeuObj = new dhtmlXChart({ view:"pie", container:"chartTeuPieContainer", value:"#teu#", label:"#yearmonth#" }) chartPieTeuObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "line": switchDisplay("chartTeuBarContainer",false); switchDisplay("chartTeuPieContainer",false); switchDisplay("chartTeuLineContainer",true); var chartLineTeuObj = new dhtmlXChart({ view:"line", container:"chartTeuLineContainer", value:"#teu#", label:"#yearmonth#" }) chartLineTeuObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; } } function initProfitChart(typeName){ var searchcacheName = $("h_searchcache").value; var searchStr = ""; if(searchcacheName.trim() != ""){ searchStr = "&searchcachename="+searchcacheName; } switch(typeName){ case "bar": switchDisplay("chartProfitBarContainer",true); switchDisplay("chartProfitPieContainer",false); switchDisplay("chartProfitLineContainer",false); var chartBarProfitObj = new dhtmlXChart({ view:"bar", container:"chartProfitBarContainer", value:"#profit#", label:"#yearmonth#" }) chartBarProfitObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "pie": switchDisplay("chartProfitBarContainer",false); switchDisplay("chartProfitPieContainer",true); switchDisplay("chartProfitLineContainer",false); var chartPieProfitObj = new dhtmlXChart({ view:"pie", container:"chartProfitPieContainer", value:"#profit#", label:"#yearmonth#" }) chartPieProfitObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "line": switchDisplay("chartProfitBarContainer",false); switchDisplay("chartProfitPieContainer",false); switchDisplay("chartProfitLineContainer",true); var chartLineProfitObj = new dhtmlXChart({ view:"line", container:"chartProfitLineContainer", value:"#profit#", label:"#yearmonth#" }) chartLineProfitObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; } } function initOrderChart(typeName){ var searchcacheName = $("h_searchcache").value; var searchStr = ""; if(searchcacheName.trim() != ""){ searchStr = "&searchcachename="+searchcacheName; } switch(typeName){ case "bar": switchDisplay("chartOrderBarContainer",true); switchDisplay("chartOrderPieContainer",false); switchDisplay("chartOrderLineContainer",false); var chartBarOrderObj = new dhtmlXChart({ view:"bar", container:"chartOrderBarContainer", value:"#order#", label:"#yearmonth#" }) chartBarOrderObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "pie": switchDisplay("chartOrderBarContainer",false); switchDisplay("chartOrderPieContainer",true); switchDisplay("chartOrderLineContainer",false); var chartPieOrderObj = new dhtmlXChart({ view:"pie", container:"chartOrderPieContainer", value:"#order#", label:"#yearmonth#" }) chartPieOrderObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; case "line": switchDisplay("chartOrderBarContainer",false); switchDisplay("chartOrderPieContainer",false); switchDisplay("chartOrderLineContainer",true); var chartLineOrderObj = new dhtmlXChart({ view:"line", container:"chartOrderLineContainer", value:"#order#", label:"#yearmonth#" }) chartLineOrderObj.load("ChartGridSource.aspx?handle=opseaechartjson"+searchStr+"&oplb=op_Seae&uid="+commonGridObj_opseaetotal.newGuid(),"json"); break; } } function refresh(){ $("h_searchcache").value = ""; createGrid(); initCharts($('sel_type').options[$('sel_type').selectedIndex].value); } function initCharts(chartType){ initTeuChart(chartType); initProfitChart(chartType); initOrderChart(chartType); } function checkList(val){ initCharts(val); } function switchDisplay(id,isDisplay){ isDisplay ? $(id).style.display = "":$(id).style.display = "none"; } function searchMultiple(){ printMessageBox(event); } var isIe=(document.all)?true:false; //设置select的可见状态 function setSelectState(state){ var objl=document.getElementsByTagName('select'); for(var i=0;i" + "" + "
"+content+"
"; var v_top=(document.body.clientHeight-mesW.clientHeight)/2; v_top+=document.documentElement.scrollTop; styleStr="top:120px;left:"+(document.body.clientWidth/2-mesW.clientWidth/2)+"px;position:absolute;width:700px;margin-left:-300px;left:50%;z-index:9999;"; mesW.style.cssText=styleStr; document.body.appendChild(mesW); } //让背景渐渐变暗 function showBackground(obj,endInt){ if(isIe){ obj.filters.alpha.opacity+=5; if(obj.filters.alpha.opacity" // +"
" //// +" " // +"
" // +"
" // +" " // +" " // +"
" // +" "; messContent += "
" + "