1 |
- var Y=Object.defineProperty,B=Object.defineProperties;var O=Object.getOwnPropertyDescriptors;var G=Object.getOwnPropertySymbols;var $=Object.prototype.hasOwnProperty,R=Object.prototype.propertyIsEnumerable;var q=(e,s,a)=>s in e?Y(e,s,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[s]=a,v=(e,s)=>{for(var a in s||(s={}))$.call(s,a)&&q(e,a,s[a]);if(G)for(var a of G(s))R.call(s,a)&&q(e,a,s[a]);return e},T=(e,s)=>B(e,O(s));import{C as W}from"./index.055bf67a.js";import{d as A,T as I,a as t,F as b,b as n,t as p,q as _,m as Z,B as y,I as j,y as L,P as x,h as m,D as k,C as E,U as K,x as Q,Q as J,S as H,z as w,u as X,G as tt,H as C}from"./vendor.85b33d80.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import{i as et}from"./icon_teacher.2c3a434a.js";import{t as st,m as at}from"./teacher_cert.5c45c8b4.js";import{S as z}from"./index.571160db.js";import{C as it}from"./index.ad9513d3.js";import{r as u,p as ot,k as rt,s as U}from"./index.ebb89ced.js";/* empty css */import{i as nt}from"./icon_upload_poster.81da3a98.js";import{C as lt}from"./index.cfe7f947.js";import{C as ct}from"./index.05aaf1a1.js";/* empty css *//* empty css *//* empty css *//* empty css */import{C as D}from"./index.918ba5ad.js";/* empty css */import{i as ut}from"./icon_timer2.563d016a.js";import{V as dt}from"./video-item.6065a28b.js";/* empty css *//* empty css */import"./icon_checkbox_default.2fe5d57e.js";/* empty css */var ht="./assets/head_bg.7e4b30d5.png",F=Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",default:ht}),pt="./assets/icon_fans.4aea0da2.png",P=Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",default:pt}),mt="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAMAAADypuvZAAAAAXNSR0IArs4c6QAAAQJQTFRFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgICBwcHDAwMFRUVGxsbHR0dIyMjJiYmKCgoKSkpLy8vOTk5Pj4+RUVFT09PWlpaW1tbZWVldHR0eHh4e3t7fHx8gYGBioqKmJiYoKCgq6ursLCwsrKytbW1urq6wcHBysrKysrK0tLS0dHR0tLS0tLS09PT2NjY3t7e4uLi4uLi4+Pj5+fn6urq6+vr7+/v8fHx8fHx8vLy8vLy9fX19/f3+fn5+/v7/Pz8/Pz8/f39/f39/v7+////////sFSKVgAAAFV0Uk5TAAMPExUYHh8rOjw+TlJTVlxeYmZnaWpqbG1vcXFzc3R1d3l7foGFhomPkZOUlpuhpq2ysrS5vsTFysvLzc3Q19rb3eHj5Onr7Ozu8PT2+fn6+/z9/vEW24oAAAGWSURBVEjHpZbldsMwDIXdlMLUxGNmXgcdM3RMrd7/VZZ16TY7puPdnz7+jhNJVxJCRRmm44ZxksSh65gGUlDZijChyCpLkLqHGfLqAqTiY478Cgcp2SnmKrVLLMYIsFABIyTVGEsUV2mm1sBSNWrUOwpMRhFvGTFWUvznv0oBVlTwG0MbK8v+yWmqDqX9LFN1sHr9ernEpfy83sjT+XcA6O6P86jvOqRqtAU9Pa5zIK/nBerwGHKdTrOpL6dY1NlJH4LnzQEWZGVQxIUALuYYUJQVAxZA8LY9VKQMZAohgJvFAmQiRwJBpzVC3XCQK4MA7pfJGy4K5RB0VogbIYoVIDgnDYISFahN3EjUoCMKUvm8uxnq8+SB6O6NYSoQ0pDfFrzlypL7sTtcqAhHUkZXC4yKNYUF+9IcZHnDEFnjbJZpwohhwsMcedrg+N1i2H0rz+cUr7OUGY1lop0hD2vcHuaxWhie3DlojvLbZZ3ZLMXy/9OWtQaA3qjRGmp641NvUOutBHrLh96ao7dQaa5umkui2jr6CZNcBOmsXp5jAAAAAElFTkSuQmCC",N=Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",default:mt});const ft="_teacherHeader_z93cu_7",_t="_headerContent_z93cu_12",gt="_headerCount_z93cu_17",At="_userLogo_z93cu_32",vt="_cert_z93cu_76",bt="_teacherCert_z93cu_94",yt="_piNameSubject_z93cu_108",Ct="_subject_z93cu_112",St="_rTitle_z93cu_124";var i={"teacher-record":"_teacher-record_z93cu_1",teacherHeader:ft,headerContent:_t,headerCount:gt,"open-teacher-info":"_open-teacher-info_z93cu_27",userLogo:At,"teacher-bottom":"_teacher-bottom_z93cu_38","teacher-data":"_teacher-data_z93cu_44","teacher-data_item":"_teacher-data_item_z93cu_49",cert:vt,"teacher-info":"_teacher-info_z93cu_83","teacher-name":"_teacher-name_z93cu_86",teacherCert:bt,piNameSubject:yt,subject:Ct,rTitle:St};const It="_single_6rzx5_1",Tt="_introduction_6rzx5_4",jt="_videoList_6rzx5_10",Lt="_videoItem_6rzx5_16",xt="_fansGroup_6rzx5_37",wt="_fansImage_6rzx5_53",zt="_fansTitle_6rzx5_59",Dt="_videoGroup_6rzx5_65";var d={single:It,introduction:Tt,videoList:jt,videoItem:Lt,"icon-upload":"_icon-upload_6rzx5_25",fansGroup:xt,fansImage:wt,fansTitle:zt,videoGroup:Dt};const Ft="_filterTitle_cir06_1",Pt="_fansGroup_cir06_9",Nt="_introduce_cir06_19",Gt="_fansImage_cir06_25",qt="_fansTitle_cir06_31",kt="_joinContainer_cir06_37",Et="_joinText_cir06_40";var g={filterTitle:Ft,fansGroup:Pt,introduce:Nt,fansImage:Gt,fansTitle:qt,joinContainer:kt,joinText:Et};const Ht=e=>{const s=`../images/${e}`;return{"../images/head_bg.png":F,"../images/icon_fans.png":P,"../images/icon_video.png":N}[s].default};var Ut=A({name:"joinChat",props:{item:{type:Object,default:{}},onClose:{type:Function,default:()=>{}}},data(){return{desc:""}},methods:{async onJoinChat(){try{await u.post("/api-student/imGroupMemberAudit/apply",{data:{groupId:this.item.id,desc:this.desc}}),I("\u7533\u8BF7\u6210\u529F"),this.onClose&&this.onClose()}catch{}}},render(){return t(b,null,[t("div",{class:[g.filterTitle,"van-hairline--bottom"]},[n("\u7533\u8BF7\u5165\u7FA4")]),t("div",{class:g.joinContainer},[t(p,{center:!0,class:g.fansGroup,border:!1},{icon:()=>t(_,{src:this.item.img||Ht("icon_fans.png"),fit:"cover",class:g.fansImage},null),title:()=>t("div",{class:g.fansTitle},[t("div",{class:g.title},[this.item.name]),t("p",{class:["van-ellipsis",g.introduce]},[this.item.introduce])])}),t(Z,{type:"textarea",class:g.joinText,rows:2,maxlength:200,modelValue:this.desc,"onUpdate:modelValue":e=>this.desc=e,placeholder:"\u8BF7\u586B\u5199\u60A8\u7684\u5165\u7FA4\u7533\u8BF7\uFF0C\u4F1A\u66F4\u5FEB\u7684\u88AB\u901A\u8FC7\u5594\uFF5E"},null)]),t("div",{class:"btnGroup"},[t(y,{type:"primary",block:!0,round:!0,style:{width:"70%",margin:"0 auto"},onClick:this.onJoinChat},{default:()=>[n("\u786E\u8BA4")]})])])}});function Mt(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!L(e)}const M=e=>{const s=`../images/${e}`;return{"../images/head_bg.png":F,"../images/icon_fans.png":P,"../images/icon_video.png":N}[s].default};var Vt=A({name:"single",props:{userInfo:{type:Object,default:{}}},data(){const e=this.$route.query;return{videoStatus:!1,chatStatus:!1,teacherId:e.teacherId,fansList:[],chatItem:{},videoItem:{}}},async mounted(){try{const e=await u.post("/api-student/imGroup/queryTeacherGroup",{data:{type:"FAN",createUserId:this.teacherId}});this.fansList=e.data||[]}catch{}},methods:{async onDetail(e){if(!e.hasWaitAuditFlag&&!e.existFlag){this.chatStatus=!0,this.chatItem=e;return}e.existFlag&&ot({api:"joinChatGroup",content:{type:"multi",id:e.id}})}},render(){let e;const s=this.userInfo;return t("div",{class:d.single},[t(z,{icon:"personal",title:"\u4E2A\u4EBA\u98CE\u91C7",size:24,border:!1},{default:()=>[t("p",{class:d.introduction},[s.introduction])]}),s.styleVideo&&s.styleVideo.length>0&&t(z,{icon:"elegant",title:"\u8001\u5E08\u98CE\u91C7",size:24,border:!1},{default:()=>[t("div",{class:d.videoList},[s.styleVideo.map(a=>t("div",{class:d.videoItem,onClick:()=>{this.videoStatus=!0,this.videoItem=a}},[t(_,{src:nt,fit:"cover"},null),t(j,{class:d["icon-upload"],name:M("icon_video.png"),size:26},null)]))])]}),this.fansList&&this.fansList.length>0&&t(z,{icon:"fans",title:"\u7C89\u4E1D\u7FA4",size:24,border:!1},Mt(e=this.fansList.map(a=>t(p,{center:!0,class:d.fansGroup},{icon:()=>t(_,{src:a.img||M("icon_fans.png"),fit:"cover",class:d.fansImage},null),title:()=>t("div",{class:d.fansTitle},[t("div",{class:d.title},[a.name]),t("p",{class:"van-ellipsis"},[a.introduce])]),default:()=>t(y,{type:"primary",size:"small",round:!0,disabled:a.hasWaitAuditFlag,onClick:()=>this.onDetail(a)},{default:()=>[a.existFlag?"\u53BB\u804A\u5929":"",a.hasWaitAuditFlag?"\u5BA1\u6838\u4E2D":"",!a.hasWaitAuditFlag&&!a.existFlag?"\u7533\u8BF7\u5165\u7FA4":""]})})))?e:{default:()=>[e]}),t(x,{show:this.chatStatus,position:"bottom",round:!0,closeable:!0,"safe-area-inset-bottom":!0,onClose:()=>this.chatStatus=!1},{default:()=>[t(Ut,{item:this.chatItem,onClose:()=>this.chatStatus=!1},null)]}),t(x,{show:this.videoStatus,round:!0,class:d.videoGroup,closeable:!0,onClose:()=>this.videoStatus=!1},{default:()=>[t(it,null,null)]})])}});const Yt="_practice_qc3my_1",Bt="_group_qc3my_4",Ot="_price_qc3my_9",$t="_rTag_qc3my_18",Rt="_tag_qc3my_21",Wt="_selectPopup_qc3my_25",Zt="_selectContainer_qc3my_30",Kt="_rTitle_qc3my_33",Qt="_selectPopupContent_qc3my_36",Jt="_desc_qc3my_39",Xt="_times_qc3my_40",te="_selectBtn_qc3my_51",ee="_btn_qc3my_56",se="_protocol_qc3my_75",ae="_arrangeCell_qc3my_79";var o={practice:Yt,group:Bt,price:Ot,rTag:$t,tag:Rt,selectPopup:Wt,selectContainer:Zt,rTitle:Kt,selectPopupContent:Qt,desc:Jt,times:Xt,selectBtn:te,btn:ee,protocol:se,arrangeCell:ae},ie=A({name:"practice",props:{userInfo:{type:Object,default:{}}},data(){return{teacherId:this.$route.query.teacherId,agreeStatus:!1,teacherSubjectList:[],subjectStatus:!1,subjectInfo:{subjectPrice:0,courseMinutes:0,subjectName:"",subjectId:0},courseNum:4,calendarList:[],selectCourseList:[],coursePlanStatus:!1,selectStatus:!1,coursePlanList:[],calendarDate:new Date}},async mounted(){try{const s=(await u.get("/api-student/courseSchedule/getTeacherSubjectPrice",{params:{teacherId:this.teacherId}})).data||[],l=s.find(S=>S.subjectId===Number(this.userInfo.subjectId))||s[0],{subjectName:r,subjectPrice:c,courseMinutes:f,subjectId:V}=l;this.subjectInfo={subjectPrice:c,courseMinutes:f,subjectName:r,subjectId:V},s.forEach(S=>{S.name=S.subjectName}),this.teacherSubjectList=s,this.getList()}catch{}},computed:{showSelectList(){let s=[...this.selectCourseList];return s.forEach(a=>{a.title=m(a.startTime).format("YYYY-MM-DD")+" "+rt(m(a.startTime).day())+" "+a.start+"~"+a.end}),s},selectType(){return this.selectCourseList.length<this.courseNum?"noEnough":"enough"}},methods:{async onSubmit(){if(this.selectCourseList.length<=0){I("\u8BF7\u9009\u62E9\u8BFE\u7A0B\u65F6\u95F4");return}if(!this.agreeStatus){I("\u8BF7\u5148\u9605\u8BFB\u5E76\u540C\u610F\u300A\u9177\u4E50\u79C0\u5E73\u53F0\u670D\u52A1\u534F\u8BAE\u300B");return}if(this.selectCourseList.length<this.courseNum){this.selectStatus=!0;return}await this._lookCourse()},async getList(e){var s;try{let a={day:m(e||new Date).format("DD"),month:m(e||new Date).format("MM"),year:m(e||new Date).format("YYYY")};const r=(await u.post("/api-student/courseSchedule/createPracticeCourseCalendar",{data:T(v({},a),{studentId:(s=U.user.data)==null?void 0:s.userId,teacherId:this.teacherId})})).data||[];let c={};r.forEach(f=>{c[f.date]=f}),this.calendarList=c}catch{}},onSelectDay(e){const s=e||[];let a=[...this.selectCourseList];console.log(e,a),s.forEach(l=>{!a.some(c=>c.startTime===l.startTime)&&a.push(v({},l))}),a.forEach(l=>{const r=s.some(f=>f.startTime===l.startTime),c=s.findIndex(f=>f.startTime===l.startTime);!r&&a.splice(c,1)}),a.sort((l,r)=>l.startTime>r.startTime?1:l.startTime<r.startTime?-1:0),console.log(a,"list"),this.selectCourseList=[...a]},onCloseTag(e){k.confirm({title:"\u63D0\u793A",message:"\u60A8\u662F\u5426\u8981\u5220\u9664\u8BE5\u9009\u62E9\u7684\u8BFE\u7A0B\uFF1F",confirmButtonColor:"var(--van-primary)"}).then(()=>{const s=this.selectCourseList.findIndex(a=>a.startTime===e.startTime);this.selectCourseList.splice(s,1)})},async _lookCourse(e){try{let s=[];this.selectCourseList.forEach(r=>{s.push({startTime:r.startTime,endTime:r.endTime})}),((await u.post("/api-teacher/courseGroup/lockCourseToCache",{data:{courseNum:this.courseNum,courseType:"PRACTICE",loop:this.selectType==="noEnough"?1:0,teacherId:this.teacherId,timeList:[...s]}})).data||[]).forEach((r,c)=>{this.coursePlanList[c]=T(v({},this.coursePlanList[c]),{startTime:r.startTime,endTime:r.endTime,classNum:c+1})}),this.coursePlanStatus=!0,this.selectStatus=!0,e&&e()}catch(s){const a=s.message;k.alert({title:"\u63D0\u793A",confirmButtonColor:"var(--van-primary)",message:a}).then(()=>{this.getList(this.calendarDate||new Date),this.selectCourseList=[],this.selectStatus=!1})}},async _unLookCourse(){var e;try{await u.get("/api-teacher/courseGroup/unlockCourseToCache",{params:{teacherId:(e=U.user.data)==null?void 0:e.userId}}),this.selectStatus=!1,this.coursePlanList.forEach(s=>{s.startTime="",s.endTime=""})}catch{}},async onReset(){this.coursePlanStatus||this.selectType==="enough"?await this._unLookCourse():this.selectType==="noEnough"&&(this.selectStatus=!1),this.coursePlanStatus=!1},async onSure(){const e=this.coursePlanStatus;await this._lookCourse(()=>{e&&(this.selectStatus=!1)})},async cancelPayment(e){try{await u.post("/api-student/userOrder/orderCancel",{data:{orderNo:e}})}catch{}}},render(){return t(b,null,[t("div",{class:o.practice},[t(E,{class:o.group},{default:()=>[t(p,{title:"\u966A\u7EC3\u8BFE\u6536\u8D39"},{default:()=>t("div",{class:o.price},[t("span",null,[n("\xA5"),this.$filters.moneyFormat(this.subjectInfo.subjectPrice)]),n("/"),this.subjectInfo.courseMinutes,n("\u5206\u949F")])}),t(p,{title:"\u9009\u62E9\u4E13\u4E1A",isLink:!0,value:this.subjectInfo.subjectName,onClick:()=>this.subjectStatus=!0},null),t(p,{title:"\u8BFE\u65F6\u6570"},{default:()=>t(K,{modelValue:this.courseNum,"onUpdate:modelValue":e=>this.courseNum=e,theme:"round",max:12,min:1,buttonSize:22,onChange:()=>{this.selectCourseList=[]}},null)})]}),t("div",{class:o.group},[t(ct,{selectList:this.selectCourseList,list:this.calendarList,maxDays:this.courseNum,nextMonth:e=>this.getList(e),prevMonth:e=>this.getList(e),selectDay:this.onSelectDay,calendarDate:this.calendarDate,"onUpdate:calendarDate":e=>this.calendarDate=e},null)]),t(p,{class:[o.arrangeCell,"mb12"]},{title:()=>t("div",{class:o.rTitle},[t("span",null,[n("\u5DF2\u9009\u62E9\u8BFE\u7A0B\u65F6\u95F4")])]),label:()=>t("div",{class:o.rTag},[this.showSelectList.map(e=>t(b,null,[t(Q,{plain:!0,round:!0,closeable:!0,size:"large",type:"primary",class:o.tag,onClose:()=>this.onCloseTag(e)},{default:()=>[e.title]}),t("br",null,null)]))])}),t("div",{class:o.protocol},[t(lt,{modelValue:this.agreeStatus,"onUpdate:modelValue":e=>this.agreeStatus=e,showHeader:!0,style:{paddingLeft:0,paddingRight:0}},null)]),t(x,{show:this.selectStatus,class:o.selectPopup},{default:()=>[t("div",{class:o.selectContainer},[t("div",{class:o.rTitle},[t("span",null,[n("\u63D0\u793A")])]),t("div",{class:o.selectPopupContent},[t("p",{class:o.desc},[this.selectType==="noEnough"&&!this.coursePlanStatus?"\u60A8\u6240\u9009\u62E9\u7684\u4E0A\u8BFE\u65F6\u95F4\u672A\u8FBE\u5230\u60A8\u8F93\u5165\u7684\u8BFE\u65F6\u6570\uFF0C\u7CFB\u7EDF\u6839\u636E\u5DF2\u9009\u65F6\u95F4\u5C06\u81EA\u52A8\u6309\u5468\u987A\u5EF6\u6392\u8BFE\u3002":"\u60A8\u5DF2\u9009\u62E9\u4EE5\u4E0B\u4E0A\u8BFE\u65F6\u95F4\u6BB5\uFF0C\u65F6\u95F4\u6BB5\u4F1A\u6682\u65F6\u9501\u5B9A\uFF0C\u9501\u5B9A\u671F\u95F4\u5B66\u5458\u4E0D\u53EF\u8D2D\u4E70\u8BE5\u65F6\u95F4\u6BB5\u8BFE\u7A0B\u3002"]),this.coursePlanList&&this.coursePlanList.length>0&&this.coursePlanStatus&&t("p",{class:o.times},[this.coursePlanList.map(e=>t("span",null,[m(e.startTime||new Date).format("YYYY-MM-DD")," ",m(e.startTime||new Date).format("HH:mm"),n("~"),m(e.endTime||new Date).format("HH:mm")]))])]),t("div",{class:o.selectBtn},[t(y,{class:o.btn,type:"primary",round:!0,block:!0,plain:!0,onClick:this.onReset},{default:()=>[this.selectType==="noEnough"?"\u7EE7\u7EED\u9009\u62E9":"\u91CD\u65B0\u9009\u62E9"]}),t(y,{class:o.btn,type:"primary",round:!0,block:!0,onClick:this.onSure},{default:()=>[n("\u786E\u8BA4")]})])])]}),t(J,{show:this.subjectStatus,actions:this.teacherSubjectList,cancelText:"\u53D6\u6D88",closeOnClickAction:!0,onCancel:()=>this.subjectStatus=!1,onSelect:e=>{const{subjectName:s,subjectPrice:a,courseMinutes:l,subjectId:r}=e;this.subjectInfo={subjectPrice:a,courseMinutes:l,subjectName:s,subjectId:r},this.subjectStatus=!1}},null)]),t(H,{offsetBottom:0,position:"bottom"},{default:()=>[t("div",{class:"btnGroup",style:{background:"#fff",paddingTop:"10px"}},[t(y,{block:!0,round:!0,type:"primary",onClick:this.onSubmit},{default:()=>[n("\u786E\u8BA4\u7EA6\u8BFE")]})])]})])}});const oe="_liveList_ants7_1",re="_liCover_ants7_4",ne="_liContent_ants7_10",le="_liTitle_ants7_13",ce="_avatar_ants7_22",ue="_liUserInfo_ants7_29",de="_userInfo_ants7_30",he="_num_ants7_42",pe="_price_ants7_45",me="_liveGroup_ants7_53";var h={liveList:oe,liCover:re,liContent:ne,liTitle:le,avatar:ce,liUserInfo:ue,userInfo:de,num:he,price:pe,liveGroup:me};function fe(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!L(e)}var _e=A({name:"live",data(){return{list:[],dataShow:!0,loading:!1,finished:!1,params:{groupStatus:"APPLY",page:1,rows:20}}},mounted(){this.getList()},methods:{formatTime(e){let s=m(e||new Date);const a=["\u5468\u65E5","\u5468\u4E00","\u5468\u4E8C","\u5468\u4E09","\u5468\u56DB","\u5468\u4E94","\u5468\u516D"];return console.log(s.day()),s.format("YYYY-MM-DD")+`(${a[s.day()]})`},async getList(){try{let e=this.params;const a=(await u.post("/api-student/courseGroup/queryPageCourseGroup",{data:v({},e)})).data||{};if(this.list.length>0&&a.pageNo===1)return;this.list=this.list.concat(a.rows||[]),this.finished=a.pageNo>=a.totalPage,this.params.page=a.pageNo+1,this.dataShow=this.list.length>0}catch{}},onDetail(e){this.$router.push({path:"/liveDetail",query:{groupId:e.courseGroupId}})}},render(){let e;return t(b,null,[this.dataShow?t(w,{class:h.liveList,loading:this.loading,"onUpdate:loading":s=>this.loading=s,immediateCheck:!1,finished:this.finished,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86"},fe(e=this.list.map(s=>t(E,{class:h.liveGroup,border:!1,onClick:()=>this.onDetail(s)},{default:()=>[t(p,null,{icon:()=>t(_,{class:h.liCover,src:s.backgroundPic,fit:"cover"},null),title:()=>t("div",{class:h.liContent},[t("div",{class:[h.liTitle,"van-ellipsis"]},[s.courseGroupName]),t("div",{class:h.liUserInfo},[t("div",{class:[h.userInfo,"van-hairline--right"]},[t(_,{class:h.avatar,fit:"cover"},null),t("p",null,[n("\u8001\u5E08\uFF1A"),s.teacherName])]),t("span",{class:h.num},[s.studentCount,n("\u4EBA\u8D2D\u4E70")])])])}),t(p,{titleStyle:{color:"#666666",fontSize:"13px"}},{title:()=>t("span",{style:{display:"flex",alignItems:"center",fontSize:"13px"}},[t(j,{name:ut,size:"16",style:{marginRight:"5px"}},null),this.formatTime(s.salesStartDate)]),default:()=>t("div",{class:h.price},[t("span",null,[n("\xA5"),this.$filters.moneyFormat(s.coursePrice)]),n("/"),s.courseNum,n("\u8BFE\u65F6")])})]})))?e:{default:()=>[e]}):t(D,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u76F4\u64AD\u8BFE"},null)])}});const ge="_videoList_1yf9v_1";var Ae={videoList:ge};function ve(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!L(e)}var be=A({name:"VideoList",data(){return{list:[],dataShow:!0,loading:!1,finished:!1,params:{page:1,rows:20}}},mounted(){this.getList()},methods:{async getList(){try{let e=this.params;const a=(await u.post("/api-student/videoLesson/selectGroup",{data:v({},e)})).data||{};if(console.log(a),this.list.length>0&&a.pageNo===1)return;this.list=this.list.concat(a.rows||[]),this.finished=a.pageNo>=a.totalPage,this.params.page=a.pageNo+1,this.dataShow=this.list.length>0}catch{}},onDetail(e){this.$router.push({path:"/videoDetail",query:{groupId:e.id}})}},render(){let e;return t(b,null,[this.dataShow?t(w,{class:Ae.videoList,loading:this.loading,"onUpdate:loading":s=>this.loading=s,finished:this.finished,immediateCheck:!1,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86",onLoad:this.getList},ve(e=this.list.map(s=>t(dt,{item:s,onClick:this.onDetail},null)))?e:{default:()=>[e]}):t(D,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u89C6\u9891\u8BFE"},null)])}}),ye=A({name:"music",data(){return{list:[],dataShow:!1,loading:!1,finished:!1,params:{page:1,rows:20}}},render(){return t(b,null,[this.dataShow?t(w,{loading:this.loading,"onUpdate:loading":e=>this.loading=e,finished:this.finished,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86"},null):t(D,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u4E50\u8C31"},null)])}});const Je=e=>{const s=`./images/${e}`;return{"./images/head_bg.png":F,"./images/icon_fans.png":P,"./images/icon_video.png":N}[s].default};var Xe=A({name:"teacherHome",data(){const e=sessionStorage.getItem("teacherHomeTabs")||"",s=this.$route.query;return{teacherId:s.teacherId,tabs:e||s.tabs||"single",userInfo:{}}},async created(){try{const e=await u.get("/api-student/teacher/queryTeacherHome",{params:{userId:this.teacherId}});this.userInfo=e.data}catch{}},computed:{subjectNameList(){const s=this.userInfo.subjectName;return s?s.split(","):[]}},methods:{async onStart(){try{const e=this.userInfo.isStar?0:1;await u.get("/api-student/teacher/starOrUnStar",{params:{userId:this.teacherId,starStatus:e}});const s=e?"\u5173\u6CE8\u6210\u529F":"\u5DF2\u53D6\u6D88\u5173\u6CE8";this.userInfo.isStar=e;let a=e?this.userInfo.fansNum+1:this.userInfo.fansNum-1;this.userInfo.fansNum=a<=0?0:a,I(s)}catch{}}},render(){return t("div",{class:i["teacher-record"]},[t(H,{position:"top",offsetTop:0},{default:()=>[t(W,{class:i.teacherHeader,background:"transparent",border:!1,color:"#fff",backIconColor:"white",isFixed:!1},{default:()=>t("div",{class:i.headerContent},[t("div",{class:i.headerCount},[t(p,{class:i["open-teacher-info"],border:!1,center:!0},{default:()=>[t("div",{class:i["teacher-info"]},[t("div",{class:i["teacher-name"]},[t("div",{class:i.teacherCert},[t("span",{style:{display:"inline-block"}},[this.userInfo.username||`\u6E38\u5BA2${this.userInfo.userId||""}`]),this.userInfo.entryFlag===1&&t(_,{class:i.cert,src:st},null),this.userInfo.musicianFlag===1&&t(_,{class:i.cert,src:at},null)]),t(y,{type:"primary",size:"mini",plain:!!this.userInfo.isStar,style:{borderRadius:"5px",padding:"5px 10px"},onClick:this.onStart},{default:()=>[!this.userInfo.isStar&&t(j,{name:"plus"},null),this.userInfo.isStar?"\u5DF2\u5173\u6CE8":"\u5173\u6CE8"]})]),t("p",{class:i.piNameSubject},[this.subjectNameList.map(e=>t("span",{class:i.subject},[e]))])])],icon:()=>t(_,{class:i.userLogo,src:this.userInfo.heardUrl||et,fit:"cover"},null)}),t("div",{class:i["teacher-bottom"]},[t("div",{class:i.level},[t(X,{iconPrefix:"iconfont",color:"#FFC459","void-icon":"star_default",modelValue:this.userInfo.starGrade,icon:"star_active",size:15},null)]),t("div",{class:i["teacher-data"]},[t("div",{class:i["teacher-data_item"]},[n("\u7C89\u4E1D "),t("span",null,[this.userInfo.fansNum||0])]),t("div",{class:i["teacher-data_item"]},[n("\u5DF2\u4E0A\u8BFE\u65F6 "),t("span",null,[this.userInfo.expTime||0])])])])])])}),t(tt,{color:"var(--van-primary)",background:"#f8f9fc",lineWidth:20,active:this.tabs,"onUpdate:active":e=>this.tabs=e,onChange:()=>{sessionStorage.setItem("teacherHomeTabs",this.tabs)}},{default:()=>[t(C,{title:"\u4E2A\u4EBA\u98CE\u91C7",name:"single"},null),t(C,{title:"\u966A\u7EC3\u8BFE",name:"practice"},null),t(C,{title:"\u76F4\u64AD\u8BFE",name:"live"},null),t(C,{title:"\u89C6\u9891\u8BFE",name:"video"},null),t(C,{title:"\u4E50\u8C31",name:"music"},null)]})]}),t("div",{class:i.container},[this.tabs==="single"&&t(Vt,{userInfo:this.userInfo},null),this.tabs==="practice"&&t(ie,{userInfo:this.userInfo},null),this.tabs==="live"&&t(_e,null,null),this.tabs==="video"&&t(be,null,null),this.tabs==="music"&&t(ye,null,null)])])}});export{Xe as default,Je as getAssetsHomeFile};
|