1 |
- System.register(["./index-legacy-e9c345f0.js","./urlUtils-legacy-34e0d3e5.js","./index-legacy-191e21ed.js","./index-legacy-664d068b.js","./index-legacy-a2c12755.js","./add-legacy-e7111c9d.js","./api-legacy-6de08d1c.js","./cordWrap-legacy-74b60b52.js","./index-legacy-48de7c33.js","./index-legacy-baf4c411.js","./searchs-legacy-3b019a5a.js"],(function(e,t){"use strict";var l,a,s,n,i,o,d,c,r,u,p,g,m,h,y,v,b,f,w,k,x,S,I,C,L,T,R,j,U,B,F,$,D,G,P,N,V,W;return{setters:[e=>{l=e.d,a=e.e,s=e.b,n=e.c,i=e.r,o=e.f,d=e.o,c=e.k,r=e.Z,u=e.q,p=e._,g=e.$,m=e.F,h=e.a,y=e.u,v=e.N,b=e.g,f=e.x,w=e.X,k=e.j,x=e.ck},e=>{S=e.v,I=e.s,C=e.g},e=>{L=e.S},e=>{T=e.C},e=>{R=e.P},e=>{j=e.a},e=>{U=e.c},e=>{B=e.s,F=e.a,$=e.c,D=e.T,G=e.b,P=e.h},e=>{N=e.g,V=e.s},e=>{W=e.T},null],execute:function(){const O=""+new URL("studentTitle-8db8be71.png",t.meta.url).href,A=""+new URL("strudentCore-ce06266f.png",t.meta.url).href,J=l({props:{activeRow:{type:Object,default:()=>({id:""})},gradeNumList:{type:Array,default:()=>[]},classArray:{type:Array,default:()=>[]}},name:"resetStudent",emits:["close","getList"],setup(e,{emit:t}){a({uploading:!1}),s();const l=n();i();const r=i(S()+`/classroom-app/#/student-register?sId=${l.getUserInfo.schoolInfos[0].id}`),u=a({saveLoading:!1,image:null,shareLoading:!1}),p=()=>{if(!u.saveLoading)if(u.saveLoading=!0,u.image)g();else{const e=document.getElementById("preview-container");P(e,{allowTaint:!0,useCORS:!0,backgroundColor:null}).then((async e=>{const t=e.toDataURL("image/png");u.image=t,g()})).catch((()=>{u.saveLoading=!1}))}},g=async()=>{setTimeout((()=>{u.saveLoading=!1}),100);const e=document.createElement("a");e.setAttribute("download","报名图片.png"),e.href=u.image,e.click()};return()=>o("div",{class:[I.addStudentWrap]},[o("div",{onClick:()=>{console.log("点击"),t("close")}},[o(d,{src:B,previewDisabled:!0,class:I.studentCLose},null)]),o(d,{previewDisabled:!0,class:I.stunentStart,src:F},null),o(d,{class:I.addTitle,previewDisabled:!0,src:O},null),o("div",{class:I.addStudentInfo,id:"preview-container"},[o(d,{class:I.studentInfoBg,previewDisabled:!0,src:A},null),o("div",{class:I.studentCore},[o("img",{alt:"img",crossorigin:"anonymous",class:I.schoolLogo,src:l.getUserInfo.schoolInfos[0].logo+`?some=${(new Date).getTime()}`},null),o("div",{class:I.studentCoreInfo},[o("h2",null,[l.getUserInfo.schoolInfos[0].name]),o("p",{class:I.studentCoreInfoSubtitle},[c("邀请您的孩子加入"),o("span",null,[c("数字化乐器课堂")])]),o("div",{class:I.codewrap},[o("img",{src:$,class:I.codewrapBg,alt:""},null),o(D,{margin:0,class:I.codewrapImg,text:r.value,size:119},null)]),o("div",{class:I.codewrapSubmit},[o(d,{previewDisabled:!0,src:G},null),c("请使用微信扫码"),o("span",null,[c("完成报名")])," "])])])]),o("div",{class:I.studentBottom},[o("p",null,[c("请将二维码图片发送给学生家长,扫码完成报名")]),o("div",{class:I.downBtn,onClick:p},[c("下载图片")])])])}}),q=l({name:"coai-guide",emits:["close"],setup(e,{emit:t}){const l=a({box:{height:"0px"},show:!1,steps:[{ele:"",eleRect:{},img:N("student1.png"),handStyle:{top:"0.91rem"},imgStyle:{left:r(-64),width:r(518),height:r(256)},btnsStyle:{bottom:"30px",left:"-90px"},eleRectPadding:{left:7,top:7,width:14,height:14}},{ele:"",img:N("student2.png"),imgStyle:{top:"100%",left:"-265px",width:"515px",height:"227px"},btnsStyle:{bottom:"30px",left:r(-90)},eleRectPadding:{left:7,top:7,width:14,height:14}}],step:0}),s=i(!1),n=localStorage.getItem("teacher-guideInfo");n&&JSON.parse(n).studentGuide?s.value=!1:s.value=!0;const d=()=>{const e=document.getElementById(`student-${l.step}`);if(e){const t=e.getBoundingClientRect(),a=l.steps[l.step].eleRectPadding?.left||0,s=l.steps[l.step].eleRectPadding?.top||0,n=l.steps[l.step].eleRectPadding?.width||0,i=l.steps[l.step].eleRectPadding?.height||0;l.box={left:t.x-a+"px",top:t.y-s+"px",width:t.width+n+"px",height:t.height+i+"px"},console.log(`coai-${l.step}`,l.box)}};u((()=>{d()}));const h=()=>{l.step>=4?y():(l.step=l.step+1,d())},y=()=>{let e=JSON.parse(localStorage.getItem("teacher-guideInfo")||"{}")||null;e?e.studentGuide=!0:e={studentGuide:!0},localStorage.setItem("teacher-guideInfo",JSON.stringify(e)),s.value=!1};return()=>o(m,null,[s.value?p(o("div",{"onUpdate:show":e=>s.value=e,class:["n-modal-mask","n-modal-mask-guide"]},[o("div",{class:V.content,onClick:()=>h()},[o("div",{class:V.backBtn,onClick:e=>{e.stopPropagation(),y()}},[c("跳过")]),o("div",{class:V.box,style:{...l.box},id:`modeType-${l.step}`},[l.steps.map(((e,t)=>o("div",{onClick:e=>e.stopPropagation(),class:V.item,style:"bottom"==e.type?{display:t===l.step?"":"none",left:`${e.eleRect?.left}px`,top:`-${e.imgStyle?.height}`}:{display:t===l.step?"":"none",left:`${e.eleRect?.left}px`,top:`${l.box?.height}`}},[o("img",{class:V.img,style:e.imgStyle,src:e.img},null),o("div",{class:V.btns,style:e.btnsStyle},[l.step+1==l.steps.length?o(m,null,[o("div",{class:[V.endBtn],onClick:()=>y()},[c("完成")]),o("div",{class:V.nextBtn,onClick:()=>{l.step=0,d()}},[c("再看一遍")])]):o("div",{class:V.btn,onClick:()=>h()},[c("下一步 ("),l.step+1,c("/"),l.steps.length,c(")")])])])))])])]),[[g,s.value,"show"]]):null])}});e("default",l({name:"student-studentList",setup(e,{emit:t}){const l=a({searchForm:{keyword:"",gender:null,classGroupId:null,membership:null},searchWord:"",orchestraType:null,courseTypeCode:null,subjectId:null,classId:null,studentType:null,loading:!1,pagination:{page:1,rows:10,pageTotal:4},tableList:[],classList:[],addStudentVisible:!1}),s=h(),n=y(),r=i(!1),S=()=>{l.pagination.page=1,F()},B=()=>{l.searchForm={keyword:"",gender:null,classGroupId:null,membership:null},S()},F=async()=>{try{const e=await C({...l.searchForm,...l.pagination});l.tableList=e.data.rows,l.pagination.pageTotal=e.data.total,l.tableList.length>0&&setTimeout((()=>{r.value=!0}),500)}catch(e){console.log(e)}console.log("getList")};u((()=>{F(),(async()=>{try{const e=await U({page:1,rows:999});l.classList=e.data.rows.map((e=>({label:e.name,value:e.id})))}catch(e){console.log(e)}})()}));const $=e=>{n.push({path:"/studentDetail",query:{...s.query,studentId:e.id,studentName:e.nickname}})};return()=>o("div",{class:I.listWrap},[o("div",{class:I.searchList},[o(v,{"label-placement":"left",inline:!0},{default:()=>[o(b,null,{default:()=>[o(L,f({placeholder:"请输入学生姓名"},{class:I.searchInput,searchWord:l.searchForm.keyword,onChangeValue:e=>l.searchForm.keyword=e}),null)]}),o(b,null,{default:()=>[o(T,f({options:[{label:"学生性别",value:null},{label:"男",value:1},{label:"女",value:0}],placeholder:"性别",clearable:!0,inline:!0},{value:l.searchForm.gender,"onUpdate:value":e=>l.searchForm.gender=e}),null)]}),o(b,null,{default:()=>[o(T,f({options:[{label:"年级班级",value:null},...l.classList],placeholder:"年级班级",clearable:!0,inline:!0},{value:l.searchForm.classGroupId,"onUpdate:value":e=>l.searchForm.classGroupId=e}),null)]}),o(b,null,{default:()=>[o(T,f({options:[{label:"学生类型",value:null},{label:"会员",value:!0},{label:"普通",value:!1}],placeholder:"学生类型",clearable:!0,inline:!0},{value:l.searchForm.membership,"onUpdate:value":e=>l.searchForm.membership=e}),null)]}),o(b,null,{default:()=>[o(w,{justify:"end"},{default:()=>[o(k,{type:"primary",class:"searchBtn",onClick:S},{default:()=>[c("搜索")]}),o(k,{type:"primary",ghost:!0,class:"resetBtn",onClick:B},{default:()=>[c("重置")]})]})]})]})]),o(k,f({id:"student-0"},{onClick:()=>{l.addStudentVisible=!0},class:I.addBtn,type:"primary"}),{default:()=>[c("新增学生")],icon:()=>o(m,null,[o(d,{class:I.addBtnIcon,previewDisabled:!0,src:j},null)])}),o("div",{class:I.tableWrap},[o(x,{class:I.classTable,loading:l.loading,columns:[{title:"学生姓名",key:"nickname"},{title:"手机号",key:"phone"},{title:"性别",key:"gender",render:e=>o(m,null,[e.gender+""!="null"?"0"==e.gender?"女":"男":"--"])},{title:"年级班级",key:"classGroupName"},{title:"学生类型",key:"vipMember",render:e=>o(m,null,[e.vipMember?"会员":"普通"])},{title:"操作",key:"id",render:(e,t)=>o(m,null,[o(k,0==t?f({id:"student-1"},{text:!0,type:"primary",onClick:()=>$(e)}):{text:!0,type:"primary",onClick:()=>$(e)},{default:()=>[c("详情")]})])}],data:l.tableList},{empty:()=>o(W,null,null)}),o(R,{page:l.pagination.page,"onUpdate:page":e=>l.pagination.page=e,pageSize:l.pagination.rows,"onUpdate:pageSize":e=>l.pagination.rows=e,pageTotal:l.pagination.pageTotal,"onUpdate:pageTotal":e=>l.pagination.pageTotal=e,onList:F,sync:!0,saveKey:"orchestraRegistration-key"},null)]),l.addStudentVisible?p(o("div",{"onUpdate:show":e=>l.addStudentVisible=e,class:"n-modal-mask"},[o(J,{onClose:()=>{l.addStudentVisible=!1}},null)]),[[g,l.addStudentVisible,"show"]]):null,r.value?o(q,null,null):null])}}))}}}));
|