import{H as V,d as k,r as S,u as se,a as re,e as T,U as J,f as e,k as n,aG as j,F as C,j as G,x as le,b as ge,V as F,b0 as me,q as H,S as ne,$ as v,C as $,T as fe,a0 as ye,a1 as he,t as ve,v as K,y as De}from"./index-324a91a1-1728525661307.js";import{a as ie,g as Te}from"./use-async-adf97bdc-1728525661307.js";import{C as be}from"./index-122fe044-1728525661307.js";import{s as a}from"./index2.module-b9ceafae-1728525661307.js";import{u as oe}from"./useECharts-784d931d-1728525661307.js";import{P as ue}from"./index-e00e25f7-1728525661307.js";import{N as D,b as B,f as Y,e as E,h as N,j as _,i as U,c as q,d as P,g as ee,a as te}from"./icon-sort-asc-bbadd74b-1728525661307.js";import{j as Ce,t as Ae,l as Se}from"./api-1a36072a-1728525661307.js";import{T as Q}from"./index-e4dbb426-1728525661307.js";import{g as z,s as O}from"./index-db345329-1728525661307.js";import{s as ae}from"./api-14a9206b-1728525661307.js";import"./index-a5039825-1728525661307.js";const xe="_listWrap_x49zf_1",we="_customTabs_x49zf_7",Oe="_searchBtn_x49zf_28",Ie="_resetBtn_x49zf_33",R={listWrap:xe,customTabs:we,searchBtn:Oe,resetBtn:Ie},Ee=b=>V.post("/edu-app/lessonTraining/trainingStat",{data:b}),Fe=b=>V.post("/edu-app/musicPracticeRecordStat/trainingStat",{data:b}),Be=b=>V.post("/edu-app/musicPracticeRecordStat/practicePageStat",{data:b}),Le=k({name:"home-trainData",props:{timer:{type:Array,defaut:()=>[]}},setup(b,{expose:I}){const i=S(null),{setOptions:p}=oe(i),d=S(!0),x=S(!0),h=se();re();const r=T({height:"360px",width:"100%",studentNum:0,paymentAmount:0,dateList:[],studentList:[],payInfoList:[]}),o=S({qualifiedRate:0,qualifiedStudentCount:0,submitStudentCount:0,totalStudentCount:0,trainingCount:0,trainingRate:0}),u=T({loading:!1,pagination:{page:1,rows:10,pageTotal:4},tableList:[],goCourseVisiable:!1}),c=J(()=>b.timer),g=()=>[{title:"布置老师",key:"teacherName"},{title:"布置时间",key:"createTime",render(l){return e(C,null,[l.createTime])}},{title:"截止时间",key:"expireDate",render(l){return e(C,null,[l.expireDate])}},{title:"训练状态",key:"status",render(l){return l.status==0?e("div",{class:a.indDot},[" ",e("span",null,null),n(" 进行中")]):e("div",{class:a.endDot},[e("span",null,null),n("已结束")])}},{title:"布置人数",key:"expectNum"},{title:"提交人数",key:"trainingNum"},{title:"合格人数",key:"standardNum"},{title:"提交率",key:"trainingRate",render(l){return e(C,null,[l.trainingRate,n("%")])}},{title:"合格率",key:"qualifiedRate",render(l){return e(C,null,[l.qualifiedRate,n("%")])}},{title:"操作",key:"id",render(l){return e(le,null,{default:()=>[e(G,{text:!0,type:"primary",onClick:()=>s(l)},{default:()=>[n("详情")]})]})}}],s=l=>{console.log(l),h.push({path:"/homework-record-detail",query:{id:l.id,name:l.name}})},f=async()=>{u.loading=!0;try{const l=await Ee({...B(c.value,["startTime","endTime"],"YYYY-MM-DD")});o.value={...l.data},r.dateList=l.data.trainingStatDetails.map(m=>m.date),r.payInfoList=l.data.trainingStatDetails.map(m=>m.qualifiedStudentCount),r.studentList=l.data.trainingStatDetails.map(m=>m.unqualifiedStudentCount),A()}catch(l){console.log(l)}try{const l=await Ce({...u.pagination,...B(c.value,["startTime","endTime"],"YYYY-MM-DD")});u.tableList=l.data.rows,u.pagination.pageTotal=l.data.total,u.loading=!1}catch(l){u.loading=!1,console.log(l)}u.loading=!1};I({getList:f});const A=()=>{p({tooltip:{trigger:"axis",axisPointer:{lineStyle:{width:2,color:"#A9C7FF"}}},legend:{show:!1,selected:{合格人数:d.value,不合格人数:x.value}},xAxis:{type:"category",boundaryGap:!0,axisLabel:{show:!0},data:r.dateList},yAxis:[{type:"value",axisLabel:{formatter:"{value}人"},axisTick:{show:!1},splitArea:{show:!1,areaStyle:{color:["rgba(255,255,255,0.2)"]}},minInterval:1,splitNumber:5}],grid:{left:"1%",right:"1%",top:80,bottom:80,containLabel:!0},series:[{data:r.studentList,type:"line",name:"不合格人数",symbol:"circle",smooth:!0,itemStyle:{color:"#FF7AA7",borderColor:"#fff",borderWidth:3},lineStyle:{width:3},areaStyle:{color:{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:"rgba(255, 243, 246, 1)"},{offset:1,color:"rgba(255, 246, 248, 0)"}]}},emphasis:{disabled:!0}},{data:r.payInfoList,type:"line",name:"合格人数",symbolSize:10,symbol:"circle",smooth:!0,itemStyle:{color:"#198CFE",borderColor:"#fff",borderWidth:3},lineStyle:{width:2},areaStyle:{color:{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:"rgba(212, 231, 255, 1)"},{offset:1,color:"rgba(221, 235, 254, 0)"}]}},emphasis:{disabled:!0}}],formatter:l=>Array.isArray(l)?[l[0].axisValueLabel,...l.map(m=>"
".concat(m.marker,'').concat(m.seriesName,": ").concat(m.value,"人 "))].join(""):l})};return f(),()=>e(C,null,[e("div",{class:a.homeTrainData},[e("div",{class:a.TrainDataTop},[e("div",{class:a.TrainDataTopLeft},[e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.trainingCount},null)]),n("次")])]),e("p",{class:a.TrainDataItemsubTitle},[n("作业次数")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.totalStudentCount},null)]),n("人次")])]),e("p",{class:a.TrainDataItemsubTitle},[n("应交总人次")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.submitStudentCount},null)]),n("人次")])]),e("p",{class:a.TrainDataItemsubTitle},[n("提交总人次")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.qualifiedStudentCount},null)]),n("人次")])]),e("p",{class:a.TrainDataItemsubTitle},[n("合格总人次")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.trainingRate},null)]),n("%")])]),e("p",{class:a.TrainDataItemsubTitle},[n("作业提交率")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:o.value.qualifiedRate},null)]),n("%")])]),e("p",{class:a.TrainDataItemsubTitle},[n("作业合格率")])])]),e("div",{class:a.TrainDataTopRight},[e("div",{onClick:()=>{d.value=!d.value,A()},class:[a.DataTopRightItem,d.value?"":a.DataTopRightItemDis]},[e("div",{class:a.DataTopRightDot},null),e("p",null,[n("合格人数")])]),e("div",{onClick:()=>{x.value=!x.value,A()},class:[a.DataTopRightItem,x.value?"":a.DataTopRightItemDis]},[e("div",{class:[a.DataTopRightDot,a.red]},null),e("p",null,[n("不合格人数")])])])]),e("div",{class:a.chatrs},[e("div",{ref:i,style:{height:r.height,width:r.width}},null)]),e("div",{class:a.tableWrap},[e(j,{class:a.classTable,loading:u.loading,columns:g(),data:u.tableList},{empty:()=>e(Q,null,null)}),e(ue,{page:u.pagination.page,"onUpdate:page":l=>u.pagination.page=l,pageSize:u.pagination.rows,"onUpdate:pageSize":l=>u.pagination.rows=l,pageTotal:u.pagination.pageTotal,"onUpdate:pageTotal":l=>u.pagination.pageTotal=l,onList:f,sync:!0},null)])])])}}),Re="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAA2tJREFUWEfFV0tLW0EU/kbvbdWUImi0JFWjJioJFB8EiiAYIbZ0Uei6v6Auuy11Yem2u9pf0HWhUChGiOAmWPCJYpqC8ZEQjQjGiNbETD1jbkjSxLk3reRAspg5851vznMug05ZX1+/E41GPQCeA3ACsGR/hBDN/jYAfLVYLH6Xy3WhB5rJlPx+/4N0Oj3JOX8J4L5MP7ufYIx9VhRlyuPxxG46U5ZAKBS6u7W19QbAawAmnYaL1U6vSH/o7Ox873A4fpfCKEkge+svnPPHFRouOMYYCyiK8qKUN/4iMDs7+yiTyXwD8PB/GM/D2GOMPfN6vWv5uAUE6OapVOrHLRjXbO6pqurO90SOAMU8HA7PGXE7YwyqquLiQlfCCxIUDpvNNqrlRI7AzMzMFIC3MrfX1taiq6sLLS0tqK+vJ0BcXl4ikUggFArh+PhYBkH778bHxycFIfrLuv6XLNsbGhowNDSEurq6skY2Nzexu7srI3GqqqqdQiEI+Hy+ac75K9kpt9uNxsZGoXZ0dISDgwNx++bmZrS2tor1TCaDQCCA01OqwPLCGPvk9XonGHW4SCQSlzUZs9mM/v5+gXh4eIilpaUCdKfTCavVKtYoFOFwWHafhNVqNTOfz/fkKvG+y7Qp7t3d3UKNjBOJfGlqasLg4KBYisViWFsrqLaS8FcJ+ZQIfOScT8gI2O124WqSlZUVnJ2dFRyhvYGBAbEWiUSwsUFj4WZhjE0TAT/nfFSmLNun25MXSILBIHZ2dmRHqILmiECQc94j1b5Boa+vD21tbUIjlUphfn5eJKdMGGM/icAJ5/yeTLncvsvlgsVCk/naOOWHzl5AHkj+EwGHwwGbzSaMn5+fY3FxUVp++RdhjJ1UHAJqSsPDw7lOuLCwgGQyaciRWggqSsKOjg709FynDiUcJZ5R0ZJQVxkWg/f29qK9vV0sr66uYn9/36h98p4oQ12NqBhdURTQj4SmIbVgoyIakd5WXAxuMplE6ZHx7e1tXWVXhHHdimlR7zDKBxgZGclNxUpyIDeMCFTvONYI1NTUYGxsTFQASTwex/LyspEIFI5jOqn3QaJZ0XpAOp0Ws4HGswEpfJDQwUqeZPQco5ZrJAHLPsnyQlGdR6nmvqo+yzUSVf0w0UhU9dMsP5ur9nFaXFK39Xn+B0AaxPFhpWhWAAAAAElFTkSuQmCC",ke=k({name:"home-practiceData",props:{timer:{type:Array,defaut:()=>[]}},setup(b,{expose:I}){const i=se(),p=ge(),d=S(null),{setOptions:x}=oe(d),h=S(!0),r=T({height:"360px",width:"100%",practiceDuration:0,evaluateUserCount:0,evaluateFrequency:0,publishUserCount:0,publishCount:0,practiceUserCount:0,paymentAmount:0,practiceDurationAvg:0,practiceDays:0,practiceDurationTotal:0,dateList:[],timeList:[]}),o=T({loading:!1,pagination:{page:1,rows:10,pageTotal:4},searchForm:{orderBy:null,sort:null},tableList:[],goCourseVisiable:!1}),u=J(()=>b.timer),c=(t,y)=>e(F,{showArrow:!1,placement:"top-start"},{trigger:()=>e("div",{class:a.cell},[t,e("img",{class:a.sortIcon,src:y.sortOrder==="descend"?U:y.sortOrder==="ascend"?q:P},null)]),default:y.sortOrder==="descend"?"点击升序":y.sortOrder==="ascend"?"取消排序":"点击降序"}),g=T({title(){return c("练习总时长",g)},key:"practiceDuration",sorter:!0,sortOrder:!1,render(t){return e(C,null,[Y(t.practiceDuration||0)])}}),s=T({title(){return c("练习天数",s)},key:"practiceDays",sorter:!0,sortOrder:!1}),f=T({title(){return c("平均练习时长",f)},key:"practiceDurationAvg",sorter:!0,sortOrder:!1,render(t){return e(C,null,[Y(t.practiceDurationAvg||0)])}}),A=T({title(){return c("评测次数",A)},key:"evaluateFrequency",sorter:!0,sortOrder:!1}),l=T({title(){return c("作品数量",l)},key:"publishCount",sorter:!0,sortOrder:!1,render(t){return t.publishCount||0}}),m=T({title(){return c("最新作品分数",m)},key:"publishScore",sorter:!0,sortOrder:!1,render(t){return t.publishScore===null?"--":t.publishScore}}),w=T({title(){return c("最新作品时间",w)},key:"publishTime",sorter:!0,sortOrder:!1,render(t){return t.publishTime||"--"}}),L=t=>{const y=document.createElement("input");y.value=t,document.body.appendChild(y),y.select(),y.setSelectionRange(0,y.value.length),document.execCommand("Copy"),document.body.removeChild(y),p.success("复制成功")},W=()=>[{title:"学生姓名",key:"studentName",render:t=>e(F,{showArrow:!1,placement:"top-start"},{trigger:()=>e("div",{style:{userSelect:"all",cursor:"pointer"},onClick:()=>L(t.studentName)},[t.studentName]),default:"点击复制"})},{title:"年级班级",key:"date",render(t){return e(C,null,[t.currentGradeNum&&t.currentClass?me(t.currentGradeNum)+"年级"+t.currentClass+"班":""])}},{title:"乐器",key:"instrumentName",render(t){return e(C,null,[t.instrumentName||"--"])}},g,s,f,A,{title:()=>e("span",{style:{display:"flex",alignItems:"center"}},[n("发布作品 "),e(F,{showArrow:!1},{trigger:()=>e("img",{src:Re,class:a.tipImg},null),default:()=>"筛选时间段内评测是否发布作品"})]),key:"publishFlag",render:t=>t.publishFlag?"是":"否"},l,m,w,{title:"操作",key:"titleImg",render:t=>e(G,{type:"primary",text:!0,onClick:()=>{ie("evaluatingRcode","tabName",{path:"/studentDetail"}),i.push({path:"/studentDetail",query:{studentId:t.studentId,studentName:t.studentName,times:JSON.stringify(u.value)}})}},{default:()=>[n("详情")]})}],M=t=>{t.order?(o.searchForm.orderBy=t.columnKey,g.sortOrder=!1,s.sortOrder=!1,f.sortOrder=!1,A.sortOrder=!1,l.sortOrder=!1,m.sortOrder=!1,w.sortOrder=!1,t.columnKey=="practiceDuration"&&(g.sortOrder=t.order),t.columnKey=="practiceDays"&&(s.sortOrder=t.order),t.columnKey=="practiceDurationAvg"&&(f.sortOrder=t.order),t.columnKey=="evaluateFrequency"&&(A.sortOrder=t.order),t.columnKey=="publishCount"&&(l.sortOrder=t.order),t.columnKey=="publishScore"&&(m.sortOrder=t.order),t.columnKey=="publishTime"&&(w.sortOrder=t.order),o.searchForm.sort=t.order=="ascend"?"asc":"desc"):(o.searchForm.orderBy="",o.searchForm.sort="",g.sortOrder=!1,s.sortOrder=!1,f.sortOrder=!1,A.sortOrder=!1,l.sortOrder=!1,m.sortOrder=!1,w.sortOrder=!1),X()},X=async()=>{o.loading=!0;try{const t=await Ae({page:1,rows:999,...o.searchForm,...B(u.value,["startTime","endTime"],"YYYY-MM-DD")});o.tableList=t.data.rows}catch(t){console.log(t)}o.loading=!1},ce=async()=>{o.loading=!0;try{const t=await Fe({page:1,rows:999,...B(u.value,["startTime","endTime"],"YYYY-MM-DD")});r.dateList=t.data.trainingStatDetailList.map(y=>y.date),r.timeList=t.data.trainingStatDetailList.map(y=>y.practiceUserCount),pe()}catch(t){}o.loading=!1},de=async()=>{o.loading=!0;try{const{data:t}=await Be({page:1,rows:999,...B(u.value,["startTime","endTime"],"YYYY-MM-DD")});r.practiceDuration=t.practiceDuration,r.practiceDurationAvg=t.practiceDurationAvg,r.practiceUserCount=t.practiceUserCount,r.evaluateUserCount=t.evaluateUserCount,r.evaluateFrequency=t.evaluateFrequency,r.publishUserCount=t.publishUserCount,r.publishCount=t.publishCount}catch(t){}o.loading=!1},Z=async()=>{await de(),await ce(),await X()};I({getList:Z});const pe=()=>{x({tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},legend:{show:!1,selected:{练习人数:h.value}},xAxis:{type:"category",boundaryGap:!0,axisLabel:{show:!0},data:r.dateList},yAxis:[{type:"value",axisLabel:{formatter:"{value}人"},axisTick:{show:!1},splitArea:{show:!1,areaStyle:{color:["rgba(255,255,255,0.2)"]}},minInterval:1,splitNumber:5}],grid:{left:"1%",right:"1%",top:"2%",bottom:0,containLabel:!0},series:[{data:r.timeList,type:"bar",barWidth:"48px",itemStyle:{normal:{barBorderRadius:[8,8,0,0],color:"#CDE5FF"},emphasis:{focus:"series",color:"#3583FA"}}}],formatter:t=>Array.isArray(t)?[t[0].axisValueLabel,...t.map(y=>"
".concat(y.marker,'练习人数: ').concat(y.value,"人 "))].join(""):t})};return Z(),()=>e(C,null,[e("div",{class:a.homeTrainData},[e("div",{class:a.TrainDataTop},[e("div",{class:a.TrainDataTopLeft},[e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:r.practiceUserCount},null)]),n("人")])]),e("p",{class:a.TrainDataItemsubTitle},[n("练习人数")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[E(r.practiceDurationAvg)>0?e("div",null,[e("span",null,[e(D,{from:0,to:E(r.practiceDurationAvg)},null)]),n("时")]):null,E(r.practiceDurationAvg)>0||N(r.practiceDurationAvg)>0?e("div",null,[e("span",null,[e(D,{from:0,to:N(r.practiceDurationAvg)},null)]),n("分")]):null,e("div",null,[e("span",null,[e(D,{from:0,to:_(r.practiceDurationAvg)},null)]),n("秒")])]),e("p",{class:a.TrainDataItemsubTitle},[n("平均每天练习时长")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[E(r.practiceDuration)>0?e("div",null,[e("span",null,[e(D,{from:0,to:E(r.practiceDuration)},null)]),n("时")]):null,E(r.practiceDuration)>0||N(r.practiceDuration)>0?e("div",null,[e("span",null,[e(D,{from:0,to:N(r.practiceDuration)},null)]),n("分")]):null,e("div",null,[e("span",null,[e(D,{from:0,to:_(r.practiceDuration)},null)]),n("秒")])]),e("p",{class:a.TrainDataItemsubTitle},[n("练习总时长")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:r.evaluateUserCount},null),n("/"),e(D,{from:0,to:r.evaluateFrequency},null)])])]),e("p",{class:a.TrainDataItemsubTitle},[n("评测人数/次数")])]),e("div",{class:a.TrainDataItem},[e("p",{class:a.TrainDataItemTitle},[e("div",null,[e("span",null,[e(D,{from:0,to:r.publishUserCount},null),n("/"),e(D,{from:0,to:r.publishCount},null)])])]),e("p",{class:a.TrainDataItemsubTitle},[n("作品人数/数量")])])]),e("div",{class:a.TrainDataTopRight},null)]),e("div",{class:a.chatrs},[e("div",{ref:d,style:{height:r.height,width:r.width}},null)]),e("div",{class:[a.tableWrap,a.noSort]},[e(j,{class:a.classTable,loading:o.loading,columns:W(),"onUpdate:sorter":M,data:o.tableList},{empty:()=>e(Q,null,null)})])])])}}),Ne=k({name:"student-studentList",props:{timer:{type:Array,defaut:()=>[]}},setup(b,{emit:I,expose:i}){const p=T({searchWord:"",orchestraType:null,courseTypeCode:null,subjectId:null,classId:null,studentType:null,loading:!1,pagination:{page:1,rows:10,pageTotal:4},tableList:[]}),d=T({ase:0,sortType:1}),x=J(()=>(console.log("ranking===>"),b.timer)),h=async()=>{p.loading=!0;try{const s=await Se({...p.pagination,...d,...B(x.value,["startTime","endTime"],"YYYY-MM-DD")});p.tableList=s.data.rows,p.pagination.pageTotal=s.data.total}catch(s){console.log(s)}p.loading=!1};i({getList:h}),h(),H(async()=>{ne(()=>{document.querySelectorAll(".n-data-table-sorter").forEach(f=>{f.style.display="none"})})});const r=s=>{if(!s)d.ase=0,d.sortType=1,o.sortOrder=!1,u.sortOrder=!1,c.sortOrder=!1;else{const f={practiceDuration:1,practiceDays:2,practiceDurationAvg:3};d.sortType=f[s.columnKey],s.columnKey=="practiceDuration"&&(u.sortOrder=s.order,o.sortOrder=!1,c.sortOrder=!1),s.columnKey=="practiceDays"&&(o.sortOrder=s.order,u.sortOrder=!1,c.sortOrder=!1),s.columnKey=="practiceDurationAvg"&&(c.sortOrder=s.order,o.sortOrder=!1,u.sortOrder=!1),d.ase=s.order=="ascend"?1:0}h()},o=T({title(){return e(F,{showArrow:!1,placement:"top-start"},{trigger:()=>e("div",{class:a.cell},[n("练习天数"),e("img",{class:a.sortIcon,src:o.sortOrder==="descend"?U:o.sortOrder==="ascend"?q:P},null)]),default:o.sortOrder==="descend"?"点击升序":o.sortOrder==="ascend"?"取消排序":"点击降序"})},key:"practiceDays",sorter:!0,sortOrder:!1,render(s){return e(C,null,[s.practiceDays?s.practiceDays:0,n("天")])}}),u=T({title(){return e(F,{showArrow:!1,placement:"top-start"},{trigger:()=>e("div",{class:a.cell},[n("练习总时长"),e("img",{class:a.sortIcon,src:u.sortOrder==="descend"?U:u.sortOrder==="ascend"?q:P},null)]),default:u.sortOrder==="descend"?"点击升序":u.sortOrder==="ascend"?"取消排序":"点击降序"})},key:"practiceDuration",sorter:!0,sortOrder:!1,render(s){return e(C,null,[s.practiceDuration?Y(s.practiceDuration,1):0])}}),c=T({title(){return e(F,{showArrow:!1,placement:"top-start"},{trigger:()=>e("div",{class:a.cell},[n("平均每天练习时长"),e("img",{class:a.sortIcon,src:c.sortOrder==="descend"?U:c.sortOrder==="ascend"?q:P},null)]),default:c.sortOrder==="descend"?"点击升序":c.sortOrder==="ascend"?"取消排序":"点击降序"})},key:"practiceDurationAvg",sorter:!0,sortOrder:!1,render(s){return e(C,null,[s.practiceDurationAvg?Y(s.practiceDuration,1):0])}}),g=()=>[{title:"姓名",key:"studentName"},{title:"手机号",key:"studentPhone"},o,u,c];return()=>e("div",{class:a.listWrap},[e("div",{class:a.tableWrap},[e(j,{class:a.classTable,loading:p.loading,columns:g(),data:p.tableList,"onUpdate:sorter":r},{empty:()=>e(Q,null,null)}),e(ue,{page:p.pagination.page,"onUpdate:page":s=>p.pagination.page=s,pageSize:p.pagination.rows,"onUpdate:pageSize":s=>p.pagination.rows=s,pageTotal:p.pagination.pageTotal,"onUpdate:pageTotal":s=>p.pagination.pageTotal=s,onList:h,sync:!0},null)])])}}),Ue=k({name:"data-guide",emits:["close"],setup(b,{emit:I}){const i=T({box:{height:"0px"},show:!1,steps:[{ele:"",eleRect:{},img:z("data1.png"),handStyle:{top:"0.91rem"},imgStyle:{top:v(-4),left:v(-100),width:v(472),height:v(256)},btnsStyle:{bottom:v(30),left:v(-110)},boxStyle:{borderRadius:"25px"},eleRectPadding:{left:14,top:14,width:28,height:28}},{ele:"",img:z("data2.png"),imgStyle:{top:v(-4),left:v(-100),width:v(509),height:v(230)},btnsStyle:{bottom:v(30),left:v(-110)},boxStyle:{borderRadius:"25px"},eleRectPadding:{left:14,top:14,width:28,height:28}},{ele:"",img:z("data3.png"),imgStyle:{top:"100%",left:v(-105),width:v(438),height:v(230)},btnsStyle:{bottom:v(30),left:v(-115)},boxStyle:{borderRadius:"25px"},eleRectPadding:{left:14,top:14,width:28,height:28}}],step:0}),p=S(!1),d=S({});(async()=>{try{const g=localStorage.getItem("teacher-guideInfo");g?d.value=JSON.parse(g)||null:d.value={},d.value&&d.value.dataGuide?p.value=!1:p.value=!0}catch(g){console.log(g)}})();const h=()=>{var s,f,A,l;const g=document.getElementById("data-".concat(i.step));if(g){const m=g.getBoundingClientRect(),w=((s=i.steps[i.step].eleRectPadding)==null?void 0:s.left)||0,L=((f=i.steps[i.step].eleRectPadding)==null?void 0:f.top)||0,W=((A=i.steps[i.step].eleRectPadding)==null?void 0:A.width)||0,M=((l=i.steps[i.step].eleRectPadding)==null?void 0:l.height)||0;i.box={left:m.x-w+"px",top:m.y-L+"px",width:m.width+W+"px",height:m.height+M+"px"}}else u()},r=async g=>{try{if(g!=="data-module")return;d.value?d.value.dataGuide=!1:d.value={dataGuide:!1};try{ae({guideTag:"teacher-guideInfo",guideValue:JSON.stringify(d.value)})}catch(s){console.log(s)}i.step=0,h(),p.value=!0}catch(s){}};H(()=>{h(),window.addEventListener("resize",o),$.on("teacher-guideInfo",r)});const o=()=>{h()};fe(()=>{window.removeEventListener("resize",o),$.off("teacher-guideInfo",r)});const u=()=>{if(i.step>=4){c();return}i.step=i.step+1,h()},c=async()=>{d.value?d.value.dataGuide=!0:d.value={dataGuide:!0};try{ae({guideTag:"teacher-guideInfo",guideValue:JSON.stringify(d.value)})}catch(g){console.log(g)}p.value=!1};return()=>{var g;return e(C,null,[p.value?ye(e("div",{"onUpdate:show":s=>p.value=s,class:["n-modal-mask","n-modal-mask-guide"]},[e("div",{class:O.content,onClick:()=>u()},[e("div",{class:O.backBtn,onClick:s=>{s.stopPropagation(),c()}},[n("跳过")]),e("div",{class:O.box,style:{...i.box,...(g=i.steps[i.step])==null?void 0:g.boxStyle},id:"modeType-".concat(i.step)},[i.steps.map((s,f)=>{var A,l,m,w;return e("div",{onClick:L=>L.stopPropagation(),class:O.item,style:s.type=="bottom"?{display:f===i.step?"":"none",left:"".concat((A=s.eleRect)==null?void 0:A.left,"px"),top:"-".concat((l=s.imgStyle)==null?void 0:l.height)}:{display:f===i.step?"":"none",left:"".concat((m=s.eleRect)==null?void 0:m.left,"px"),top:"".concat((w=i.box)==null?void 0:w.height)}},[e("img",{class:O.img,style:s.imgStyle,src:s.img},null),e("div",{class:O.btns,style:s.btnsStyle},[i.step+1==i.steps.length?e(C,null,[e("div",{class:[O.endBtn],onClick:()=>c()},[n("完成")]),e("div",{class:O.nextBtn,onClick:()=>{i.step=0,h()}},[n("再看一遍")])]):e("div",{class:O.btn,onClick:()=>u()},[n("下一步 ("),i.step+1,n("/"),i.steps.length,n(")")])])])})])])]),[[he,p.value,"show"]]):null])}}}),Qe=k({name:"data-module",setup(){const b=S("training"),I=re();Te(c=>{c.form.tabName&&(b.value=c.form.tabName)});const i=S(),p=S(),d=S(),x=c=>{ie(c,"tabName",I)},h=S(!1),r=S([ee(new Date().getTime()),te(new Date().getTime())]),o=()=>{console.log(r.value),i.value&&i.value.getList(),p.value&&p.value.getList(),d.value&&d.value.getList()},u=()=>{console.log("点击重置"),r.value=[ee(new Date().getTime()),te(new Date().getTime())],ne(()=>{o()})};return H(()=>{setTimeout(()=>{h.value=!0},800)}),()=>e("div",null,[e("div",{class:R.listWrap},[e(ve,{"onUpdate:value":[c=>x(c),c=>b.value=c],class:R.customTabs,value:b.value,size:"large",animated:!1,"pane-wrapper-style":"margin: 0 -4px","pane-style":"padding-left: 4px; padding-right: 4px; box-sizing: border-box;"},{default:()=>[e(K,{name:"training",tab:"作业统计"},{default:()=>[e(Le,{ref:i,timer:r.value},null)],tab:()=>e("span",{id:"data-0"},[n("作业统计")])}),e(K,{name:"practice",tab:"学练数据"},{default:()=>[e(ke,{ref:p,timer:r.value},null)],tab:()=>e("span",{id:"data-1"},[n("学练数据")])}),e(K,{name:"ranking",tab:"学练排行"},{default:()=>[e(Ne,{ref:d,timer:r.value},null)],tab:()=>e("span",{id:"data-2"},[n("学练排行")])})],suffix:()=>e(C,null,[e("div",{class:R.homeStudyInfoDate},[e(le,null,{default:()=>[e(be,De({clearable:!1},{value:r.value,"onUpdate:value":c=>r.value=c,separator:"-",type:"daterange",timerValue:r.value}),null),e(G,{type:"primary",class:R.searchBtn,onClick:()=>o()},{default:()=>[n("搜索")]}),e(G,{type:"primary",onClick:()=>u(),ghost:!0,class:R.resetBtn},{default:()=>[n("重置")]})]})])])}),h.value?e(Ue,null,null):null])])}});export{Qe as default};