import{T as g,r as _}from"./request.a45d1be5.js";import{d as m,c as e,b as d,_ as f,e as v,r as u,n as x,a as h,J as b}from"./index.3718c0a8.js";import{G as y,a as G}from"./index.ef83260a.js";import{C as N,L as c}from"./index.2b675c4f.js";import{B as V}from"./index.a013fe9c.js";import{L as C}from"./index.3536719e.js";import"./vue3-lottie.es.e34f7e89.js";import"./index.7077e759.js";import"./use-tab-status.a6d8936e.js";const T="_theMusicGrid_pbxg4_1",L="_item_pbxg4_12",S="_title_pbxg4_19",w="_des_pbxg4_28",A="_imgWrap_pbxg4_35",B="_model_pbxg4_39",M="_classNum_pbxg4_53",j="_num_pbxg4_56",I="_itemContent_pbxg4_59",s={theMusicGrid:T,item:L,title:S,des:w,imgWrap:A,model:B,classNum:M,num:j,itemContent:I};function W(a){return typeof a=="function"||Object.prototype.toString.call(a)==="[object Object]"&&!f(a)}const k=m({name:"TheVideoGrid",props:{list:{type:Array,default:()=>[]}},emits:["goto"],setup(a,{emit:l}){const n={loading:()=>e(c,{size:20},null),error:()=>e(c,{size:20},null)};return()=>{let i;return e("div",{class:s.theMusicGrid},[e(y,{border:!1,columnNum:2},W(i=a.list.map(t=>e(G,null,{default:()=>[e("div",{class:s.item,onClick:()=>l("goto",t)},[e("div",{class:s.imgWrap},[e(N,{width:"100%",height:"100%",src:t.lessonCoverUrl},n),e("div",{class:s.model},[e("span",{class:s.classNum},[t.lessonCount,d("\u8BFE\u65F6")]),e("div",{class:s.num},[e("span",{class:s.dot},null),t.countStudent,d("\u4EBA\u5728\u5B66")])])]),e("div",{class:s.itemContent},[e("div",{class:s.title},[t.lessonName,d(" "),t.lessonDesc]),e("div",{class:s.des},[e("span",null,[t.username]),e("span",null,[t.lessonSubjectName])])])])]})))?i:{default:()=>[i]})])}}}),z="_indexVideo_z9lik_1",q={indexVideo:z},H=m({name:"indexVideo",setup(){const a=h(),[l,n]=v(!1),i=u(!1),t=x({albumStatus:"PASS",page:1,rows:10}),r=u([]),p=async()=>{if(!l.value){n(!0);try{const o=await _.post("/api-website/open/videoLessonGroup/page",{data:t});o.data&&Array.isArray(o.data.rows)&&(r.value=[].concat(r.value,o.data.rows),o.data.rows.length?t.page=o.data.pageNo+1:i.value=!0)}catch{}b(()=>{n(!1)})}};return()=>e("div",{class:q.indexVideo},[e(V,null,null),e(g,{title:"\u7CBE\u54C1\u89C6\u9891\u8BFE",isMore:!1},null),e(C,{loading:l.value,finished:i.value,finishedText:"\u6CA1\u6709\u66F4\u591A\u4E86",onLoad:()=>p()},{default:()=>[e(k,{list:r.value,onGoto:o=>a.push({path:"/videoDetail",query:{id:o.teacherId,groupId:o.id}})},null)]})])}});export{H as default};