!function(){function e(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function t(t){for(var a=1;a0&&1===o.pageNo)){i.next=10;break}return i.abrupt("return");case 10:e.list=e.list.concat(o.rows||[]),e.finished=o.pageNo>=o.totalPage,e.params.page=o.pageNo+1,e.dataShow=e.list.length>0,i.next=20;break;case 16:i.prev=16,i.t0=i.catch(0),e.dataShow=!1,e.finished=!0;case 20:case"end":return i.stop()}}),i,null,[[0,16]])})))()},onPlay:function(e){var t=this;e.id!==Number(this.classId)&&(this.reload=!0,this.posterUrl=e.imgUrl,this.srcUrl=e.videoUrl,this.title=e.title,this.currentClassIndex=e.index,this.videoContent=e.content,this.classId=e.id,this.onSearch(),setTimeout((function(){t.reload=!1}),0))},onSubmit:function(){var e=this;return n(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,l.post("/api-teacher/videoLesson/evaluate",{data:{isTeacher:1,videoId:e.classId,content:e.message,studentId:r.user.data.userId}});case 3:c("评论成功"),e.message="",setTimeout((function(){e.onSearch()}),1e3),t.next=10;break;case 8:t.prev=8,t.t0=t.catch(0);case 10:case"end":return t.stop()}}),t,null,[[0,8]])})))()}},render:function(){var e,t,n=this;return d("div",{class:w["video-class-detail"]},[d(o,{src:this.srcUrl,poster:this.posterUrl,freeTitleStatus:this.lessonPrice>0,freeRate:Number(this.freeRate),trySee:this.trySee,height:this.videoHeight},null),d(p,{border:!1,class:w.cell,title:this.title,titleClass:w.titleInfo},{icon:function(){return d(u,{name:"video",size:18,color:"var(--van-primary)",style:{display:"flex",alignItems:"center"}},null)},value:function(){return d("div",{class:w.label},[d("span",null,[n.currentClassIndex]),_("/"),n.detailList.length,_("课时")])}}),d("div",{class:w.videoDesc},[this.videoContent]),d(h,{active:this.tabIndex,"onUpdate:active":function(e){return n.tabIndex=e},class:w.infoField,color:"var(--van-primary)",lineWidth:20,sticky:!0,lazyRender:!0,offsetTop:this.offsetTop},{default:function(){return[d(y,{title:"目录",name:1},{default:function(){return[d("div",{style:{height:"calc(100vh - 320px)",overflowY:"auto"}},[d(a,{title:"课程列表",icon:"courseList"},C(e=n.detailList.map((function(e,t){var a=(e.musicAlbumInfos||[]).map((function(e){return{relationMusicAlbum:e.relationType,musicAlbumName:e.name,musicAlbumId:e.musicAlbumId,status:e.status,useRelationType:n.useRelationType}}));return d(i,{musicAlbumInfos:a,playId:Number(n.classId),detail:{id:e.id,title:e.videoTitle,content:e.videoContent,imgUrl:e.coverUrl,videoUrl:e.videoUrl,index:t+1},onPlay:n.onPlay,onMusicAlbumDetail:function(e){n.alreadyBuy||e.status?"MUSIC"===e.relationMusicAlbum?n.$router.push({path:"/music-detail",query:{id:e.musicAlbumId}}):"ALBUM"===e.relationMusicAlbum&&n.$router.push({path:"/music-album-detail/"+e.musicAlbumId}):c("数据正在更新,请稍后再试")}},null)})))?e:{default:function(){return[e]}})])]}}),d(y,{title:"讨论",name:3},{default:function(){return[d("div",{style:{overflowY:"auto",marginBottom:"calc(var(--van-cell-vertical-padding) * 2 + var( --van-cell-line-height))"}},[n.dataShow?d(I,{loading:n.loading,"onUpdate:loading":function(e){return n.loading=e},finished:n.finished,finishedText:" ",immediateCheck:!1,onLoad:n.getList},C(t=n.list.map((function(e){return d(p,{class:[w["message-list"],1===e.isTeacher&&w["message-active"]],valueClass:w["message-time"]},{icon:function(){return d(b,{class:w.userLogo,src:e.avatar||j,fit:"cover"},null)},title:function(){return d("div",{class:w.title},[d("div",{class:w["message-name"]},[e.userName]),d("div",{class:w["message-time"]},[v(e.evaluateTime).format("YYYY年MM月DD日")])])},label:function(){return d("div",{class:w.label},[e.content])}})})))?t:{default:function(){return[t]}}):d(f,{btnStatus:!1,tips:"暂无讨论"},null)]),d("div",{class:[w.messageContainer]},[d(x,{placeholder:"快来讨论吧~",modelValue:n.message,"onUpdate:modelValue":function(e){return n.message=e}},{button:function(){return d(m,{type:"primary",disabled:!n.message,style:{padding:"0 20px"},size:"small",round:!0,onClick:n.onSubmit},{default:function(){return[_("发布")]}})}})])]}})]}})])}}))}}}))}();