1 |
- System.register(["./index.module-legacy-f2b0f9bd.js","./index-legacy-4f2516a1.js","./index-legacy-8aa8edaa.js","./index-legacy-fd682661.js","./api-legacy-6ff284b8.js","./index-legacy-f073bf97.js","./index-legacy-47e74465.js","./teacherIcon-legacy-3eeb62c3.js","./dateFormat-legacy-8633a26e.js","./searchArray-legacy-9842eab3.js","./index-legacy-c0ba6859.js","./unqualified-legacy-0d5e0ffe.js","./contants-legacy-276987e2.js","./index-legacy-3b06cf1f.js","./Slider-legacy-03a9d790.js"],(function(e,a){"use strict";var t,n,i,l,s,r,o,u,c,d,g,p,m,v,y,T,f,w,h,D,b,k,x,I,S,L,j,Y,N,C,M,R,U,A,B,q;return{setters:[e=>{t=e.s},e=>{n=e.S},e=>{i=e.C},e=>{l=e.P},e=>{s=e.o,r=e.q,o=e.s},e=>{u=e.d,c=e.e,d=e.r,g=e.b,p=e.n,m=e.f,v=e.t,y=e.k,T=e.V,f=e.w,w=e.j,h=e.a,D=e.N,b=e.g,k=e.x,x=e.c9,I=e.v},e=>{S=e.C},e=>{L=e.d},e=>{j=e.g,Y=e.a},e=>{N=e.t},e=>{C=e.T},e=>{M=e.n,R=e.u,U=e.q},e=>{A=e.N,B=e.e},e=>{q=e.T},null],execute:function(){const a=u({props:{activeRow:{type:Object,default:()=>({studentLessonTrainingId:""})},total:{type:Number,default:0},current:{type:Number,default:0}},name:"TrainingDetails",emits:["close","next","pre"],setup(e,{emit:a,expose:n}){c({uploading:!1});const i=d({studentName:"",submitTime:"",trainingStatus:"",studentAvatar:"",studentLessonTrainingDetails:[]});g(),d();const l=async e=>{try{const a=await s({studentLessonTrainingId:e}),t=a.data.studentLessonTrainingDetails.map((e=>{const a=((e,a)=>{let t=[];return"EVALUATION"===e?(t=[`${B[a.evaluateDifficult]}`,"全部小节",`${a.trainingTimes}分合格`],console.log("configJson.evaluateDifficult--",t)):(t=[`${a.practiceChapterBegin}-${a.practiceChapterEnd}小节`,`速度${a.practiceSpeed}`,`${a.trainingTimes}分钟`],console.log("configJson.evaluateDifficult",t)),t})(e.trainingType,JSON.parse(e.trainingContent));return{...e,coverImg:e.titleImg,allTimes:JSON.parse(e.trainingContent).trainingTimes,typeList:a||[]}}));i.value={...a.data,studentLessonTrainingDetails:t}}catch(a){console.log(a)}};return n({getTrainingDetail:l}),p((()=>{l(e.activeRow.studentLessonTrainingId)})),()=>m("div",{class:[t.trainingDetails]},[m("div",{class:t.studentList},[m("div",{class:t.studentHeaderWrap},[m("div",{class:t.studentHeader},[m("div",{class:t.studentHeaderBorder},[m(v,{class:t.studentHeaderImg,src:i.value.studentAvatar?i.value.studentAvatar:L,previewDisabled:!0},null)])]),m("div",{class:t.workafterInfo},[m("h4",null,[i.value.studentName," ",m("div",{class:t.workafterInfoDot},[y("学生")])]),m("p",null,[y("提交时间:"),i.value.submitTime?T(new Date(i.value.submitTime)).format("YYYY-MM-DD"):"--"])])]),"UNSUBMITTED"==i.value.trainingStatus?m(v,{previewDisabled:!0,class:t.workStatus,src:M},null):null,"SUBMITTED"==i.value.trainingStatus?m(v,{previewDisabled:!0,class:t.workStatus,src:R},null):null,"TARGET"==i.value.trainingStatus?m(v,{previewDisabled:!0,class:t.workStatus,src:U},null):null]),m(A,{style:"max-height:400px",trigger:"none"},{default:()=>[m("div",{class:t.workList},[i.value.studentLessonTrainingDetails.map((e=>m(C,{style:{marginBottom:"20px"},isDisabled:!0,isDelete:!1,item:e},null)))])]}),m(f,{class:[t.btnGroups,t.nextWrap],justify:"space-between"},{default:()=>[m("div",{class:t.allTotal},[e.current,y("/"),e.total,y("名学生")]),m("div",null,[m(f,null,{default:()=>[m(w,{disabled:e.current<=1,round:!0,type:"primary",onClick:()=>{a("pre")}},{default:()=>[y("上一名")]}),m(w,{disabled:e.current>=e.total,round:!0,type:"primary",onClick:()=>{a("next")}},{default:()=>[y("下一名")]})]})])]})])}});e("default",u({name:"student-studentList",setup(e,{emit:s}){const u=c({searchForm:{keyword:"",trainingStatus:null},loading:!1,pagination:{page:1,rows:10,pageTotal:4},tableList:[],workInfo:{createTime:"",expireDate:"",teacherAvatar:"",teacherName:""},detailVisiable:!1,activeRow:null,index:0}),g=d([j((new Date).getTime()),Y((new Date).getTime())]),C=d(),M=h(),R=d([{name:"班级管理",path:"/classList"},{name:M.query.name,path:"/classDetail"},{name:M.query.teacherName,path:"/afterWorkDetail"}]),U=()=>{u.pagination.page=1,B(),console.log("search",u)},A=()=>{u.searchForm={keyword:"",trainingStatus:null},g.value=[j((new Date).getTime()),Y((new Date).getTime())],U()},B=async()=>{u.loading=!0;try{const e=await r({trainingId:M.query.trainingId,...u.searchForm,...u.pagination});u.tableList=e.data.rows,u.pagination.pageTotal=e.data.total,u.loading=!1}catch(e){u.loading=!1,console.log(e)}};p((()=>{(async()=>{console.log(M.query);try{const e=await o({trainingId:M.query.trainingId});u.workInfo={...e.data}}catch(e){console.log(e)}})(),B()}));const V=()=>[{title:"学生姓名",key:"studentName"},{title:"最后提交时间",key:"submitTime",render:e=>e.submitTime?T(e.submitTime).format("YYYY-MM-DD"):"--"},{title:"训练状态",key:"sex",render:e=>m("div",null,["UNSUBMITTED"==e.trainingStatus?m("p",{class:t.nosub},[y("未提交")]):null,"SUBMITTED"==e.trainingStatus?m("p",{class:t.ison},[y("不合格")]):null,"TARGET"==e.trainingStatus?m("p",{class:t.isok},[y("合格")]):null])},{title:"操作",key:"id",render:(e,a)=>m(w,{text:!0,type:"primary",onClick:()=>{((e,a)=>{console.log(a,"index"),u.index=a+1,u.activeRow=e,u.detailVisiable=!0})(e,a)}},{default:()=>[y("详情")]})}];return()=>m("div",null,[m(S,{list:R.value},null),m("div",{class:t.listWrap},[m("div",{class:t.teacherList},[m("div",{class:t.teacherHeader},[m("div",{class:t.teacherHeaderBorder},[m(v,{class:t.teacherHeaderImg,src:u.workInfo.teacherAvatar?u.workInfo.teacherAvatar:L,previewDisabled:!0},null)])]),m("div",{class:t.workafterInfo},[m("h4",null,[u.workInfo.teacherName]),m("p",null,[y("布置时间:"),T(u.workInfo.createTime).format("YYYY-MM-DD"),y(" |")," ",m("span",null,[y("截止时间:"),T(u.workInfo.expireDate).format("YYYY-MM-DD")])])])]),m("div",{class:t.searchList},[m(D,{"label-placement":"left",inline:!0},{default:()=>[m(b,null,{default:()=>[m(n,k({placeholder:"请输入学生姓名"},{class:t.searchInput,searchWord:u.searchForm.keyword,onChangeValue:e=>u.searchForm.keyword=e}),null)]}),m(b,null,{default:()=>[m(i,k({options:[{label:"训练状态",value:null},...N],placeholder:"训练状态",clearable:!0,inline:!0},{value:u.searchForm.trainingStatus,"onUpdate:value":e=>u.searchForm.trainingStatus=e}),null)]}),m(b,null,{default:()=>[m(f,{justify:"end"},{default:()=>[m(w,{type:"primary",class:"searchBtn",onClick:U},{default:()=>[y("搜索")]}),m(w,{type:"primary",ghost:!0,class:"resetBtn",onClick:A},{default:()=>[y("重置")]})]})]})]})]),m("div",{class:t.tableWrap},[m(x,{class:t.classTable,loading:u.loading,columns:V(),data:u.tableList},{empty:()=>m(q,null,null)}),m(l,{page:u.pagination.page,"onUpdate:page":e=>u.pagination.page=e,pageSize:u.pagination.rows,"onUpdate:pageSize":e=>u.pagination.rows=e,pageTotal:u.pagination.pageTotal,"onUpdate:pageTotal":e=>u.pagination.pageTotal=e,onList:B,sync:!0},null)])]),m(I,{show:u.detailVisiable,"onUpdate:show":e=>u.detailVisiable=e,preset:"card",class:["modalTitle background",t.wordDetailModel],title:"训练详情"},{default:()=>[m(a,{onNext:()=>(++u.index,u.activeRow=u.tableList[u.index-1],void C.value.getTrainingDetail(u.activeRow.studentLessonTrainingId)),onPre:()=>(--u.index,u.activeRow=u.tableList[u.index-1],void C.value.getTrainingDetail(u.activeRow.studentLessonTrainingId)),ref:C,onClose:()=>u.detailVisiable=!1,total:u.tableList.length,current:u.index,activeRow:u.activeRow},null)]})])}}))}}}));
|