index.d8add259.js 18 KB

1
  1. import{E as W,G as k,a0 as X,ab as V,H as j,b7 as q,d as Y,W as I,a3 as F,bP as K,au as R,j as e,be as x,aJ as G,O as Z,P as Q,Q as J,f as v,S as $,U as tt,g as et,V as ot,b3 as at,bi as rt,bv as nt,af as st,A as m,bQ as it,F as z,C as ct,B as H,aS as lt,$ as ut,y,D as E,n as L,T as dt}from"./ResizeObserver.es.b7226882.js";import{C as At}from"./index.40f703b6.js";import{C as pt}from"./index.9269bf1e.js";import{V as mt}from"./vue3-lottie.es.a7302674.js";import{A as gt}from"./refresh_anim.04019e5d.js";import{o as g}from"./orderStatus.1ca966f0.js";import{T as N}from"./index.1743594f.js";import{C as ft}from"./index.969bba7f.js";import"./index.1eaf642c.js";const[ht,B]=W("circle");let bt=0;const _=o=>Math.min(Math.max(+o,0),100);function St(o,f){const h=o?1:0;return`M ${f/2} ${f/2} m 0, -500 a 500, 500 0 1, ${h} 0, 1000 a 500, 500 0 1, ${h} 0, -1000`}const Tt={text:String,size:k,fill:X("none"),rate:V(100),speed:V(0),color:[String,Object],clockwise:j,layerColor:String,currentRate:q(0),strokeWidth:V(40),strokeLinecap:String,startPosition:X("top")};var wt=Y({name:ht,props:Tt,emits:["update:currentRate"],setup(o,{emit:f,slots:h}){const a=`van-circle-${bt++}`,S=I(()=>+o.strokeWidth+1e3),C=I(()=>St(o.clockwise,S.value)),D=I(()=>{const c={top:0,right:90,bottom:180,left:270}[o.startPosition];if(c)return{transform:`rotate(${c}deg)`}});F(()=>o.rate,u=>{let c;const A=Date.now(),d=o.currentRate,p=_(u),T=Math.abs((d-p)*1e3/+o.speed),t=()=>{const r=Date.now(),i=Math.min((r-A)/T,1)*(p-d)+d;f("update:currentRate",_(parseFloat(i.toFixed(1)))),(p>d?i<p:i>p)&&(c=R(t))};o.speed?(c&&K(c),c=R(t)):f("update:currentRate",p)},{immediate:!0});const P=()=>{const{strokeWidth:c,currentRate:A,strokeLinecap:d}=o,p=3140*A/100,T=G(o.color)?`url(#${a})`:o.color,t={stroke:T,strokeWidth:`${+c+1}px`,strokeLinecap:d,strokeDasharray:`${p}px ${3140}px`};return e("path",{d:C.value,style:t,class:B("hover"),stroke:T},null)},U=()=>{const u={fill:o.fill,stroke:o.layerColor,strokeWidth:`${o.strokeWidth}px`};return e("path",{class:B("layer"),style:u,d:C.value},null)},M=()=>{const{color:u}=o;if(!G(u))return;const c=Object.keys(u).sort((A,d)=>parseFloat(A)-parseFloat(d)).map((A,d)=>e("stop",{key:d,offset:A,"stop-color":u[A]},null));return e("defs",null,[e("linearGradient",{id:a,x1:"100%",y1:"0%",x2:"0%",y2:"0%"},[c])])},O=()=>{if(h.default)return h.default();if(o.text)return e("div",{class:B("text")},[o.text])};return()=>e("div",{class:B(),style:x(o.size)},[e("svg",{viewBox:`0 0 ${S.value} ${S.value}`,style:D.value},[M(),U(),P()]),O()])}});const vt=Z(wt);const yt="_courseList_1pmp6_1",Lt="_periodContent_1pmp6_9",Ct="_cover_1pmp6_13",Pt="_contentTitle_1pmp6_47",Mt="_contentLabel_1pmp6_54",Et="_periodSection_1pmp6_60",Bt="_periodHeader_1pmp6_65",Dt="_searchGroup_1pmp6_71",Ut="_iconSearch_1pmp6_80",Ot="_periodTitle_1pmp6_91",Vt="_pIcon_1pmp6_96",It="_pTitle_1pmp6_102",zt="_pNum_1pmp6_108",Ht="_periodList_1pmp6_114",Xt="_circleProgress_1pmp6_153",Rt="_basePlay_1pmp6_158",Gt="_tips_1pmp6_174",Nt="_periodItem_1pmp6_184",_t="_courseDialog_1pmp6_196",Yt="_iconCross_1pmp6_200",Wt="_periodItemModel_1pmp6_208",kt="_iconCachePoint_1pmp6_211",jt="_periodTip_1pmp6_220",qt="_downloading_1pmp6_228",Ft="_btnGroup_1pmp6_242",Kt="_iconClose_1pmp6_250",xt="_title_1pmp6_260",Zt="_content_1pmp6_47",Qt="_popupBtnGroup_1pmp6_275",Jt="_btnLeft_1pmp6_288",$t="_btnRight_1pmp6_292",te="_finch_1pmp6_296",ee="_finchLoad_1pmp6_300",oe="_footers_1pmp6_307";var s={courseList:yt,periodContent:Lt,cover:Ct,contentTitle:Pt,contentLabel:Mt,periodSection:Et,periodHeader:Bt,searchGroup:Dt,iconSearch:Ut,periodTitle:Ot,pIcon:Vt,pTitle:It,pNum:zt,periodList:Ht,circleProgress:Xt,basePlay:Rt,tips:Gt,periodItem:Nt,courseDialog:_t,iconCross:Yt,periodItemModel:Wt,iconCachePoint:kt,periodTip:jt,downloading:qt,btnGroup:Ft,iconClose:Kt,title:xt,content:Zt,popupBtnGroup:Qt,btnLeft:Jt,btnRight:$t,finch:te,finchLoad:ee,footers:oe},ae="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEgAAABQCAMAAACNtsODAAABYlBMVEUAAAD/6O3/5+z/5Ov/6O3/5+3/5+v/09v/5+3/6Oz/5+v/6Oz/5uz/6u3/5PL/4///0tv/0tz/3uT/09z/09z/09v/0tr/19f/4+P/5+z/0tvdK1D/eYr/fYz/a4D/VXL/5er/h5L/coX/////gI7/WXX/b4P/ZHz/W3f/go//X3n/XXj/doj/aH//kZn/e4v5xdD/Zn7/TW3/Rmn/dYf/Ynv/V3T/iZT/bYL/dIb/YXr/Qmf/hZH/lpz/jpf/hJD/UXD/T2//SWv//f3/mZ7/i5X/UnH/k5v/P2T/4uj/S2z/nKD/2eD/jZb/O2LiMVX/oKP/N2DiLlP/zdb/wcviM1f/8vT/7fH/sLv/qLP/lqj/5uv/3+T/3OL/1t3/ytP/x8//uMP/sLP/g5j/n6r/eJL/9vj/wMX/oLL/jKLwjaHthZr/doziNVj6zdb0rbzrYH3mX3vlWXblVnPgPV/iNVevbim2AAAAGXRSTlMA1egk++7e2LSudW1dMBMJsejudW1dMBMJaHAW9wAAA69JREFUWMOt2GtTGjEUBuBFRQUFvNU2gCisggJiQSigqFBARVBppQh4Q7y1au/t/+8m2V0SYOR04f2YGZ/Jec1GJwIbk9Gg0w+h7hHTUyMT07NCx1jGdAgaUSxYpYzMvGl3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dpKBBwPMhIMODgAdNSD9mwBMrYKxxjY++fHRjFgbQ8gyNhvQ6g9EkMPkH/FTASwIbrxMAAAAASUVORK5CYII=",re="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAMAAAAM7l6QAAAApVBMVEUAAAD///////////////////////////////////////////////9Ev3tAvnk+vndCv3pGwHw8vXY7vXVLxYFPy4f7/vxU0YxszpjY8uTy+/bb8+ac3rmN2K/h9uq558500J1wzppTxYag37yB3qt606FhyZBIwX73/PqU27RZx4rp9+/c9efK7dqq6cas4sSZ4LiB1KZ10J5p2ptc15OH1qpmypMm6/isAAAADHRSTlMA6vjFkoSAVEwQBahhgfI7AAABV0lEQVQoz4XT2XqCMBAFYAKIoAdIAqWs7ku1i9Uu7/9onZAaSrlgbv8vmcwSy8TMdx1m28xx/Zn1PwKPwQTzgr5OCavtaiPEZl1XAJv+1QlQrMKQcx5RxOsCmHQ6R3YS4Z1jiibDvDtb3kgpiLXLvLyfnyLbC6HVsMwztPkDhvfUMCdVHMsGLCD28PKQ9k9ft/VZygIedYNhp1h0fAIWR5nkYDPLx+Kxf5qyPh1kkiQVfMvFW5/TZ6CRkryGaznY9Zi/Ass4VpzDsRg+iL+Xy1q0ddcqMSlxCmbZ+CROK+BCytcqcaw5hv3L4lACe843KrGuW7O+XIgrUJ5DlZj6Yi43TxMXoNiqxMTmaV1hxwIAJY4irbqwri3nkvjrPhLZtsU0lcreU2Kt5LqpvZHcGmEG2o5kMNCO9UD1OgznrdbBLNNK83CZhqsYmVUcWeSRbzD6iUa+4A98PDGu23FRUwAAAABJRU5ErkJggg==",ne="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAAAY1BMVEUAAACzs7O0tLS0tLS1tbWzs7O0tLS0tLS0tLS0tLS1tbW2tra0tLS0tLSzs7Ozs7O3t7fJycmzs7O5ubm5ubm/v7+zs7O2tra0tLS0tLS0tLS0tLS2trazs7O0tLS1tbWzs7NrsV1bAA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qv49HTMTYJmcOMi51IYLBM4UvGbSV1UjxIBYEFONob2amy7LfCmVcbbVhKq2cymsJpVXbdXHKu3CCqvJroPahRVWAUu1Xd+/rD43yS4VMAA7vMkT/sLzvNMmAZW5lA54DrqREHJeBjFprAQwAKScfjUJqMylEsDi8tpzHPu1DGLSWD5gSt/V6xsXxuPxN5OAylxKAywqqV/UordvbW+dCYLgkwxg2ljO32GhKt04dj0Kgj3TAKbzKaTwXNU7oOo6gAXw+RXOoaoJHY/MCqtnNauq0N6BjscqmgAQA2JBTPW1zqZwDlXVYMZ1PAT6QE1Q2kVUlT5MGWtqIrZt/xEFwCX1mWgKwQ18MdrfHwyHw8z1surLth1RcPOz6rOqbdEE6MfxbFfG0QDHcfzebjY/CqUb4j77Qiz6UNzAWy8Hg0huKDJ2u523cfyzLv7vhMLCKeJr0d55x6MPHY8wDA8Wrcd5ZAAZQAaQAWQAGUAGkAFkABk4mgGtHl5lR+LotIrPQvHwr288tGqJEOvB/BuMSiuZ4nCW8uBAKQrVmVoeai0e+LpmKVdrtCiNSQO8Rjhyp6oBTn8PkdurQRvTmLQz3F1hR6JqTrDjUTXD6B8ZQAaQAWQAGUAGFjLwFzLkMaro6ElHAAAAAElFTkSuQmCC";function ce(o){return typeof o=="function"||Object.prototype.toString.call(o)==="[object Object]"&&!ut(o)}var be=Y({name:"courseList",setup(){const o=Q(),f=J(),h=v(),a=$({titleOpacity:0,catchStatus:!1,catchItem:{},loading:!0,detail:{},list:[],isDownloading:!1}),S=tt(et.platformType==="STUDENT"?"/api-student":"/api-teacher"),C=async()=>{try{const t=await y.post(S.value+"/tenantAlbumMusic/getLessonCoursewareDetail",{data:{lessonCoursewareId:o.query.id,albumId:o.query.albumId}});a.detail=(t==null?void 0:t.data)||{}}catch{}},D=async()=>{a.loading=!0;try{const t=await y.get(S.value+"/tenantAlbumMusic/getLessonCoursewareCourseList/"+o.query.id);if(Array.isArray(t==null?void 0:t.data)){a.list=t.data,t.data.forEach(n=>{const{knowledgePointList:i,...l}=n;(i||[]).forEach(w=>{w.materialList=[...w.materialList||[],...P(w.children||[])],w.children=null})});const r=await O(t.data);a.list=h.isApp?t.data.map(n=>{const i=r.find(b=>b.lessonCoursewareDetailId==n.lessonCoursewareDetailId),l={...n};return i&&(l.hasCache=i.hasCache),l}):t.data}}catch{}a.loading=!1},P=(t=[])=>{const r=[];return t.forEach(n=>{n.materialList&&n.materialList.length>0&&r.push(...n.materialList||[]),n.children&&n.children.length>0&&r.push(...P(n.children||[]))}),r};ot(()=>{C(),D(),at("downloadCoursewareToCache",c)}),rt(()=>{nt("downloadCoursewareToCache",c)});const U=async t=>{var r;if(!((r=a.detail)!=null&&r.play)){if(o.query.buyStatus==="1")return;if(!v().isApp){T();return}A();return}if(!t.knowledgePointList){E.confirm({message:"\u8BE5\u8BFE\u4EF6\u6682\u65E0\u77E5\u8BC6\u70B9"});return}if(!t.hasCache){if(t.downloadStatus==1){L({api:"cancelDownloadCourseware"}),setTimeout(()=>{L({api:"cancelDownloadCourseware"}),t.downloadStatus=0,a.isDownloading=!1},1e3),dt.loading({message:"\u53D6\u6D88\u4E2D...",forbidClick:!1,loadingType:"spinner",duration:1e3});return}if(t.downloadStatus==3){u(t);return}a.catchStatus=!0,a.catchItem=t;return}M(t)},M=t=>{a.catchStatus=!1,v().isApp?L({api:"openWebView",content:{url:`${location.origin}${location.pathname}#/coursewarePlay?id=${t.coursewareDetailId}&source=my-course`,orientation:0,isHideTitle:!0,statusBarTextColor:!1,isOpenLight:!0,showLoadingAnim:!0}}):f.push({path:"/coursewarePlay",query:{id:t.coursewareDetailId,source:"my-course"}})},O=t=>v().isApp?new Promise(r=>{L({api:"checkCoursewareCache",content:{data:t}},n=>{var i;if((i=n==null?void 0:n.content)!=null&&i.data){r(n.content.data);return}return[]})}):Promise.resolve(t),u=async t=>(console.log(t),h.isApp?(a.catchStatus=!1,a.isDownloading=!0,await L({api:"downloadCoursewareToCache",content:{data:t}})):!0),c=t=>{var r;if((r=t==null?void 0:t.content)!=null&&r.lessonCoursewareDetailId){const{lessonCoursewareDetailId:n,downloadStatus:i,progress:l}=t.content,b=a.list.find(w=>w.lessonCoursewareDetailId==n);b&&(b.downloadStatus=i,b.progress=l,i==2&&(b.hasCache=1,b.progress=100,a.isDownloading=!1))}};st("scroll",()=>{const t=window.scrollY||window.pageYOffset||document.documentElement.scrollTop;a.titleOpacity=t>100?1:t/100});const A=async()=>{const t=S.value+"/tenantGroupAlbum/buyAlbumInfo?tenantGroupAlbumId="+(o.query.taId||""),{data:r}=await y.get(t),n=r[0];g.orderObject.orderType="TENANT_ALBUM",g.orderObject.orderName=n.name,g.orderObject.orderDesc=n.name,g.orderObject.actualPrice=n.actualPrice,g.orderObject.orderNo="",g.orderObject.orderList=[{orderType:"TENANT_ALBUM",goodsName:n.name,actualPrice:n.actualPrice,price:n.actualPrice,...n}];const l=(await y.post("/api-student/userOrder/getPendingOrder",{data:{goodType:"TENANT_ALBUM",bizId:n.id}})).data;l?E.confirm({title:"\u63D0\u793A",message:"\u60A8\u6709\u4E00\u4E2A\u672A\u652F\u4ED8\u7684\u8BA2\u5355\uFF0C\u662F\u5426\u7EE7\u7EED\u652F\u4ED8\uFF1F",theme:"round-button",className:"confirm-button-group",cancelButtonText:"\u53D6\u6D88\u8BA2\u5355",confirmButtonText:"\u7EE7\u7EED\u652F\u4ED8"}).then(async()=>{g.orderObject.orderNo=l.orderNo,g.orderObject.actualPrice=l.actualPrice,g.orderObject.discountPrice=l.discountPrice,g.orderObject.paymentConfig={...l.paymentConfig,paymentVendor:l.paymentVendor,paymentVersion:l.paymentVersion},p(n.id)}).catch(()=>{E.close(),d(l.orderNo)}):p(n.id)},d=async t=>{try{await y.post("/api-student/userOrder/orderCancel/v2",{data:{orderNo:t}})}catch{}},p=t=>{f.push({path:"/orderDetail",query:{orderType:"ALBUM",album:t}})},T=()=>{E.alert({title:"\u63D0\u793A",message:"\u8BF7\u5728\u9177\u4E50\u79C0APP\u4E2D\u4F7F\u7528",confirmButtonColor:"#2dc7aa"}).then(()=>{window.location.href=location.origin+"/student/#/download"})};return()=>{let t;return e("div",{class:s.courseList},[e(N,{position:"top"},{default:()=>[e(ft,{hideHeader:!1,background:`rgba(255,255,255, ${a.titleOpacity})`,isFixed:!1,border:!1,title:"\u6559\u7A0B\u8BE6\u60C5",color:"#131415"},null)]}),e("div",{style:"height: calc(100vh - var(--header-height, 0px) - var(--bottom-height, 0px)); overflow-x: hidden; overflow-y: auto;display:flex; flex-direction: column;"},[e("div",{class:s.periodContent},[e("div",{class:s.cover},[e("img",{src:a.detail.coverImg,onLoad:r=>{r.target&&(r.target.style.opacity=1)}},null)]),e("div",null,[e("div",{class:s.contentTitle},[a.detail.name]),e("div",{class:s.contentLabel},[m("\u6559\u5B66\u76EE\u6807\uFF1A"),a.detail.lessonTargetDesc])])]),e("div",{class:s.periodSection},[e(it,{name:"van-fade"},{default:()=>[!a.loading&&e(z,null,[e("div",{class:s.periodHeader},[e("div",{key:"periodTitle",class:s.periodTitle},[e("img",{class:s.pIcon,src:ie},null),e("div",{class:s.pTitle},[m("\u8BFE\u7A0B\u5217\u8868")]),e("div",{class:s.pNum},[m("\u5171"),a.list.length,m("\u8BFE")])]),e("div",{class:s.searchGroup,onClick:()=>{f.push({path:"/courseListSearch",query:{id:o.query.id,albumId:o.query.albumId,taId:o.query.taId}})}},[e("img",{src:se,class:s.iconSearch},null),e("span",{class:s.searchContent},[m("\u641C\u7D22\u7D20\u6750")])])]),e("div",{key:"list",class:s.periodList},[e(pt,{inset:!0},ce(t=a.list.map(r=>e(At,{border:!0,center:!0,title:r.coursewareDetailName,onClick:()=>U(r)},{icon:()=>e("div",{class:s.periodItem},[e("div",{class:s.periodItemModel},[e("img",{src:ae},null),r.hasCache?e("img",{class:s.iconCachePoint,src:re},null):"",r.downloadStatus==1&&e("div",{class:s.downloading},[`${r.progress||0}%`])])]),value:()=>e(z,null,[r.knowledgePointList?e("div",{class:s.circleProgress},[r.hasCache||r.downloadStatus!==1?e("img",{class:s.basePlay,src:ne},null):e(z,null,[e("div",{class:s.tips},null),e(vt,{"current-rate":r.progress,"onUpdate:current-rate":n=>r.progress=n,rate:r.progress,speed:10,"stroke-width":80,"layer-color":"#B3B3B3",color:"#FE2451"},null)])]):""])})))?t:{default:()=>[t]})])])]}),a.loading&&e("div",null,[e(mt,{animationData:gt,class:s.finch},null)]),!a.loading&&!a.list.length&&e(ct,{tips:"\u6682\u65E0\u5185\u5BB9",classImgSize:"SMALL",btnStatus:!1},null)])]),e(N,{position:"bottom",varName:"--bottom-height"},{default:()=>[a.detail.id&&!a.detail.play&&e("div",{class:s.footers},[e(H,{disabled:o.query.buyStatus==="1",round:!0,block:!0,type:"primary",color:"linear-gradient(270deg, #FF204B 0%, #FE5B71 100%)",onClick:()=>{if(!v().isApp){T();return}A()}},{default:()=>[m("\u5F00\u901A\u8BAD\u7EC3\u6559\u7A0B")]})])]}),e(lt,{show:a.catchStatus,"onUpdate:show":r=>a.catchStatus=r,round:!0,class:s.courseDialog},{default:()=>[e("i",{class:s.iconClose,onClick:()=>a.catchStatus=!1},null),e("div",{class:s.title},[m("\u4E0B\u8F7D\u63D0\u9192")]),e("div",{class:s.content},[m("\u60A8\u5C1A\u672A\u4E0B\u8F7D\u8BFE\u4EF6\uFF0C\u4E3A\u4E86\u66F4\u52A0\u6D41\u7545\u7684\u5B66\u4E60\u4F53\u9A8C\uFF0C\u63A8\u8350\u60A8\u4E0B\u8F7D\u540E\u89C2\u770B\u8BFE\u4EF6\u3002")]),e("div",{class:s.popupBtnGroup},[e(H,{class:s.btnLeft,round:!0,onClick:()=>M(a.catchItem)},{default:()=>[m("\u76F4\u63A5\u89C2\u770B")]}),e(H,{class:s.btnRight,round:!0,type:"primary",onClick:()=>u(a.catchItem)},{default:()=>[m("\u4E0B\u8F7D\u8BFE\u4EF6")]})])]})])}}});export{be as default};