import{E as p}from"./index-37bf2f99-1785478469326v=1.0.0.js";import{x as d,c as m,r as h,al as f,y as _,z as x,A as y,Q as n,I as b,M as g,L as w,u as C}from"./vendor-46662d77-1785478469326v=1.0.0.js";import{_ as v}from"./index-5a47c360-1785478469326v=1.0.0.js";import"./eleVendor-bc05bc4d-1785478469326v=1.0.0.js";const D={class:"five-year-test-records"},F={class:"down-btn"},S=d({__name:"Five-YearTestRecords",props:{chartData:{default:[]}},setup(l){const o=l,i=m(()=>o.chartData.length===0?{title:{text:"\u6682\u65E0\u6570\u636E",x:"center",y:"center",textStyle:{fontSize:16,fontWeight:"normal"}}}:{grid:{left:"8%",right:"3%",top:"15%",bottom:"10%"},tooltip:{trigger:"axis",axisPointer:{type:"cross",label:{backgroundColor:"#6a7985"}}},title:{text:"\u8FD15\u5E74\u4F53\u6D4B\u7ED3\u679C",left:"left",top:"top",padding:[15,10,0,0],textStyle:{color:"#303133",fontSize:16,fontWeight:400}},xAxis:{axisLine:{lineStyle:{color:"#606266"}},splitLine:{show:!1},axisTick:{show:!0,alignWithLabel:!0},axisLabel:{show:!0},data:o.chartData.map(e=>e.schoolYearName)},yAxis:{type:"value"},series:[{name:"\u53CA\u683C",type:"line",smooth:!0,lineStyle:{width:2,color:"#5AD8A6"},showSymbol:!1,emphasis:{focus:"series"},label:{show:!0,position:"top"},data:o.chartData.map(e=>e.passNum)},{name:"\u5408\u683C",type:"line",smooth:!0,lineStyle:{width:2,color:"#5B8FF9"},showSymbol:!1,emphasis:{focus:"series"},label:{show:!0,position:"top"},data:o.chartData.map(e=>e.qualifiedNum)},{name:"\u4F18\u79C0",type:"line",smooth:!0,lineStyle:{width:2,color:"#FFB558"},showSymbol:!1,emphasis:{focus:"series"},label:{show:!0,position:"top"},data:o.chartData.map(e=>e.excellentNum)}]}),r=h(null),c=()=>{var t,a;const e=(a=(t=r.value)==null?void 0:t.getInstance)==null?void 0:a.call(t);if(e){const u=e.getDataURL({type:"png",pixelRatio:2,backgroundColor:"#fff"}),s=document.createElement("a");s.href=u,s.download="chart.png",s.click()}};return(e,t)=>{const a=f("el-button");return _(),x("div",D,[y("div",F,[n(a,{size:"small",onClick:c},{default:b(()=>t[0]||(t[0]=[g("\u4E0B\u8F7D",-1)])),_:1,__:[0]})]),w(" {{ option }} "),n(p,{ref_key:"echartsRef",ref:r,option:C(i)},null,8,["option"])])}}});const R=v(S,[["__scopeId","data-v-ab81d5b7"]]);export{R as default};
