!function(){function e(e,a,n,t,r,i,u){try{var c=e[i](u),o=c.value}catch(l){return void n(l)}c.done?a(o):Promise.resolve(o).then(t,r)}function a(a){return function(){var n=this,t=arguments;return new Promise((function(r,i){var u=a.apply(n,t);function c(a){e(u,r,i,c,o,"next",a)}function o(a){e(u,r,i,c,o,"throw",a)}c(void 0)}))}}function n(e,a){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);a&&(t=t.filter((function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))),n.push.apply(n,t)}return n}function t(e){for(var a=1;a=a.data.totalPage,e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),K.value=!0;case 17:Q.value=!1;case 18:case"end":return e.stop()}}),e,null,[[4,14]])})));return function(){return e.apply(this,arguments)}}(),Z=function(){var e=a(regeneratorRuntime.mark((function e(a){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,r.post("/api-teacher/teacher/defaultSubject",{params:{subjectId:a}});case 3:e.next=7;break;case 5:e.prev=5,e.t0=e.catch(0);case 7:case"end":return e.stop()}}),e,null,[[0,5]])})));return function(a){return e.apply(this,arguments)}}(),$=function(e){J.page=1,J.subjectIds=e.id,F.value=null,"TEACHER"===i.platformType?(I.value={name:e.name,id:e.id},Z(e.id)):(ae.id=e.id,ae.name=e.name,h(j.SEARCH,JSON.stringify({id:e.id,name:e.name}),"set")),Y(),ae.show=!1};R({onSearch:X,onComfirm:function(e){var a=Object.values(e).flat().filter(Boolean).join(",");J.albumTagIds=a,J.page=1,F.value=null,Y(),W.value=!1},onComfirmSubject:$});var ee=h(j.SEARCH),ae=l({show:!1,name:ee.name||"全部声部",id:ee.id||""});return function(){var e=N.value&&N.value.data||[];return s(v,null,[s(b,{loading:Q.value,finished:V.value,"finished-text":F.value&&F.value.rows.length?"没有更多了":"",onLoad:Y,error:K.value},{default:function(){return[!k&&s(S,{class:E},{default:function(){return[s(T,{border:!1},null),s(_,{modelValue:J.search,onSearch:X,placeholder:"请输入专辑名称 "},{left:function(){return s("div",{class:O,onClick:function(){return ae.show=!0}},["TEACHER"===i.platformType?I.value.name:ae.name,s(f,{classPrefix:"iconfont",name:"down",size:12,color:"#333"},null)])}}),s(p,{shrink:!0,class:A,lineHeight:0,"onClick-tab":function(e){J.albumTagIds=e.name,F.value=null,J.page=1,Y()}},{default:function(){return[s(g,{title:"全部",name:""},null),e.map((function(e){return s(g,{title:e.name,name:e.id},null)}))]}})]}}),F.value&&F.value.rows.length?s("div",{class:C},[s(x,{list:F.value.rows,onGoto:function(e){var a="TEACHER"===i.platformType?I.value:ae;B.push({name:"music-album-detail",params:{id:e.id},query:{subjectId:a.id,subjectName:a.name}})}},null)]):!Q.value&&s(d,{tips:"暂无专辑",classImgSize:"SMALL",btnStatus:!1},null)]}}),s(m,{show:ae.show,position:"bottom",round:!0,closeable:!0,"safe-area-inset-bottom":!0,onClose:function(){return ae.show=!1},onClosed:function(){return ae.show=!1}},{default:function(){return[s(y,{type:"ALBUM",searchParams:"TEACHER"===i.platformType?I.value:ae,onComfirm:$},null)]}})])}}}))}}}))}();