import{i as kt,a as Tt,b as Et,_ as Y,c as G,d as U,e as R,f as q,g as z,h as W,j as J,k as K,l as Q,m as X,n as Z,o as tt,p as et,q as st,r as at,s as it,t as ot,u as nt,v as rt,w as ct,x as lt,y as ut,z as ht,A as dt,B as pt,C as mt,D as gt,E as _t,F as Ft}from"./vip_default.7099e014.js";import{_ as ft}from"./icon_video.f8e50d61.js";import{d as b,U as wt,V as xt,j as e,N as Bt,w as u,y as p,g,bc as w,T as bt,D as L,F as m,A as r,aS as x,B as y,C as E,$ as vt,n as H,Y as yt,i as At,b3 as Vt}from"./ResizeObserver.es.b7226882.js";import{C as $t}from"./index.969bba7f.js";import"./index.f6c44874.js";import"./index.cf00521e.js";import{T as Mt,a as D}from"./index.dc988884.js";import{C as jt}from"./index.016ea0b0.js";import{A as Lt}from"./index.06142038.js";import{C as I}from"./index.40f703b6.js";import{C as B}from"./index.9269bf1e.js";import{S as Nt}from"./index.8d0ef866.js";import{T as Pt}from"./index.ed3a5560.js";import{o as _}from"./orderStatus.1ca966f0.js";import{t as Dt}from"./tradeOrder.b3e670b0.js";import{L as It}from"./index.9fec2202.js";import{I as N}from"./index.20c0f4c5.js";import{a as Ot,b as Ht}from"./index.1eaf642c.js";import{i as Yt}from"./icon_teacher.40b6f077.js";import{u as Gt}from"./hooks.a4ed20cb.js";import{F as Ut}from"./index.021f1c7b.js";import Rt from"./index.89aec646.js";import"./use-id.5d5e6e63.js";import"./use-tab-status.db1f6d2e.js";import"./use-refs.428b450a.js";import"./index.77fc1df7.js";import"./index.0809e001.js";import"./utils.db47622f.js";import"./index.deda73db.js";import"./index.521acd0b.js";import"./select-tag.09b8e6bc.js";import"./index.1799aedf.js";import"./index.b1e15d61.js";import"./index.926ca9c5.js";import"./index.5f9ef71b.js";import"./music.e5884c70.js";import"./index.f4934f0d.js";import"./icon_uploader.21a85a4d.js";import"./icon-xin.797feb04.js";import"./icon_album.4957b8e0.js";import"./icon_album_active.cb923735.js";import"./icon_exquisite.01ddc5aa.js";import"./icon_music_active.f55820b3.js";import"./icon-play.bc9e7aab.js";import"./index.1743594f.js";const qt="_bgImg_6z94a_33",zt="_bg_6z94a_33",Wt="_teacherHeader_6z94a_51",Jt="_singleSection_6z94a_55",Kt="_btnType_6z94a_60",Qt="_btn2_6z94a_63",Xt="_btn1_6z94a_64",Zt="_singleContent_6z94a_89",te="_fansPopup_6z94a_99";var v={"teacher-record":"_teacher-record_6z94a_1",bgImg:qt,bg:zt,teacherHeader:Wt,singleSection:Jt,btnType:Kt,btn2:Qt,btn1:Xt,singleContent:Zt,fansPopup:te};const ee="_tipSection_1i68p_1",se="_practice_1i68p_7",ae="_group_1i68p_11",ie="_price_1i68p_23",oe="_rTag_1i68p_40",ne="_tag_1i68p_43",re="_selectPopup_1i68p_47",ce="_selectContainer_1i68p_52",le="_rTitle_1i68p_55",ue="_selectPopupContent_1i68p_58",he="_desc_1i68p_61",de="_times_1i68p_62",pe="_selectBtn_1i68p_73",me="_btn_1i68p_78",ge="_protocol_1i68p_97",_e="_arrangeCell_1i68p_101",fe="_fixedBtn_1i68p_107";var c={tipSection:ee,practice:se,group:ae,price:ie,rTag:oe,tag:ne,selectPopup:re,selectContainer:ce,rTitle:le,selectPopupContent:ue,desc:he,times:de,selectBtn:pe,btn:me,protocol:ge,arrangeCell:_e,fixedBtn:fe};const be="_tipSection_19emr_1",ve="_iconCross_19emr_7",Ie="_tipTitle_19emr_15",ye="_tipContent_19emr_28",Se="_tipFooter_19emr_35";var k={tipSection:be,iconCross:ve,tipTitle:Ie,tipContent:ye,tipFooter:Se},F=b({name:"tips",props:{title:{type:String,default:""},content:{type:String,default:""},type:{type:String,default:""},btnTxt:{type:String,default:"\u4E0D\u518D\u63D0\u9192"},class:{type:String,default:""}},emits:["close","confirm"],setup(t,{emit:s}){const a=wt(!0),o=()=>{const i=localStorage.getItem("teacher_home_local");return!!(i?JSON.parse(i):{})[t.type]},n=()=>{const i=localStorage.getItem("teacher_home_local"),h=i?JSON.parse(i):{};h[t.type]=1,localStorage.setItem("teacher_home_local",JSON.stringify(h))};return xt(()=>{a.value=!o()}),()=>a.value?e("div",{class:[k.tipSection,t.class]},[e(Bt,{class:k.iconCross,onClick:()=>{s("close"),a.value=!1},name:"cross"},null),e("div",{class:k.tipTitle},[e("img",{src:kt},null),t.title]),e("div",{class:k.tipContent},[t.content]),e("div",{class:k.tipFooter,onClick:()=>{s("confirm"),n(),a.value=!1}},[t.btnTxt])]):""}}),Ce=b({name:"practice",props:{userInfo:{type:Object,default:{}}},data(){const t=this.$route.query;return{teacherId:t.teacherId,subjectId:t.subjectId,teacherSubjectList:[],subjectStatus:!1,subjectInfo:{subjectPrice:0,courseMinutes:0,freeMinutes:0,id:null,subjectName:"",subjectId:0},courseNum:4,calendarStatus:!1,calendarList:[],selectCourseList:[],coursePlanStatus:!1,selectStatus:!1,coursePlanList:[],calendarDate:u().add(1,"day").toDate(),settingStatus:!0,loadDataStatus:!0}},async mounted(){var t;try{this.loadDataStatus=!0;const a=(await p.get("/api-student/courseSchedule/getTeacherSubjectPrice",{params:{teacherId:this.teacherId,groupType:"PRACTICE"}})).data||[];if(a.length>0){const o=this.subjectId||((t=g.user.data)==null?void 0:t.subjectId),i=a.find(C=>C.subjectId===Number(o))||a[0],{subjectName:h,subjectPrice:S,courseMinutes:A,subjectId:V,id:$,freeMinutes:M}=i;this.subjectInfo={subjectPrice:S,id:$,freeMinutes:M,courseMinutes:A,subjectName:h,subjectId:V},a.forEach(C=>{C.name=C.subjectName}),this.teacherSubjectList=a,this.getList(),this.onBuy(!0),this.settingStatus=!0;const O=await p.post("/api-teacher/open/appVersion",{data:{platform:g.platformType==="STUDENT"?"ios-student":"ios-teacher",version:g.version}});this.settingStatus=!O.data.check}else this.settingStatus=!1;this.loadDataStatus=!1}catch{this.loadDataStatus=!1}},computed:{showSelectList(){let s=[...this.selectCourseList];return s.forEach(a=>{a.title=u(a.startTime).format("YYYY-MM-DD")+" "+w(u(a.startTime).day())+" "+a.start+"~"+a.end}),s},selectType(){return this.selectCourseList.length{h[S.date]=S}),this.calendarList=h,this.calendarStatus=i.length>0}catch{}},onSelectDay(t){const s=t||[];let a=[...this.selectCourseList];s.forEach(n=>{!a.some(h=>h.startTime===n.startTime)&&a.push({...n})});let o=[];a.forEach(n=>{s.some(h=>h.startTime===n.startTime)&&o.push(n)}),o.sort((n,i)=>n.startTime>i.startTime?1:n.startTime{const s=this.selectCourseList.findIndex(a=>a.startTime===t.startTime);this.selectCourseList.splice(s,1)})},async _lookCourse(t){try{let s=[];this.selectCourseList.forEach(n=>{s.push({startTime:n.startTime,endTime:n.endTime})}),((await p.post("/api-student/courseGroup/lockCourseToCache",{data:{courseFreeMinutes:this.subjectInfo.freeMinutes,courseNum:this.courseNum,courseType:"PRACTICE",loop:this.selectType==="noEnough"?1:0,teacherId:this.teacherId,timeList:[...s]}})).data||[]).forEach((n,i)=>{this.coursePlanList[i]={...this.coursePlanList[i],startTime:n.startTime,endTime:n.endTime,classNum:i+1}}),this.coursePlanStatus=!0,this.selectStatus=!0,t&&t()}catch(s){const a=s.message;L.alert({title:"\u63D0\u793A",confirmButtonColor:"var(--van-primary)",message:a}).then(()=>{this.getList(this.calendarDate||new Date),this.selectCourseList=[],this.selectStatus=!1})}},async onReset(){this.coursePlanStatus||this.selectType==="enough"?(this.selectStatus=!1,setTimeout(()=>{this.coursePlanList=[]},500)):this.selectType==="noEnough"&&(this.selectStatus=!1),setTimeout(()=>{this.coursePlanStatus=!1},500)},async onSure(){const t=this.coursePlanStatus;await this._lookCourse(()=>{t&&(this.selectStatus=!1,this.onBuy())})},async onBuy(t){try{const s=await p.post("/api-student/userOrder/getPendingOrder",{data:{goodType:"PRACTICE",bizId:this.teacherId}}),a=this.subjectInfo,o=[...this.coursePlanList];o.forEach(i=>{i.classDate=u(i.startTime).format("YYYY-MM-DD"),i.title=`${u(i.startTime).format("YYYY-MM-DD")} ${w(u(i.startTime).day())} ${u(i.startTime).format("HH:mm")}~${u(i.endTime).format("HH:mm")}`}),_.orderObject.orderType="PRACTICE",_.orderObject.orderName=a.subjectName+"\u8DA3\u7EA0\u8BFE",_.orderObject.orderDesc=a.subjectName+"\u8DA3\u7EA0\u8BFE",_.orderObject.actualPrice=Number((this.courseNum*a.subjectPrice).toFixed(2)),_.orderObject.orderNo="",_.orderObject.orderList=[{orderType:"PRACTICE",goodsName:a.subjectName+"\u8DA3\u7EA0\u8BFE",courseGroupName:a.subjectName+"\u8DA3\u7EA0\u8BFE",courseIntroduce:a.subjectName+"\u8DA3\u7EA0\u8BFE",subjectId:a.subjectId,singleCourseMinutes:a.courseMinutes,teacherSubjectPriceId:a.id,courseNum:this.courseNum,coursePrice:(this.courseNum*a.subjectPrice).toFixed(2),price:(this.courseNum*a.subjectPrice).toFixed(2),teacherName:this.userInfo.username||`\u6E38\u5BA2${this.userInfo.userId||""}`,teacherId:this.userInfo.userId,starGrade:this.userInfo.starGrade,avatar:this.userInfo.heardUrl,classTime:o}];const n=s.data;n?L.confirm({title:"\u63D0\u793A",message:"\u60A8\u6709\u4E00\u4E2A\u672A\u652F\u4ED8\u7684\u8BA2\u5355\uFF0C\u662F\u5426\u7EE7\u7EED\u652F\u4ED8\uFF1F",confirmButtonColor:"#269a93",cancelButtonText:"\u53D6\u6D88\u8BA2\u5355",confirmButtonText:"\u7EE7\u7EED\u652F\u4ED8"}).then(async()=>{Dt(n,this.routerTo)}).catch(()=>{L.close(),this.cancelPayment(n.orderNo)}):!t&&this.routerTo()}catch{}},routerTo(){this.$router.push({path:"/orderDetail",query:{orderType:"PRACTICE"}})},async cancelPayment(t){try{await p.post("/api-student/userOrder/orderCancel",{data:{orderNo:t}})}catch{}}},render(){return e(m,null,[e("div",{class:c.tipSection},[e(F,{type:"PRACTICE",title:"\u4EC0\u4E48\u662F\u8DA3\u7EA0\u8BFE\uFF1F",content:"\u8DA3\u7EA0\u8BFE\u4EE5\u4E00\u5BF9\u4E00\u4E13\u5C5E\u3001\u9AD8\u5EA6\u9488\u5BF9\u6027\u7684\u5F62\u5F0F\u8FDB\u884C\uFF0C\u6BCF\u6B21\u8BFE\u7A0B\u65F6\u957F\u4E3A25\u5206\u949F\u3002\u672C\u8BFE\u7A0B\u4E13\u4E3A\u89E3\u51B3\u5B66\u751F\u65E5\u5E38\u7EC3\u4E60\u4E2D\u7684\u7591\u95EE\u4E0E\u8BEF\u533A\u8BBE\u8BA1\uFF0C\u5C24\u5176\u9002\u5408\u90A3\u4E9B\u5728\u81EA\u6211\u7EC3\u4E60\u540E\u611F\u5230\u56F0\u60D1\u6216\u4E0D\u786E\u5B9A\u81EA\u5DF1\u65B9\u6CD5\u662F\u5426\u6B63\u786E\u7684\u5B66\u751F\u3002\u4E0D\u540C\u4E8E\u4F20\u7EDF\u7684\u6559\u5B66\u6A21\u5F0F\uFF0C\u8DA3\u7EA0\u8BFE\u4E0D\u4FA7\u91CD\u4E8E\u65B0\u77E5\u8BC6\u6216\u65B0\u6280\u80FD\u7684\u4F20\u6388\uFF0C\u800C\u662F\u5168\u5FC3\u5168\u610F\u81F4\u529B\u4E8E\u68C0\u67E5\u5B66\u751F\u73B0\u6709\u7684\u7EC3\u4E60\u6210\u679C\uFF0C\u5E76\u53CA\u65F6\u7EA0\u6B63\u5176\u4E2D\u51FA\u73B0\u7684\u95EE\u9898\u3002\u8FD9\u79CD\u65B9\u5F0F\u4E0D\u4EC5\u6709\u52A9\u4E8E\u5B66\u751F\u5DE9\u56FA\u5DF2\u638C\u63E1\u7684\u77E5\u8BC6\u548C\u6280\u80FD\uFF0C\u8FD8\u80FD\u6709\u6548\u9632\u6B62\u9519\u8BEF\u4E60\u60EF\u7684\u5F62\u6210\u548C\u53D1\u5C55\uFF0C\u4E3A\u4ED6\u4EEC\u4ECA\u540E\u7684\u5B66\u4E60\u6253\u4E0B\u66F4\u52A0\u575A\u5B9E\u7684\u57FA\u7840\u3002"},null)]),!this.loadDataStatus&&(this.settingStatus?e(m,null,[e("div",{class:c.practice},[e(B,{class:c.group,border:!1},{default:()=>[e(I,{title:"\u9009\u62E9\u4E13\u4E1A",isLink:!0,value:this.subjectInfo.subjectName,onClick:()=>this.subjectStatus=!0},null),this.subjectInfo.subjectPrice>0&&e(I,{title:"\u8DA3\u7EA0\u8BFE\u6536\u8D39"},{default:()=>e("div",{class:c.price},[e("span",null,[r("\xA5"),this.$filters.moneyFormat(this.subjectInfo.subjectPrice)]),r("/"),this.subjectInfo.courseMinutes,r("\u5206\u949F")])}),e(I,{title:"\u8BFE\u65F6\u6570"},{default:()=>e(Nt,{modelValue:this.courseNum,"onUpdate:modelValue":t=>this.courseNum=t,theme:"round",max:12,min:4,buttonSize:22,onChange:()=>{this.selectCourseList=[]}},null)})]}),this.calendarStatus&&e("div",{class:c.group},[e(jt,{selectList:this.selectCourseList,list:this.calendarList,maxDays:this.courseNum,nextMonth:t=>this.getList(t),prevMonth:t=>this.getList(t),selectDay:this.onSelectDay,calendarDate:this.calendarDate,"onUpdate:calendarDate":t=>this.calendarDate=t},null)]),this.showSelectList.length>0&&e(I,{class:[c.arrangeCell]},{title:()=>e("div",{class:c.rTitle},[e("span",null,[r("\u5DF2\u9009\u62E9\u8BFE\u7A0B\u65F6\u95F4")])]),label:()=>e("div",{class:c.rTag},[this.showSelectList.map(t=>e(m,null,[e(Pt,{plain:!0,round:!0,closeable:!0,size:"large",type:"primary",class:c.tag,onClose:()=>this.onCloseTag(t)},{default:()=>[t.title]}),e("br",null,null)]))])}),e(x,{show:this.selectStatus,class:c.selectPopup},{default:()=>[e("div",{class:c.selectContainer},[e("div",{class:c.rTitle},[e("span",null,[r("\u63D0\u793A")])]),e("div",{class:c.selectPopupContent},[e("p",{class:c.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&&e("p",{class:c.times},[this.coursePlanList.map(t=>e("span",null,[u(t.startTime||new Date).format("YYYY-MM-DD")," ",u(t.startTime||new Date).format("HH:mm"),r("~"),u(t.endTime||new Date).format("HH:mm")]))])]),e("div",{class:c.selectBtn},[e(y,{class:c.btn,type:"primary",round:!0,block:!0,plain:!0,onClick:this.onReset},{default:()=>[this.selectType==="noEnough"?"\u7EE7\u7EED\u9009\u62E9":"\u91CD\u65B0\u9009\u62E9"]}),e(y,{class:c.btn,type:"primary",round:!0,block:!0,onClick:this.onSure},{default:()=>[r("\u786E\u8BA4")]})])])]}),e(Lt,{show:this.subjectStatus,actions:this.teacherSubjectList,cancelText:"\u53D6\u6D88",closeOnClickAction:!0,onCancel:()=>this.subjectStatus=!1,onSelect:t=>{const{subjectName:s,subjectPrice:a,courseMinutes:o,id:n,subjectId:i,freeMinutes:h}=t;this.subjectInfo={subjectPrice:a,id:n,freeMinutes:h,courseMinutes:o,subjectName:s,subjectId:i},this.subjectStatus=!1}},null)]),e("div",{class:["btnGroup",c.fixedBtn],style:{background:"#fff",paddingTop:"10px"}},[e(y,{block:!0,round:!0,type:"primary",onClick:this.onSubmit},{default:()=>[r("\u786E\u8BA4\u7EA6\u8BFE")]})])]):e(E,{btnStatus:!1,classImgSize:"SMALL",tips:"\u8001\u5E08\u6682\u672A\u5F00\u653E\u8DA3\u7EA0\u8BFE"},null))])}});const Te="_liveList_15t4o_1",je="_liCover_15t4o_4",Le="_liContent_15t4o_9",Ne="_liTitle_15t4o_15",Pe="_users_15t4o_21",De="_user_15t4o_21",ke="_lean_15t4o_42",Ee="_buyNum_15t4o_47",Fe="_num_15t4o_48",we="_price_15t4o_52",xe="_priceNum_15t4o_56",Be="_label_15t4o_65",Ae="_liveGroup_15t4o_70",Ve="_liveTop_15t4o_77",$e="_iconLive_15t4o_81",Me="_liveCenter_15t4o_92",Oe="_subjectName_15t4o_96",He="_timerString_15t4o_107",Ye="_tips_15t4o_113";var l={liveList:Te,liCover:je,liContent:Le,liTitle:Ne,users:Pe,user:De,lean:ke,buyNum:Ee,num:Fe,price:we,priceNum:xe,label:Be,liveGroup:Ae,liveTop:Ve,iconLive:$e,liveCenter:Me,subjectName:Oe,timerString:He,tips:Ye};function Ge(t){return typeof t=="function"||Object.prototype.toString.call(t)==="[object Object]"&&!vt(t)}var Ue=b({name:"live",data(){const t=this.$route.query;return{list:[],dataShow:!0,loading:!1,finished:!1,params:{teacherId:t.teacherId,groupStatus:"APPLY",page:1,rows:20}}},mounted(){this.getList()},methods:{formatTime(t){const s=u(t||new Date),a=["\u5468\u65E5","\u5468\u4E00","\u5468\u4E8C","\u5468\u4E09","\u5468\u56DB","\u5468\u4E94","\u5468\u516D"];return s.format("YYYY-MM-DD")+`(${a[s.day()]})`},async getList(){try{const t={...this.params};g.version&&(t.version=g.version||"",t.platform="ios-student");const s=await p.post("/api-student/courseGroup/queryPageCourseGroup",{data:{...t}});this.loading=!1;const a=s.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{this.dataShow=!1,this.finished=!0}},onDetail(t){this.$router.push({path:"/liveDetail",query:{groupId:t.courseGroupId}})}},render(){let t;return e(m,null,[e(F,{type:"LIVE",class:l.tips,title:"\u4EC0\u4E48\u662F\u76F4\u64AD\u8BFE\uFF1F",content:"\u76F4\u64AD\u8BFE\u662F\u73B0\u4EE3\u6559\u80B2\u9886\u57DF\u4E2D\u4E00\u79CD\u5E7F\u53D7\u6B22\u8FCE\u7684\u8BFE\u7A0B\u5F62\u5F0F\uFF0C\u5B83\u96C6\u5B9E\u65F6\u4E92\u52A8\u3001\u591A\u5A92\u4F53\u5C55\u793A\u548C\u9AD8\u5EA6\u4FBF\u5229\u6027\u4E8E\u4E00\u4F53\uFF0C\u4E3A\u5B66\u4E60\u8005\u5E26\u6765\u4E86\u72EC\u7279\u4E14\u4E30\u5BCC\u7684\u5B66\u4E60\u4F53\u9A8C\u3002\u7279\u522B\u662F\u5728\u7BA1\u4E50\u76F4\u64AD\u8BFE\u4E2D\uFF0C\u6559\u5E08\u53EF\u4EE5\u901A\u8FC7\u64AD\u653E\u7ECF\u5178\u97F3\u4E50\u4F5C\u54C1\uFF0C\u52A0\u6DF1\u5B66\u751F\u5BF9\u97F3\u4E50\u4E4B\u7F8E\u7684\u611F\u77E5\u4E0E\u7406\u89E3\u3002\u5BF9\u4E8E\u90A3\u4E9B\u9700\u8981\u5177\u4F53\u64CD\u4F5C\u6F14\u793A\u7684\u6559\u5B66\u5185\u5BB9\uFF0C\u76F4\u64AD\u8BFE\u80FD\u591F\u63D0\u4F9B\u6E05\u6670\u76F4\u89C2\u7684\u89C6\u89D2\uFF0C\u8BA9\u6559\u5E08\u7684\u6BCF\u4E00\u4E2A\u52A8\u4F5C\u7EC6\u8282\u90FD\u5C55\u73B0\u5728\u5B66\u751F\u9762\u524D\uFF0C\u786E\u4FDD\u5B66\u4E60\u6548\u679C\u3002\u76F4\u64AD\u8BFE\u7A0B\u7684\u5185\u5BB9\u56F4\u7ED5\u7279\u5B9A\u4E3B\u9898\u7CBE\u5FC3\u8BBE\u8BA1\uFF0C\u65E8\u5728\u6EE1\u8DB3\u4E0D\u540C\u5B66\u4E60\u8005\u7684\u9700\u6C42\uFF0C\u4FC3\u8FDB\u77E5\u8BC6\u4E0E\u6280\u80FD\u7684\u6709\u6548\u4F20\u9012\u3002"},null),this.dataShow?e(It,{class:l.liveList,loading:this.loading,"onUpdate:loading":s=>this.loading=s,immediateCheck:!1,finished:this.finished,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86"},Ge(t=this.list.map(s=>e(B,{class:l.liveGroup,border:!1,onClick:()=>this.onDetail(s)},{default:()=>[e("div",{class:l.liveTop},[e("img",{src:Tt,class:l.iconLive},null),e("span",null,[r("\u5F00\u8BFE\u65F6\u95F4\uFF1A "),this.formatTime(s.salesStartDate),r(" ")])]),e("div",{class:l.liveCenter},[e(N,{class:l.liCover,src:s.backgroundPic,fit:"cover"},null),e("span",{class:l.subjectName},[s==null?void 0:s.subjectName])]),e("div",{class:l.liContent},[e("div",{class:[l.liTitle,"van-ellipsis"]},[s.courseGroupName]),e("div",{class:l.users},[e("div",{class:l.lean},[e("span",{class:l.num},[s.studentCount,r("\u4EBA\u5B66\u4E60")])]),e("div",{class:l.price},[s.coursePrice>0&&e(m,null,[e("span",{class:l.priceNum},[e("i",null,[r("\xA5")]),this.$filters.moneyFormat(s.coursePrice)])]),e("span",{class:l.label},[s.coursePrice>0&&"/",s.courseNum,r("\u8BFE\u65F6")])])])])]})))?t:{default:()=>[t]}):e(E,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u76F4\u64AD\u8BFE"},null)])}});const Re="_videoItem_1h9f5_1",qe="_viCover_1h9f5_11",ze="_viSection_1h9f5_18",We="_viTitle_1h9f5_22",Je="_viUserNum_1h9f5_29",Ke="_viPrice_1h9f5_37",Qe="_priceNum_1h9f5_44",Xe="_tags_1h9f5_53",Ze="_label_1h9f5_56",ts="_subjectName_1h9f5_66";var f={videoItem:Re,viCover:qe,viSection:ze,viTitle:We,viUserNum:Je,viPrice:Ke,priceNum:Qe,tags:Xe,label:Ze,subjectName:ts},es=b({name:"VideoItem",props:{item:Object,onClick:{type:Function,default:t=>{}}},render(){const t=this.item;return e("div",{class:f.videoItem,onClick:()=>{this.onClick(t)}},[e("div",{style:{position:"relative",flexShrink:0}},[e(N,{class:f.viCover,fit:"cover",src:t==null?void 0:t.lessonCoverUrl},null),e("span",{class:f.subjectName},[t==null?void 0:t.lessonSubjectName])]),e("div",{class:f.viSection},[e("div",{class:[f.viTitle,"van-ellipsis"]},[t==null?void 0:t.lessonName]),e("div",{class:f.tags},[(t==null?void 0:t.musicNum)>0?e("span",{class:f.label},[t==null?void 0:t.musicNum,r("\u9996\u66F2\u76EE")]):"",(t==null?void 0:t.lessonCount)>0?e("span",{class:f.label},[t==null?void 0:t.lessonCount,r("\u8BFE\u65F6")]):""]),e("div",{class:f.viPrice},[e("div",{class:f.viUserNum},[t==null?void 0:t.countStudent,r("\u4EBA\u5B66\u4E60")]),e("span",{class:f.priceNum},[t.payType==="VIP"?e("span",{style:{color:"#C76E21"}},[r("\u4F1A\u5458")]):e(m,null,[(t==null?void 0:t.lessonPrice)>0&&e(m,null,[e("i",null,[r("\uFFE5")]),t==null?void 0:t.lessonPrice]),(t==null?void 0:t.lessonPrice)<=0&&t.auditVersion!==0&&e(m,null,[e("i",null,[r("\uFFE5")]),r("0")]),(t==null?void 0:t.lessonPrice)<=0&&t.auditVersion===0&&e("span",{style:{color:"#20BEA0"}},[r("\u514D\u8D39")])])])])])])}});const ss="_videoList_15ff1_1",as="_tips_15ff1_12";var St={videoList:ss,tips:as};function is(t){return typeof t=="function"||Object.prototype.toString.call(t)==="[object Object]"&&!vt(t)}var os=b({name:"VideoList",data(){const t=this.$route.query;return{list:[],dataShow:!0,loading:!1,finished:!1,params:{teacherId:t.teacherId,page:1,rows:20}}},mounted(){this.getList()},methods:{async getList(){try{const t={...this.params};g.version&&(t.version=g.version||"",t.platform="ios-student");const s=await p.post("/api-student/videoLesson/selectGroup",{data:{...t}});this.loading=!1;const a=s.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{this.dataShow=!1,this.finished=!0}},onDetail(t){this.$router.push({path:"/videoDetail",query:{groupId:t.id}})}},render(){let t;return e(m,null,[e(F,{type:"VIDEO",class:St.tips,title:"\u4EC0\u4E48\u662F\u89C6\u9891\u8BFE\uFF1F",content:"\u89C6\u9891\u8BFE\u662F\u7531\u6559\u5E08\u4E8B\u5148\u7CBE\u5FC3\u51C6\u5907\u5E76\u5F55\u5236\u7684\u8BFE\u7A0B\u5185\u5BB9\u3002\u6559\u5E08\u4F9D\u636E\u6559\u5B66\u5927\u7EB2\u548C\u76EE\u6807\uFF0C\u7CFB\u7EDF\u89C4\u5212\u6BCF\u4E00\u8282\u89C6\u9891\u7684\u4E3B\u9898\u4E0E\u5185\u5BB9\uFF0C\u786E\u4FDD\u6559\u5B66\u7684\u8FDE\u8D2F\u6027\u548C\u5B8C\u6574\u6027\u3002\u5728\u5F55\u5236\u8FC7\u7A0B\u4E2D\uFF0C\u91C7\u7528\u4E13\u4E1A\u8BBE\u5907\u5982\u9AD8\u6E05\u6444\u50CF\u673A\u548C\u5F55\u5C4F\u8F6F\u4EF6\uFF0C\u4FDD\u969C\u89C6\u9891\u753B\u8D28\u6E05\u6670\u3001\u97F3\u9891\u8D28\u91CF\u4F18\u826F\u3002\u89C6\u9891\u8BFE\u4E3A\u5B66\u751F\u63D0\u4F9B\u4E86\u6781\u5927\u7684\u5B66\u4E60\u7075\u6D3B\u6027\uFF0C\u4ED6\u4EEC\u53EF\u4EE5\u4F9D\u636E\u4E2A\u4EBA\u7684\u65F6\u95F4\u5B89\u6392\u81EA\u7531\u9009\u62E9\u5B66\u4E60\u65F6\u95F4\uFF0C\u4E0D\u53D7\u5730\u70B9\u9650\u5236\u3002\u7279\u522B\u9002\u7528\u4E8E\u7CFB\u7EDF\u5316\u5B66\u4E60\u4F53\u7CFB\u7684\u5185\u5BB9\uFF0C\u89C6\u9891\u8BFE\u80FD\u591F\u5E2E\u52A9\u5B66\u751F\u6309\u90E8\u5C31\u73ED\u5730\u638C\u63E1\u77E5\u8BC6\uFF0C\u5B9E\u73B0\u81EA\u4E3B\u9AD8\u6548\u5B66\u4E60\u3002"},null),this.dataShow?e(It,{class:St.videoList,loading:this.loading,"onUpdate:loading":s=>this.loading=s,finished:this.finished,immediateCheck:!1,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86",onLoad:this.getList},is(t=this.list.map(s=>e(es,{item:s,onClick:this.onDetail},null)))?t:{default:()=>[t]}):e(E,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u89C6\u9891\u8BFE"},null)])}});const ns="_headerContent_gt9yb_1",rs="_teacherContent_gt9yb_5",cs="_teacherUs_gt9yb_10",ls="_teacherIcon_gt9yb_14",us="_avatar_gt9yb_18",hs="_avatarActive_gt9yb_26",ds="_teacherIconVip_gt9yb_30",ps="_teacherInfo_gt9yb_37",ms="_teacherInfoName_gt9yb_42",gs="_teacherHonor_gt9yb_56",_s="_score_gt9yb_65",fs="_headerCount_gt9yb_68",bs="_teacherOperation_gt9yb_75",vs="_btn_gt9yb_88",Is="_btnStar_gt9yb_100",ys="_subjectSection_gt9yb_104",Ss="_iconCert_gt9yb_114",Cs="_followFans_gt9yb_118",Ts="_iconVip_gt9yb_157",js="_iconOther_gt9yb_161",Ls="_teacherCert_gt9yb_177",Ns="_teacherLast_gt9yb_181",Ps="_subjectList_gt9yb_188",Ds="_piNameSubject_gt9yb_199",ks="_subject_gt9yb_104",Es="_rTitle_gt9yb_219",Fs="_liveTag_gt9yb_232",ws="_teacherName_gt9yb_240",xs="_teacherIcons_gt9yb_248",Bs="_teaherPopup_gt9yb_252",As="_teacherIconWrap_gt9yb_257",Vs="_teacherIconItem_gt9yb_263",$s="_teacherIconItemTop_gt9yb_266",Ms="_teacherIconTitle_gt9yb_276",Os="_teacherIconDes_gt9yb_281",Hs="_closeIcon_gt9yb_288",Ys="_liveList_gt9yb_296",Gs="_headerFollow_gt9yb_299",Us="_unlinkeBtn_gt9yb_333",Rs="_followContainer_gt9yb_340";var d={headerContent:ns,teacherContent:rs,teacherUs:cs,teacherIcon:ls,avatar:us,avatarActive:hs,teacherIconVip:ds,teacherInfo:ps,teacherInfoName:ms,teacherHonor:gs,score:_s,headerCount:fs,teacherOperation:bs,btn:vs,btnStar:Is,subjectSection:ys,"teacher-bottom":"_teacher-bottom_gt9yb_109",iconCert:Ss,followFans:Cs,"teacher-data":"_teacher-data_gt9yb_121","teacher-data_item":"_teacher-data_item_gt9yb_126",iconVip:Ts,iconOther:js,"teacher-info":"_teacher-info_gt9yb_166","teacher-name":"_teacher-name_gt9yb_169",teacherCert:Ls,teacherLast:Ns,subjectList:Ps,piNameSubject:Ds,subject:ks,rTitle:Es,liveTag:Fs,teacherName:ws,teacherIcons:xs,teaherPopup:Bs,teacherIconWrap:As,teacherIconItem:Vs,teacherIconItemTop:$s,teacherIconTitle:Ms,teacherIconDes:Os,closeIcon:Hs,liveList:Ys,headerFollow:Gs,unlinkeBtn:Us,followContainer:Rs};const P=t=>{const s=`../images/${t}`;return{"../images/cert_active.png":Y,"../images/cert_default.png":G,"../images/follow_bg.png":U,"../images/head_bg.png":R,"../images/icon-add-star.png":q,"../images/icon-add.png":z,"../images/icon-cert.png":W,"../images/icon-chat.png":J,"../images/icon-close.png":K,"../images/icon-live.png":Q,"../images/icon-message.png":X,"../images/icon-small-live.png":Z,"../images/icon1.png":tt,"../images/icon2.png":et,"../images/icon3.png":st,"../images/icon_fans.png":at,"../images/icon_subject.png":it,"../images/icon_subject1.png":ot,"../images/icon_video.png":ft,"../images/live_active.png":nt,"../images/live_bg.png":rt,"../images/live_default.png":ct,"../images/music_active.png":lt,"../images/music_default.png":ut,"../images/svip_active.png":ht,"../images/teacher-icon.png":dt,"../images/video_active.png":pt,"../images/video_default.png":mt,"../images/vip_active.png":gt,"../images/vip_default.png":_t}[s].default};var qs=b({name:"teacher-header",props:{userInfo:{type:Object,default:()=>({})},teacherId:{type:String||Number,default:""}},emits:["star"],data(){return{iconShow:!1}},computed:{subjectNameList(){const s=this.userInfo.subjectName;return s?s.split(","):[]},starGrade(){const{starGrade:t}=this.userInfo;return Number(t)||0}},methods:{async onStart(){try{const t=this.userInfo.isStar?0:1;await p.get("/api-student/teacher/starOrUnStar",{params:{userId:this.teacherId,starStatus:t}});const s=t?this.userInfo.fansNum+1:this.userInfo.fansNum-1;this.$emit("star",{isStar:t,fansNum:s<=0?0:s})}catch{}},checkBadge(t){var o,n,i;let s=!1;const{userInfo:a}=this;switch(t){case"STYLE":case"VIDEO":case"LIVE":case"MUSIC":a.tag&&(s=a.tag.indexOf(t)>-1);break;case"VIP":s=((o=a.userVip)==null?void 0:o.vipType)==="VIP";break;case"SVIP":s=((n=a.userVip)==null?void 0:n.vipType)==="SVIP"||((i=a.userVip)==null?void 0:i.vipType)==="PERMANENT_SVIP";break;default:s=!1;break}return s},openTeacherIcon(){this.iconShow=!0}},render(){return e(m,null,[e("div",{class:d.headerContent},[e("div",{class:d.headerCount},[e("div",{class:d.teacherContent},[e("div",{class:d.teacherIcon,onClick:()=>{this.userInfo.liveing===1&&H({api:"joinLiveRoom",content:{roomId:this.userInfo.roomUid,teacherId:this.userInfo.userId}})}},[e(N,{class:[d.avatar,(this.checkBadge("SVIP")||this.checkBadge("VIP"))&&d.avatarActive],round:!0,src:this.userInfo.heardUrl||Yt,fit:"cover"},null),this.userInfo.liveing===1&&e("img",{src:Et,class:d.liveTag},null),(this.checkBadge("SVIP")||this.checkBadge("VIP"))&&e(N,{class:d.teacherIconVip,src:this.checkBadge("SVIP")?P("svip_active.png"):this.checkBadge("VIP")?P("vip_active.png"):""},null)]),e("div",{class:d.teacherUs},[e("div",{class:d.teacherInfo},[e("div",{class:d.teacherInfoName},[this.userInfo.username||`\u6E38\u5BA2${this.userInfo.userId||""}`])]),e("div",{class:d["teacher-bottom"]},[e("img",{src:P("icon-cert.png"),class:d.iconCert},null),e("div",{class:d["teacher-data"]},[e("div",{class:d["teacher-data_item"]},[r("\u7C89\u4E1D "),e("span",null,[this.userInfo.fansNum||0])]),e("div",{class:d["teacher-data_item"]},[r("\u5DF2\u4E0A\u8BFE\u65F6 "),e("span",null,[this.userInfo.expTime||0])])])])])]),e("div",{class:d.piNameSubject},[e(N,{class:d.subjectSection,src:P("icon_subject1.png"),fit:"contain"},null),e("div",{class:d.subjectList},[this.subjectNameList.map(t=>e("span",{class:d.subject},[t]))])]),e("div",{class:d.teacherOperation},[e(y,{type:"primary",size:"small",class:[d.btn,!this.userInfo.isStar&&d.btnStar],onClick:this.onStart},{default:()=>[this.userInfo.isStar?e("img",{src:P("icon-add-star.png")},null):e("img",{src:P("icon-add.png")},null),this.userInfo.isStar?"\u5DF2\u5173\u6CE8":"\u5173\u6CE8"]}),e(y,{type:"primary",size:"small",class:d.btn,onClick:()=>{H({api:"joinChatGroup",content:{type:"single",id:this.userInfo.imUserId}})}},{default:()=>[e("img",{src:P("icon-message.png")},null),r("\u804A\u5929")]})])])])])}}),zs=b({name:"VIP_COURSE",props:{userInfo:{type:Object,default:{}}},data(){const t=this.$route.query;return{teacherId:t.teacherId,subjectId:t.subjectId,teacherSubjectList:[],subjectStatus:!1,subjectInfo:{freeMinutes:0,subjectPrice:0,courseMinutes:0,id:null,subjectName:"",subjectId:0},courseNum:4,calendarStatus:!1,calendarList:[],selectCourseList:[],coursePlanStatus:!1,selectStatus:!1,coursePlanList:[],calendarDate:u().add(1,"day").toDate(),settingStatus:!0,loadDataStatus:!0}},async mounted(){var t;try{this.loadDataStatus=!0;const a=(await p.get("/api-student/courseSchedule/getTeacherSubjectPrice",{params:{teacherId:this.teacherId,groupType:"VIP"}})).data||[];if(a.length>0){const o=this.subjectId||((t=g.user.data)==null?void 0:t.subjectId),i=a.find(C=>C.subjectId===Number(o))||a[0],{subjectName:h,subjectPrice:S,courseMinutes:A,subjectId:V,id:$,freeMinutes:M}=i;this.subjectInfo={subjectPrice:S,freeMinutes:M,id:$,courseMinutes:A,subjectName:h,subjectId:V},a.forEach(C=>{C.name=C.subjectName}),this.teacherSubjectList=a,this.getList(),this.onBuy(!0),this.settingStatus=!0;const O=await p.post("/api-teacher/open/appVersion",{data:{platform:g.platformType==="STUDENT"?"ios-student":"ios-teacher",version:g.version}});this.settingStatus=!O.data.check}else this.settingStatus=!1;this.loadDataStatus=!1}catch{this.loadDataStatus=!1}},computed:{showSelectList(){let s=[...this.selectCourseList];return s.forEach(a=>{a.title=u(a.startTime).format("YYYY-MM-DD")+" "+w(u(a.startTime).day())+" "+a.start+"~"+a.end}),s},selectType(){return this.selectCourseList.length{h[S.date]=S}),this.calendarList=h,this.calendarStatus=i.length>0}catch{}},onSelectDay(t){const s=t||[];let a=[...this.selectCourseList];s.forEach(n=>{!a.some(h=>h.startTime===n.startTime)&&a.push({...n})});let o=[];a.forEach(n=>{s.some(h=>h.startTime===n.startTime)&&o.push(n)}),o.sort((n,i)=>n.startTime>i.startTime?1:n.startTime{const s=this.selectCourseList.findIndex(a=>a.startTime===t.startTime);this.selectCourseList.splice(s,1)})},async _lookCourse(t){try{let s=[];this.selectCourseList.forEach(n=>{s.push({startTime:n.startTime,endTime:n.endTime})}),((await p.post("/api-student/courseGroup/lockCourseToCache",{data:{courseFreeMinutes:this.subjectInfo.freeMinutes,courseNum:this.courseNum,courseType:"VIP",loop:this.selectType==="noEnough"?1:0,teacherId:this.teacherId,timeList:[...s]}})).data||[]).forEach((n,i)=>{this.coursePlanList[i]={...this.coursePlanList[i],startTime:n.startTime,endTime:n.endTime,classNum:i+1}}),this.coursePlanStatus=!0,this.selectStatus=!0,t&&t()}catch(s){const a=s.message;L.alert({title:"\u63D0\u793A",confirmButtonColor:"var(--van-primary)",message:a}).then(()=>{this.getList(this.calendarDate||new Date),this.selectCourseList=[],this.selectStatus=!1})}},async onReset(){this.coursePlanStatus||this.selectType==="enough"?(this.selectStatus=!1,setTimeout(()=>{this.coursePlanList=[]},500)):this.selectType==="noEnough"&&(this.selectStatus=!1),setTimeout(()=>{this.coursePlanStatus=!1},500)},async onSure(){const t=this.coursePlanStatus;await this._lookCourse(()=>{t&&(this.selectStatus=!1,this.onBuy())})},async onBuy(t){try{const s=await p.post("/api-student/userOrder/getPendingOrder",{data:{goodType:"VIP_COURSE",bizId:this.teacherId}}),a=this.subjectInfo,o=[...this.coursePlanList];o.forEach(i=>{i.classDate=u(i.startTime).format("YYYY-MM-DD"),i.title=`${u(i.startTime).format("YYYY-MM-DD")} ${w(u(i.startTime).day())} ${u(i.startTime).format("HH:mm")}~${u(i.endTime).format("HH:mm")}`}),_.orderObject.orderType="VIP_COURSE",_.orderObject.orderName=a.subjectName+"VIP\u5B9A\u5236\u8BFE",_.orderObject.orderDesc=a.subjectName+"VIP\u5B9A\u5236\u8BFE",_.orderObject.actualPrice=Number((this.courseNum*a.subjectPrice).toFixed(2)),_.orderObject.orderNo="",_.orderObject.orderList=[{orderType:"VIP_COURSE",goodsName:a.subjectName+"VIP\u5B9A\u5236\u8BFE",courseGroupName:a.subjectName+"VIP\u5B9A\u5236\u8BFE",courseIntroduce:a.subjectName+"VIP\u5B9A\u5236\u8BFE",subjectId:a.subjectId,singleCourseMinutes:a.courseMinutes,teacherSubjectPriceId:a.id,courseNum:this.courseNum,coursePrice:(this.courseNum*a.subjectPrice).toFixed(2),price:(this.courseNum*a.subjectPrice).toFixed(2),teacherName:this.userInfo.username||`\u6E38\u5BA2${this.userInfo.userId||""}`,teacherId:this.userInfo.userId,starGrade:this.userInfo.starGrade,avatar:this.userInfo.heardUrl,classTime:o}];const n=s.data;n?L.confirm({title:"\u63D0\u793A",message:"\u60A8\u6709\u4E00\u4E2A\u672A\u652F\u4ED8\u7684\u8BA2\u5355\uFF0C\u662F\u5426\u7EE7\u7EED\u652F\u4ED8\uFF1F",confirmButtonColor:"#269a93",cancelButtonText:"\u53D6\u6D88\u8BA2\u5355",confirmButtonText:"\u7EE7\u7EED\u652F\u4ED8"}).then(async()=>{Dt(n,this.routerTo)}).catch(()=>{L.close(),this.cancelPayment(n.orderNo)}):!t&&this.routerTo()}catch{}},routerTo(){this.$router.push({path:"/orderDetail",query:{orderType:"VIP_COURSE"}})},async cancelPayment(t){try{await p.post("/api-student/userOrder/orderCancel",{data:{orderNo:t}})}catch{}}},render(){return e(m,null,[e("div",{class:c.tipSection},[e(F,{type:"LIVE_COURSE",title:"\u4EC0\u4E48\u662FVIP\u5B9A\u5236\u8BFE\uFF1F",content:"VIP\u5B9A\u5236\u8BFE\u7A0B\u91C7\u7528\u4E00\u5BF9\u4E00\u4E13\u5C5E\u6388\u8BFE\u6A21\u5F0F\uFF0C\u6BCF\u8282\u8BFE\u65F6\u957F\u4E3A45\u5206\u949F\u3002\u8BFE\u7A0B\u5185\u5BB9\u6839\u636E\u5B66\u751F\u7684\u5177\u4F53\u9700\u6C42\u91CF\u8EAB\u6253\u9020\uFF0C\u65E8\u5728\u5168\u9762\u63D0\u5347\u5B66\u751F\u7684\u4E2A\u4EBA\u6280\u80FD\u4E0E\u8868\u73B0\u3002\u4E0D\u8BBA\u662F\u5E0C\u671B\u5728\u4E50\u5668\u6F14\u594F\u6280\u5DE7\u4E0A\u53D6\u5F97\u7A81\u7834\uFF0C\u5982\u63D0\u9AD8\u6307\u6CD5\u7CBE\u51C6\u5EA6\u3001\u6C14\u606F\u63A7\u5236\u80FD\u529B\u6216\u8282\u594F\u638C\u63E1\u7B49\uFF1B\u8FD8\u662F\u4E3A\u5373\u5C06\u5230\u6765\u7684\u91CD\u8981\u6D3B\u52A8\u3001\u6BD4\u8D5B\u6216\u8003\u7EA7\u505A\u5145\u5206\u51C6\u5907\uFF0C\u6211\u4EEC\u90FD\u80FD\u63D0\u4F9B\u9AD8\u5EA6\u5339\u914D\u7684\u6559\u5B66\u65B9\u6848\u3002\u6B64\u5916\uFF0C\u6559\u5B66\u8FDB\u5EA6\u5C06\u6839\u636E\u6BCF\u4F4D\u5B66\u5458\u7684\u5B66\u4E60\u5438\u6536\u60C5\u51B5\u7075\u6D3B\u8C03\u6574\uFF0C\u786E\u4FDD\u6BCF\u4E2A\u4EBA\u90FD\u80FD\u5728\u6700\u9002\u5408\u81EA\u5DF1\u7684\u8282\u594F\u4E2D\u7A33\u6B65\u524D\u8FDB\uFF0C\u624E\u5B9E\u63D0\u5347\u4E2A\u4EBA\u80FD\u529B\u3002"},null)]),!this.loadDataStatus&&(this.settingStatus?e(m,null,[e("div",{class:c.practice},[e(B,{class:c.group,border:!1},{default:()=>[e(I,{title:"\u9009\u62E9\u4E13\u4E1A",isLink:!0,value:this.subjectInfo.subjectName,onClick:()=>this.subjectStatus=!0},null),this.subjectInfo.subjectPrice>0&&e(I,{title:"VIP\u5B9A\u5236\u8BFE\u6536\u8D39"},{default:()=>e("div",{class:c.price},[e("span",null,[r("\xA5"),this.$filters.moneyFormat(this.subjectInfo.subjectPrice)]),r("/"),this.subjectInfo.courseMinutes,r("\u5206\u949F")])}),e(I,{title:"\u8BFE\u65F6\u6570"},{default:()=>e(Nt,{modelValue:this.courseNum,"onUpdate:modelValue":t=>this.courseNum=t,theme:"round",max:12,min:4,buttonSize:22,onChange:()=>{this.selectCourseList=[]}},null)})]}),this.calendarStatus&&e("div",{class:c.group},[e(jt,{selectList:this.selectCourseList,list:this.calendarList,maxDays:this.courseNum,nextMonth:t=>this.getList(t),prevMonth:t=>this.getList(t),selectDay:this.onSelectDay,calendarDate:this.calendarDate,"onUpdate:calendarDate":t=>this.calendarDate=t},null)]),this.showSelectList.length>0&&e(I,{class:[c.arrangeCell]},{title:()=>e("div",{class:c.rTitle},[e("span",null,[r("\u5DF2\u9009\u62E9\u8BFE\u7A0B\u65F6\u95F4")])]),label:()=>e("div",{class:c.rTag},[this.showSelectList.map(t=>e(m,null,[e(Pt,{plain:!0,round:!0,closeable:!0,size:"large",type:"primary",class:c.tag,onClose:()=>this.onCloseTag(t)},{default:()=>[t.title]}),e("br",null,null)]))])}),e(x,{show:this.selectStatus,class:c.selectPopup},{default:()=>[e("div",{class:c.selectContainer},[e("div",{class:c.rTitle},[e("span",null,[r("\u63D0\u793A")])]),e("div",{class:c.selectPopupContent},[e("p",{class:c.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&&e("p",{class:c.times},[this.coursePlanList.map(t=>e("span",null,[u(t.startTime||new Date).format("YYYY-MM-DD")," ",u(t.startTime||new Date).format("HH:mm"),r("~"),u(t.endTime||new Date).format("HH:mm")]))])]),e("div",{class:c.selectBtn},[e(y,{class:c.btn,type:"primary",round:!0,block:!0,plain:!0,onClick:this.onReset},{default:()=>[this.selectType==="noEnough"?"\u7EE7\u7EED\u9009\u62E9":"\u91CD\u65B0\u9009\u62E9"]}),e(y,{class:c.btn,type:"primary",round:!0,block:!0,onClick:this.onSure},{default:()=>[r("\u786E\u8BA4")]})])])]}),e(Lt,{show:this.subjectStatus,actions:this.teacherSubjectList,cancelText:"\u53D6\u6D88",closeOnClickAction:!0,onCancel:()=>this.subjectStatus=!1,onSelect:t=>{const{subjectName:s,subjectPrice:a,courseMinutes:o,id:n,subjectId:i,freeMinutes:h}=t;this.subjectInfo={subjectPrice:a,freeMinutes:h,id:n,courseMinutes:o,subjectName:s,subjectId:i},this.subjectStatus=!1}},null)]),e("div",{class:["btnGroup",c.fixedBtn],style:{background:"#fff",paddingTop:"10px"}},[e(y,{block:!0,round:!0,type:"primary",onClick:this.onSubmit},{default:()=>[r("\u786E\u8BA4\u7EA6\u8BFE")]})])]):e(E,{btnStatus:!1,classImgSize:"SMALL",tips:"\u8001\u5E08\u6682\u672A\u5F00\u653EVIP\u5B9A\u5236\u8BFE"},null))])}});const Ws="_filterTitle_cir06_1",Js="_fansGroup_cir06_9",Ks="_introduce_cir06_19",Qs="_fansImage_cir06_25",Xs="_fansTitle_cir06_31",Zs="_joinContainer_cir06_37",ta="_joinText_cir06_40";var j={filterTitle:Ws,fansGroup:Js,introduce:Ks,fansImage:Qs,fansTitle:Xs,joinContainer:Zs,joinText:ta};const ea=t=>{const s=`../images/${t}`;return{"../images/cert_active.png":Y,"../images/cert_default.png":G,"../images/follow_bg.png":U,"../images/head_bg.png":R,"../images/icon-add-star.png":q,"../images/icon-add.png":z,"../images/icon-cert.png":W,"../images/icon-chat.png":J,"../images/icon-close.png":K,"../images/icon-live.png":Q,"../images/icon-message.png":X,"../images/icon-small-live.png":Z,"../images/icon1.png":tt,"../images/icon2.png":et,"../images/icon3.png":st,"../images/icon_fans.png":at,"../images/icon_subject.png":it,"../images/icon_subject1.png":ot,"../images/icon_video.png":ft,"../images/live_active.png":nt,"../images/live_bg.png":rt,"../images/live_default.png":ct,"../images/music_active.png":lt,"../images/music_default.png":ut,"../images/svip_active.png":ht,"../images/teacher-icon.png":dt,"../images/video_active.png":pt,"../images/video_default.png":mt,"../images/vip_active.png":gt,"../images/vip_default.png":_t}[s].default};var sa=b({name:"joinChat",props:{item:{type:Object,default:{}},onClose:{type:Function,default:t=>{}}},data(){return{desc:""}},methods:{async onJoinChat(){try{await p.post("/api-student/imGroupMemberAudit/apply",{data:{groupId:this.item.id,auditStatus:"AUDITING",roleType:"STUDENT",desc:this.desc}}),bt("\u7533\u8BF7\u6210\u529F"),this.desc="",this.onClose&&this.onClose(this.item.id)}catch{}}},render(){return e(m,null,[e("div",{class:[j.filterTitle,"van-hairline--bottom"]},[r("\u7533\u8BF7\u5165\u7FA4")]),e("div",{class:j.joinContainer},[e(I,{center:!0,class:j.fansGroup,border:!1},{icon:()=>e(N,{src:this.item.img||ea("icon_fans.png"),fit:"cover",class:j.fansImage},null),title:()=>e("div",{class:j.fansTitle},[e("div",{class:j.title},[this.item.name]),e("p",{class:["van-ellipsis",j.introduce]},[this.item.introduce])])}),e(Ut,{type:"textarea",class:j.joinText,rows:2,maxlength:200,modelValue:this.desc,"onUpdate:modelValue":t=>this.desc=t,placeholder:"\u8BF7\u586B\u5199\u60A8\u7684\u5165\u7FA4\u7533\u8BF7\uFF0C\u4F1A\u66F4\u5FEB\u7684\u88AB\u901A\u8FC7\u5594\uFF5E"},null)]),e("div",{class:"btnGroup"},[e(y,{type:"primary",block:!0,round:!0,style:{width:"70%",margin:"0 auto"},onClick:this.onJoinChat},{default:()=>[r("\u786E\u8BA4")]})])])}});const aa="_fansSection_x9kaa_1",ia="_fansBg_x9kaa_6",oa="_noFans_x9kaa_9",na="_fansList_x9kaa_16",ra="_fansGroup_x9kaa_22",ca="_fansImage_x9kaa_50",la="_fansTitle_x9kaa_57",ua="_title_x9kaa_62",ha="_introduce_x9kaa_66";var T={fansSection:aa,fansBg:ia,noFans:oa,fansList:na,fansGroup:ra,fansImage:ca,fansTitle:la,title:ua,introduce:ha},da="./assets/fans-bg.fa43239b.png",pa=b({name:"fans-list",props:{fansList:{type:Array,default:()=>[]}},emits:["confirm"],setup(t,{emit:s}){const a=async o=>{if(!o.hasWaitAuditFlag&&!o.existFlag){s("confirm",o);return}o.existFlag&&H({api:"joinChatGroup",content:{type:"multi",id:o.id}})};return()=>e("div",{class:T.fansSection},[e("img",{src:da,class:T.fansBg},null),t.fansList&&t.fansList.length>0?e("div",{class:T.fansList},[t.fansList.map(o=>e(I,{center:!0,class:T.fansGroup,border:!1},{icon:()=>e(N,{src:o.img||Ft,fit:"cover",class:T.fansImage},null),title:()=>e("div",{class:T.fansTitle},[e("div",{class:[T.title,"van-ellipsis"]},[o.name]),e("p",{class:["van-ellipsis",T.introduce]},[o.introduce])]),default:()=>e(y,{type:"primary",size:"small",round:!0,disabled:o.hasWaitAuditFlag,onClick:()=>a(o)},{default:()=>[o.existFlag?"\u53BB\u804A\u5929":"",o.hasWaitAuditFlag?"\u5BA1\u6838\u4E2D":"",!o.hasWaitAuditFlag&&!o.existFlag?"\u7533\u8BF7\u5165\u7FA4":""]})}))]):e("div",{class:T.noFans},[r("\u6682\u65F6\u8FD8\u6CA1\u6709\u7C89\u4E1D\u7FA4\u54E6\uFF01")])])}});function ma(t){return typeof t=="function"||Object.prototype.toString.call(t)==="[object Object]"&&!vt(t)}var ga=b({name:"group",data(){const t=this.$route.query;return{list:[],dataShow:!0,loading:!1,finished:!1,params:{teacherId:t.teacherId,courseType:"GROUP",groupStatus:"APPLY",page:1,rows:20}}},mounted(){this.getList()},methods:{formatTime(t){const s=u(t||new Date),a=["\u5468\u65E5","\u5468\u4E00","\u5468\u4E8C","\u5468\u4E09","\u5468\u56DB","\u5468\u4E94","\u5468\u516D"];return s.format("YYYY-MM-DD")+`(${a[s.day()]})`},async getList(){try{const t={...this.params};g.version&&(t.version=g.version||"",t.platform="ios-student");const s=await p.post("/api-student/courseGroup/queryPageCourseGroup",{data:{...t}});this.loading=!1;const a=s.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{this.dataShow=!1,this.finished=!0}},onDetail(t){this.$router.push({path:"/groupDetail",query:{groupId:t.courseGroupId}})}},render(){let t;return e("div",null,[e(F,{type:"GROUP",class:l.tips,title:"\u4EC0\u4E48\u662F\u5C0F\u7EC4\u8BFE\uFF1F",content:"\u5C0F\u7EC4\u8BFE\u662F\u8001\u5E08\u6839\u636E\u6559\u5B66\u76EE\u7684\u7F16\u6392\u7684\u8BFE\u7A0B\uFF0C\u56FA\u5B9A\u65F6\u95F4\u8FDB\u884C1V5\u7EBF\u4E0A\u6388\u8BFE\u3002\u60A8\u53EF\u6839\u636E\u8001\u5E08\u5F00\u653E\u7684\u8BFE\u7A0B\u5185\u5BB9\u548C\u60A8\u7684\u65F6\u95F4\u5B89\u6392\uFF0C\u9009\u62E9\u60A8\u611F\u5174\u8DA3\u7684\u8BFE\u7A0B\u7EC4\u8FDB\u884C\u5B66\u4E60\u3002"},null),this.dataShow?e(It,{class:l.liveList,loading:this.loading,"onUpdate:loading":s=>this.loading=s,immediateCheck:!1,finished:this.finished,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86"},ma(t=this.list.map(s=>e(B,{class:l.liveGroup,border:!1,onClick:()=>this.onDetail(s)},{default:()=>[e("div",{class:l.liveTop},[e("img",{src:Tt,class:l.iconLive},null),e("span",null,[r("\u5F00\u8BFE\u65F6\u95F4\uFF1A "),this.formatTime(s.salesStartDate),r(" ")])]),e("div",{class:l.liveCenter},[e(N,{class:l.liCover,src:s.backgroundPic,fit:"cover"},null),e("span",{class:l.subjectName},[s==null?void 0:s.subjectName])]),e("div",{class:l.liContent},[e("div",{class:[l.liTitle,"van-ellipsis"]},[s.courseGroupName]),e("div",{class:l.users},[e("div",{class:l.lean},[e("span",{class:l.num},[s.studentCount,r("\u4EBA\u5B66\u4E60")])]),e("div",{class:l.price},[s.coursePrice>0&&e(m,null,[e("span",{class:l.priceNum},[e("i",null,[r("\xA5")]),this.$filters.moneyFormat(s.coursePrice)])]),e("span",{class:l.label},[s.coursePrice>0&&"/",s.courseNum,r("\u8BFE\u65F6")])])])])]})))?t:{default:()=>[t]}):e(E,{btnStatus:!1,classImgSize:"SMALL",tips:"\u6682\u65E0\u5C0F\u7EC4\u8BFE"},null)])}});const Ct=t=>{const s=`./images/${t}`;return{"./images/cert_active.png":Y,"./images/cert_default.png":G,"./images/follow_bg.png":U,"./images/head_bg.png":R,"./images/icon-add-star.png":q,"./images/icon-add.png":z,"./images/icon-cert.png":W,"./images/icon-chat.png":J,"./images/icon-close.png":K,"./images/icon-live.png":Q,"./images/icon-message.png":X,"./images/icon-small-live.png":Z,"./images/icon1.png":tt,"./images/icon2.png":et,"./images/icon3.png":st,"./images/icon_fans.png":at,"./images/icon_subject.png":it,"./images/icon_subject1.png":ot,"./images/icon_video.png":ft,"./images/live_active.png":nt,"./images/live_bg.png":rt,"./images/live_default.png":ct,"./images/music_active.png":lt,"./images/music_default.png":ut,"./images/svip_active.png":ht,"./images/teacher-icon.png":dt,"./images/video_active.png":pt,"./images/video_default.png":mt,"./images/vip_active.png":gt,"./images/vip_default.png":_t}[s].default};var ri=b({name:"teacherHome",data(){const t=sessionStorage.getItem("teacherHomeTabs")||"",s=this.$route.query;return{teacherId:s.teacherId,tabs:t||s.tabs||"vip",userInfo:{},background:"rgba(55, 205, 177, 0)",headColor:"#fff",height:"auto",tabsHeight:0,stickyHeightNum:0,backIconColor:"white",homeContaiterHeight:"",fansStatus:!1,fansList:[],chatItem:{},chatStatus:!1}},async mounted(){postMessage({api:"setStatusBarTextColor",content:{statusBarTextColor:!0}}),this.$nextTick(()=>{const{height:t}=yt(document.querySelector(".van-tabs__wrap"));this.tabsHeight=t,this.stickyHeight()});try{const t=await p.get("/api-student/student/queryUserInfo");At(t.data)}catch{}this.getTeacherDetail(),Vt("webViewOnResume",()=>{this.getTeacherDetail()}),Ot(document,"scroll",t=>{const{y:s}=Ht();s.value>52?(this.headColor="#000",this.background="#fff",this.backIconColor="black"):(this.background="transparent",this.headColor="#fff",this.backIconColor="white")}),Gt("\u8001\u5E08\u98CE\u91C7")},methods:{stickyHeight(){var s;let t=0;this.height==="auto"?t=this.tabsHeight:t=this.height+this.tabsHeight,this.stickyHeightNum=t,(s=this.$refs.musicListRef)==null||s.updateStickyHeight(t)},async getTeacherDetail(){try{const t=await p.get("/api-student/teacher/queryTeacherHome",{params:{userId:this.teacherId}});this.userInfo=t.data}catch{}},async getFansList(){try{const t=await p.post("/api-student/imGroup/queryTeacherGroup",{data:{type:"FAN",createUserId:this.teacherId}});this.fansList=t.data||[]}catch{}},onItemClick(t){this.$router.push({path:"/music-detail",query:{id:t.id}})}},render(){return e("div",{class:v["teacher-record"]},[e("div",{ref:"headers"},[e($t,{hideHeader:!1,background:this.background,border:!1,color:this.headColor,backIconColor:this.backIconColor,onHeaderBack:()=>{this.$nextTick(()=>{const{height:t}=yt(this.$refs.headers);this.height=Math.floor(t),this.stickyHeight()})}},null)]),e("img",{class:v.bgImg,src:this.userInfo.heardUrl},null),e("div",{class:v.bg,style:{paddingTop:this.height+"px"}},null),e("div",{class:v.teacherHeader},[e(qs,{userInfo:this.userInfo,teacherId:this.teacherId,onStar:t=>{this.userInfo.isStar=t.isStar,this.userInfo.fansNum=t.fansNum}},null),e("div",{class:v.singleSection},[e("div",{class:v.btnType},[e("div",{class:v.btn1,onClick:()=>{this.$router.push({path:"/teacher-style",query:{teacherId:this.teacherId}})}},[e("img",{src:Ct("icon1.png")},null),r("\u4E2A\u4EBA\u98CE\u91C7")]),e("div",{class:v.btn2,onClick:async()=>{this.fansList.length<=0&&await this.getFansList(),this.fansStatus=!0}},[e("img",{src:Ct("icon2.png")},null),r("\u7C89\u4E1D\u7FA4")])]),this.userInfo.introduction&&e("div",{class:v.singleContent},[this.userInfo.introduction])])]),e(Mt,{color:"var(--van-primary)",background:"#f8f9fc",shrink:!0,lineWidth:44,sticky:!0,offsetTop:this.height,active:this.tabs,"onUpdate:active":t=>this.tabs=t,onChange:()=>{sessionStorage.setItem("teacherHomeTabs",this.tabs)}},{default:()=>[e(D,{title:"VIP\u5B9A\u5236\u8BFE",name:"vip"},{default:()=>[e("div",{style:{minHeight:this.homeContaiterHeight}},[this.tabs==="vip"&&e(zs,{userInfo:this.userInfo},null)])]}),e(D,{title:"\u8DA3\u7EA0\u8BFE",name:"practice"},{default:()=>[e("div",{style:{minHeight:this.homeContaiterHeight}},[this.tabs==="practice"&&e(Ce,{userInfo:this.userInfo},null)])]}),e(D,{title:"\u5C0F\u7EC4\u8BFE",name:"group"},{default:()=>[e("div",{style:{minHeight:this.homeContaiterHeight}},[this.tabs==="group"&&e(ga,null,null)])]}),e(D,{title:"\u76F4\u64AD\u8BFE",name:"live"},{default:()=>[e("div",{style:{minHeight:this.homeContaiterHeight}},[this.tabs==="live"&&e(Ue,null,null)])]}),e(D,{title:"\u89C6\u9891\u8BFE",name:"video"},{default:()=>[this.tabs==="video"&&e(os,null,null)]}),e(D,{title:"\u4E50\u8C31",name:"music"},{default:()=>[this.tabs==="music"&&e(Rt,{hideSearch:!0,onlySearch:!0,myself:!0,height:this.stickyHeightNum,ref:"musicListRef",onItemClick:this.onItemClick,teacherId:this.teacherId},null)]})]}),e(x,{show:this.fansStatus,class:v.fansPopup,closeable:!0,onClose:()=>this.fansStatus=!1},{default:()=>[e(pa,{fansList:this.fansList,onConfirm:t=>{this.chatStatus=!0,this.chatItem=t}},null)]}),e(x,{show:this.chatStatus,position:"bottom",round:!0,closeable:!0,"safe-area-inset-bottom":!0,onClose:()=>this.chatStatus=!1},{default:()=>[e(sa,{item:this.chatItem,onClose:t=>{this.fansList.forEach(s=>{s.id===t&&(s.hasWaitAuditFlag=!0)}),this.chatStatus=!1}},null)]})])}});export{ri as default,Ct as getAssetsHomeFile};