index.5987e941.js 91 KB

1234567891011121314151617181920212223242526272829
  1. var rt=Object.defineProperty,ot=Object.defineProperties;var nt=Object.getOwnPropertyDescriptors;var Me=Object.getOwnPropertySymbols;var ct=Object.prototype.hasOwnProperty,dt=Object.prototype.propertyIsEnumerable;var Pe=(u,I,d)=>I in u?rt(u,I,{enumerable:!0,configurable:!0,writable:!0,value:d}):u[I]=d,G=(u,I)=>{for(var d in I||(I={}))ct.call(I,d)&&Pe(u,d,I[d]);if(Me)for(var d of Me(I))dt.call(I,d)&&Pe(u,d,I[d]);return u},Z=(u,I)=>ot(u,nt(I));var A=(u,I,d)=>new Promise((l,e)=>{var a=g=>{try{k(d.next(g))}catch(x){e(x)}},y=g=>{try{k(d.throw(g))}catch(x){e(x)}},k=g=>g.done?l(g.value):Promise.resolve(g.value).then(a,y);k((d=d.apply(u,I)).next())});import{S as Ke}from"./index.77470f2a.js";import{P as $e}from"./index.6c1f867a.js";import{a as Ve,b as pt,c as mt,d as ft,e as ht,f as gt,m as Fe,g as yt,h as Ae,i as St,j as Be,k as bt,l as vt,n as Tt,o as It,p as kt}from"./api.288b45b3.js";import{U as te}from"./index.f6bfd815.js";import{cj as xt,cG as Lt,d as se,cI as Ft,cJ as Je,F as ke,cP as Ct,bi as De,dx as wt,dy as je,a as ee,u as ne,r as Q,B as ce,dj as be,i as t,l as v,ce as M,aj as me,_ as ie,a9 as W,p as O,k as m,cg as ve,bx as Xe,b as Ut,dk as He,q as Ce,ac as R,ad as N,m as pe,db as de,M as We,ai as we,dz as Nt,di as he,a8 as H,a7 as Y,dA as Et,ag as Te,aa as oe,bn as Ze,H as J,ae as Mt,ch as Pt,d9 as le,da as Se,bC as X,a0 as At,a1 as Bt,e as Dt,d7 as jt,d8 as Re}from"./index.dbedee1d.js";import{C as ge,D as Rt,B as Qe,E as xe,c as _e}from"./constant.3b7ec83f.js";import{g as re,a as Oe}from"./objectUtil.ec24ceed.js";import{c as Le}from"./api.4bdfcee3.js";import{x as et}from"./api.b4db67c2.js";import{s as tt}from"./api.edac2afc.js";import{f as at}from"./index.00a04aee.js";import{a as _t}from"./uploadFile.9e94b455.js";import{N as B}from"./FormItemGridItem.8ac0ca8b.js";import{N as Ue}from"./Cascader.cc98a5ae.js";import{M as Ot,c as Yt,g as qt}from"./musicUtil.4814d453.js";import{g as zt}from"./filters.01f9ff18.js";import{T as ye}from"./index.3eb2ac77.js";import{g as Gt,s as Kt}from"./use-async.c10a7996.js";import"./searchs.b637f0d6.js";import"./oss-file-upload.79e07571.js";import"./api.70230169.js";import"./vuedraggable.umd.d92f2f5f.js";import"./DeleteFilled.c6300190.js";import"./api.895dff94.js";import"./knowledgeTypeData.3b15dd0b.js";import"./dateUtil.540277d7.js";import"./dayjs.min.eeb6d4db.js";const $t=xt("input-group-label",`
  2. position: relative;
  3. user-select: none;
  4. -webkit-user-select: none;
  5. box-sizing: border-box;
  6. padding: 0 12px;
  7. display: inline-block;
  8. border-radius: var(--n-border-radius);
  9. background-color: var(--n-group-label-color);
  10. color: var(--n-group-label-text-color);
  11. font-size: var(--n-font-size);
  12. line-height: var(--n-height);
  13. height: var(--n-height);
  14. flex-shrink: 0;
  15. white-space: nowrap;
  16. transition:
  17. color .3s var(--n-bezier),
  18. background-color .3s var(--n-bezier),
  19. box-shadow .3s var(--n-bezier);
  20. `,[Lt("border",`
  21. position: absolute;
  22. left: 0;
  23. right: 0;
  24. top: 0;
  25. bottom: 0;
  26. border-radius: inherit;
  27. border: var(--n-group-label-border);
  28. transition: border-color .3s var(--n-bezier);
  29. `)]),Vt=Object.assign(Object.assign({},Je.props),{size:{type:String,default:"medium"},bordered:{type:Boolean,default:void 0}}),Ye=se({name:"InputGroupLabel",props:Vt,setup(u){const{mergedBorderedRef:I,mergedClsPrefixRef:d,inlineThemeDisabled:l}=Ft(u),e=Je("Input","-input-group-label",$t,wt,u,d),a=ke(()=>{const{size:k}=u,{common:{cubicBezierEaseInOut:g},self:{groupLabelColor:x,borderRadius:P,groupLabelTextColor:S,lineHeight:c,groupLabelBorder:L,[je("fontSize",k)]:D,[je("height",k)]:F}}=e.value;return{"--n-bezier":g,"--n-group-label-color":x,"--n-group-label-border":L,"--n-border-radius":P,"--n-group-label-text-color":S,"--n-font-size":D,"--n-line-height":c,"--n-height":F}}),y=l?Ct("input-group-label",ke(()=>u.size[0]),a,u):void 0;return{mergedClsPrefix:d,mergedBordered:I,cssVars:l?void 0:a,themeClass:y==null?void 0:y.themeClass,onRender:y==null?void 0:y.onRender}},render(){var u,I,d;const{mergedClsPrefix:l}=this;return(u=this.onRender)===null||u===void 0||u.call(this),De("div",{class:[`${l}-input-group-label`,this.themeClass],style:this.cssVars},(d=(I=this.$slots).default)===null||d===void 0?void 0:d.call(I),this.mergedBordered?De("div",{class:`${l}-input-group-label__border`}):null)}}),Jt="_audioSection_o5wty_1",Xt="_btnRemove_o5wty_9",Ht="_formContainer_o5wty_14",Wt="_productModal_o5wty_19",Zt="_productIframe_o5wty_27",ue={audioSection:Jt,btnRemove:Xt,formContainer:Ht,productModal:Wt,productIframe:Zt},Qt=se({name:"musicSheetOwnerDialog",props:{musicSheetExtend:{type:Object,default:()=>{}},sourceType:{type:String,required:!0},appData:{type:Array,required:!0,default:[]}},emits:["close","getList","choseMusicSheetOwnerData"],setup(u,{slots:I,attrs:d,emit:l}){const e=ee({loading:!1,pagination:{page:1,rows:10,pageTotal:0},searchForm:{applicationId:null,name:null,sourceType:null},dataList:[],appData:[]}),a=ne(),y=Q(),k=()=>{e.pagination.page=1,x()},g=()=>{var c;(c=y.value)==null||c.submit()},x=()=>A(this,null,function*(){try{e.searchForm.applicationId||a.warning("\u83B7\u53D6\u5E94\u7528\u5217\u8868\u5931\u8D25"),e.loading=!0,e.searchForm.sourceType=u.sourceType;const{data:L}=yield Ve(G(G({},e.pagination),e.searchForm));e.pagination.pageTotal=Number(L.total),e.dataList=L.rows||[]}catch(c){}e.loading=!1});ce(()=>A(this,null,function*(){{if(e.appData=be(u.appData),e.appData.length==0){a.warning("\u83B7\u53D6\u5E94\u7528\u5217\u8868\u5931\u8D25");return}u.musicSheetExtend&&u.musicSheetExtend.applicationId?e.searchForm.applicationId=u.musicSheetExtend.applicationId:e.searchForm.applicationId=e.appData[0].value,e.searchForm.name=null}x()}));const P=()=>e.searchForm.sourceType==="ORG"?[{title:"\u673A\u6784\u540D\u79F0",key:"orgName"},{title:"\u64CD\u4F5C",key:"operation",fixed:"right",render(c){return t(W,null,{default:()=>[t(O,{type:"primary",size:"small",text:!0,onClick:()=>{const L=Z(G({},c),{applicationId:e.searchForm.applicationId});l("choseMusicSheetOwnerData",L),l("close")}},{default:()=>[m("\u9009\u62E9")]})]})}}]:[{title:"\u4EBA\u5458\u540D\u79F0",key:"userName"},{title:"\u624B\u673A\u53F7",key:"phone"},{title:"\u64CD\u4F5C",key:"operation",fixed:"right",render(c){return t(W,null,{default:()=>[t(O,{type:"primary",size:"small",text:!0,onClick:()=>{const L=Z(G({},c),{applicationId:e.searchForm.applicationId});l("choseMusicSheetOwnerData",L),l("close")}},{default:()=>[m("\u9009\u62E9")]})]})}}],S=()=>[{title:"\u673A\u6784\u540D\u79F0",key:"organizationRole"},{title:"\u64CD\u4F5C",key:"operation",fixed:"right",render(c){return t(W,null,{default:()=>[t(O,{type:"primary",size:"small",text:!0,onClick:()=>{const L=Z(G({},c),{applicationId:e.searchForm.applicationId});l("choseMusicSheetOwnerData",L),l("close")}},{default:()=>[m("\u9009\u62E9")]})]})}}];return()=>t("div",{class:"system-menu-container"},[t(Ke,{ref:y,model:e.searchForm,onSubmit:k,onSetModel:c=>e.searchForm=c},{default:()=>[t(v,{label:"\u6240\u5C5E\u9879\u76EE",path:"applicationId",size:"small",style:"width:250px"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u9002\u7528\u6240\u5C5E\u9879\u76EE",value:e.searchForm.applicationId,"onUpdate:value":c=>e.searchForm.applicationId=c,options:e.appData},null)]}),e.searchForm.sourceType==="PERSON"&&t(me,null,[t(v,{label:"\u6240\u5C5E\u4EBA",path:"name",size:"small",style:"width:250px"},{default:()=>[t(ie,{placeholder:"\u8BF7\u8F93\u5165\u6240\u5C5E\u4EBA/\u624B\u673A\u53F7",value:e.searchForm.name,"onUpdate:value":c=>e.searchForm.name=c,clearable:!0},null)]})]),e.searchForm.sourceType==="ORG"&&t(me,null,[t(v,{label:"\u673A\u6784\u540D\u79F0",path:"name",size:"small",style:"width:250px"},{default:()=>[t(ie,{placeholder:"\u8BF7\u8F93\u5165\u673A\u6784\u540D\u79F0",value:e.searchForm.name,"onUpdate:value":c=>e.searchForm.name=c,clearable:!0},null)]})]),t(v,{size:"small"},{default:()=>[t(W,null,{default:()=>[t(O,{type:"primary",onClick:g},{default:()=>[m("\u641C\u7D22")]})]})]})]}),t("div",{class:["section-container"]},[u.sourceType==="PERSON"&&t(ve,{loading:e.loading,columns:P(),data:e.dataList},null),u.sourceType==="ORG"&&t(ve,{loading:e.loading,columns:S(),data:e.dataList},null),t($e,{page:e.pagination.page,"onUpdate:page":c=>e.pagination.page=c,pageSize:e.pagination.rows,"onUpdate:pageSize":c=>e.pagination.rows=c,pageTotal:e.pagination.pageTotal,"onUpdate:pageTotal":c=>e.pagination.pageTotal=c,onList:x,sync:!0,pageSlot:5},null)])])}}),lt=se({name:"music-create-img",props:{xmlFileUrl:{type:String,default:""}},emits:["close","confirm"],setup(u,{emit:I}){const d=ne(),l=ee({productOpen:!1,productIfameSrc:""}),e=ee({musicImg:"",musicFirstImg:"",musicJianImg:""}),a=()=>{if(!u.xmlFileUrl){d.error("\u8BF7\u5148\u4E0A\u4F20XML");return}const x={dev:"https://dev.kt.colexiu.com",test:"https://test.lexiaoya.cn",online:"https://mec.colexiu.com"},P=location.origin.includes("//dev")?"dev":location.origin.includes("//test")?"test":location.origin.includes("//mec")?"online":"dev",S=x[P],c=/(localhost|192)/.test(location.host)?"https://dev.kt.colexiu.com":S,L=encodeURIComponent(u.xmlFileUrl);l.productIfameSrc=c+`/instrument/#/product-img?xmlUrl=${L}&isCreateImg=true&isCbs=true`},y=x=>{const P=x.data;if((P==null?void 0:P.api)==="webApi_renderSvg"){let S=[];try{S=JSON.parse(P.product)}catch(c){console.log("\u{1F680} ~ error:",c)}S=S.filter(c=>c.base64),S.length===3?(d.success("\u56FE\u7247\u751F\u6210\u6210\u529F"),k(S)):d.error("\u56FE\u7247\u751F\u6210\u5931\u8D25")}},k=x=>A(this,null,function*(){var P,S,c;for(let L=0;L<x.length;L++){const D=g(x[L].base64,`${Date.now()}p${L}.png`);x[L].url=yield _t(D)}e.musicImg=((P=x[0])==null?void 0:P.url)||"",e.musicFirstImg=((S=x[1])==null?void 0:S.url)||"",e.musicJianImg=((c=x[2])==null?void 0:c.url)||"",x=[],I("close"),I("confirm",e)}),g=(x,P)=>{var j;let S=x.split(",")||[],c=(j=S[0].match(/:(.*?);/))==null?void 0:j[1],L=atob(S[1]),D=L.length,F=new Uint8Array(D);for(;D--;)F[D]=L.charCodeAt(D);return new File([F],P,{type:c})};return ce(()=>{a(),window.addEventListener("message",y)}),Xe(()=>{window.removeEventListener("message",y)}),()=>t("iframe",{class:ue.productIframe,src:l.productIfameSrc},null)}}),ea="_musiceBeatTime_khkvo_1",ta="_tit_khkvo_10",aa="_iframe_khkvo_18",Ie={musiceBeatTime:ea,tit:ta,iframe:aa},st=se({name:"musiceBeatTime",props:{id:{type:String}},emits:["close"],setup(u,{emit:I}){const d=ne();ce(()=>{window.addEventListener("message",l)}),Xe(()=>{window.removeEventListener("message",l)});function l(L){const D=L.data;(D==null?void 0:D.api)==="webApi_beatTimes"&&(a.value=!1,e(D))}function e(L){return A(this,null,function*(){try{const{beatTime:D,singBeatTime:F,mingBeatTime:j,isBeatTime:o,isSingBeatTime:b,isMingBeatTime:h}=JSON.parse(L.data);yield pt({id:u.id,playTimeList:D,singTimeList:F,solmizationTimeList:j,playTimeSilence:o,singTimeSilence:b,solmizationTimeSilence:h}),d.success("\u8282\u62CD\u5668\u751F\u6210\u6210\u529F"),I("close")}catch(D){console.log("\u{1F680} ~ \u97F3\u9891\u5408\u6210\u5931\u8D25",D),d.error("\u8282\u62CD\u5668\u751F\u6210\u5931\u8D25"),I("close",!0)}})}const a=Q(!0),k=Ut().getToken,g={dev:"https://dev.kt.colexiu.com",test:"https://test.lexiaoya.cn",online:"https://mec.colexiu.com"},x=location.origin.includes("//dev")?"dev":location.origin.includes("//test")?"test":location.origin.includes("//mec.colexiu")?"online":"dev",P=g[x];let c=(/(localhost|192)/.test(location.host)?"https://dev.kt.colexiu.com/":P)+`/instrument/?_t=${Date.now()}&id=${u.id}&Authorization=${k}&isCbs=true&isbeatTimes=true&musicRenderType=staff`;return()=>t("div",{class:Ie.musiceBeatTime},[t("div",{class:Ie.tit},[m("\u8282\u62CD\u5668\u97F3\u9891\u751F\u6210\u4E2D...")]),a.value&&t("iframe",{class:Ie.iframe,width:"667px",height:"375px",frameborder:"0",src:c},null)])}}),it=se({name:"music-platform",props:{type:{type:String,default:""},useProject:{type:Array,required:!0,default:[]},id:{type:String,required:!0,default:null}},emits:["close","getList"],setup(u,{emit:I}){const d=ne(),l=ee({gym:{applicationId:"",checked:!0,paymentType:"VIP",isConvertibleScore:!1,scoreType:"STAVE",status:!1,sortNo:null},gyt:{applicationId:"",checked:!0,availableType:"PLATFORM",isConvertibleScore:!1,scoreType:"STAVE",status:!1,sortNo:null},klxt:{applicationId:"",checked:!0,isConvertibleScore:!1,scoreType:"STAVE",status:!1,sortNo:null},klx:{applicationId:"",checked:!0,musicTagIds:[],paymentType:["VIP"],musicPrice:null,availableType:"PLATFORM",topFlag:!1,exquisiteFlag:!1,isConvertibleScore:!0,scoreType:"FIRST",status:!1,sortNo:null},kt:{applicationId:"",checked:!0,musicSheetCategoryId:null,paymentType:"VIP",isConvertibleScore:!0,scoreType:"FIRST",status:!1,sortNo:null}}),e=ke(()=>({GYM:P("GYM"),KLX_JG:P("KLX_JG"),KLX:P("KLX"),KT:P("KT"),GYT:P("GYT")})),a=Q(),y=Q(!1),k=Q([]),g=Q([]),x=Q(!1),P=o=>(u.useProject||[]).findIndex(h=>h.appKey===o)!==-1,S=()=>{let o=!1;const b=l.gym;if(b.checked){if(!b.paymentType)return d.error("\u8BF7\u9009\u62E9\u6536\u8D39\u65B9\u5F0F"),!0;if(console.log(b.isConvertibleScore,"gym.isConvertibleScore"),b.isConvertibleScore==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u652F\u6301\u8F6C\u8C31"),!0;if(!b.scoreType)return d.error("\u8BF7\u9009\u62E9\u9ED8\u8BA4\u8C31\u9762"),!0;if(b.status==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u542F\u7528"),!0}const h=l.gyt;if(h.checked){if(!h.availableType)return d.error("\u8BF7\u9009\u62E9\u53EF\u7528\u9014\u5F84"),!0;if(h.isConvertibleScore==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u652F\u6301\u8F6C\u8C31"),!0;if(!h.scoreType)return d.error("\u8BF7\u9009\u62E9\u9ED8\u8BA4\u8C31\u9762"),!0;if(h.status==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u542F\u7528"),!0}const K=l.klxt;if(K.checked){if(K.isConvertibleScore==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u652F\u6301\u8F6C\u8C31"),!0;if(!K.scoreType)return d.error("\u8BF7\u9009\u62E9\u9ED8\u8BA4\u8C31\u9762"),!0;if(K.status==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u542F\u7528"),!0}const i=l.klx;if(i.checked){if(i.musicTagIds.length<=0)return d.error("\u8BF7\u9009\u62E9\u66F2\u76EE\u6807\u7B7E"),!0;if(!i.paymentType||i.paymentType.length<=0)return d.error("\u8BF7\u9009\u62E9\u6536\u8D39\u65B9\u5F0F"),!0;if(!i.paymentType.includes("CHARGE"))i.musicPrice=0;else if(i.musicPrice===null||i.musicPrice===void 0||i.musicPrice==="")return d.error("\u66F2\u76EE\u4EF7\u683C\u4E0D\u80FD\u4E3A\u7A7A"),!0;if(typeof i.topFlag!="boolean")return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u7F6E\u9876"),!0;if(typeof i.exquisiteFlag!="boolean")return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u7CBE\u54C1"),!0;if(i.isConvertibleScore==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u652F\u6301\u8F6C\u8C31"),!0;if(!i.scoreType)return d.error("\u8BF7\u9009\u62E9\u9ED8\u8BA4\u8C31\u9762"),!0;if(i.status==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u542F\u7528"),!0}const T=l.kt;if(T.checked){if(!T.musicSheetCategoryId)return d.error("\u8BF7\u9009\u62E9\u4E50\u8C31\u6559\u6750"),!0;if(!T.paymentType)return d.error("\u8BF7\u9009\u62E9\u6536\u8D39\u65B9\u5F0F"),!0;if(T.isConvertibleScore==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u652F\u6301\u8F6C\u8C31"),!0;if(!T.scoreType)return d.error("\u8BF7\u9009\u62E9\u9ED8\u8BA4\u8C31\u9762"),!0;if(T.status==null)return d.error("\u8BF7\u9009\u62E9\u662F\u5426\u542F\u7528"),!0}return o},c=()=>{const o=[],b=[];return l.gym.checked&&(o.push(G({},l.gym)),b.push(l.gym.applicationId)),l.gyt.checked&&(o.push(G({},l.gyt)),b.push(l.gyt.applicationId)),l.klxt.checked&&(o.push(G({},l.klxt)),b.push(l.klxt.applicationId)),l.klx.checked&&(o.push(Z(G({},l.klx),{musicTagIds:l.klx.musicTagIds.join(","),paymentType:l.klx.paymentType.join(",")})),b.push(l.klx.applicationId)),l.kt.checked&&(o.push(G({},l.kt)),b.push(l.kt.applicationId)),{musicSheetId:u.id,applicationExtends:o||{},useApplicationIds:b.join(",")||""}},L=()=>A(this,null,function*(){try{if(S())return;x.value=!0;const o=c();yield gt(o),d.success("\u4FDD\u5B58\u6210\u529F"),I("close"),I("getList")}catch(o){}x.value=!1}),D=()=>A(this,null,function*(){try{const b=(u.useProject||[]).find(K=>K.appKey==="KLX");if(!b)return;const{data:h}=yield mt({applicationId:b.id});h&&h.length>0&&h.forEach(K=>{k.value.push(Z(G({},K),{label:K.name,value:K.id}))})}catch(o){}}),F=()=>A(this,null,function*(){const b=(u.useProject||[]).find(K=>K.appKey==="KT");if(!b)return;const h=yield ft({applicationIds:b.id});h.data&&h.data.length>0&&(g.value=h.data[0].musicSheetCategories)}),j=()=>A(this,null,function*(){try{const{data:o}=yield ht({musicSheetId:u.id});(o||[]).forEach(h=>{h.appKey==="GYM"?(l.gym.checked=!0,l.gym.paymentType=h.paymentType,l.gym.isConvertibleScore=h.isConvertibleScore,l.gym.scoreType=h.scoreType,l.gym.status=h.status,l.gym.sortNo=h.sortNo):h.appKey==="GYT"?(l.gyt.checked=!0,l.gyt.availableType=h.availableType,l.gyt.isConvertibleScore=h.isConvertibleScore,l.gyt.scoreType=h.scoreType,l.gyt.status=h.status,l.gyt.sortNo=h.sortNo):h.appKey==="KLX_JG"?(l.klxt.checked=!0,l.klxt.isConvertibleScore=h.isConvertibleScore,l.klxt.scoreType=h.scoreType,l.klxt.status=h.status,l.klxt.sortNo=h.sortNo):h.appKey==="KLX"?(l.klx.checked=!0,l.klx.musicTagIds=h.musicTagIds?h.musicTagIds.split(","):[],l.klx.paymentType=h.paymentType?h.paymentType.split(","):[],l.klx.musicPrice=h.musicPrice,l.klx.availableType=h.availableType,l.klx.topFlag=h.topFlag,l.klx.exquisiteFlag=h.exquisiteFlag,l.klx.isConvertibleScore=h.isConvertibleScore,l.klx.scoreType=h.scoreType,l.klx.status=h.status,l.klx.sortNo=h.sortNo):h.appKey==="KT"&&(l.kt.checked=!0,l.kt.musicSheetCategoryId=h.musicSheetCategoryId,l.kt.paymentType=h.paymentType,l.kt.isConvertibleScore=h.isConvertibleScore,l.kt.scoreType=h.scoreType,l.kt.status=h.status,l.kt.sortNo=h.sortNo)})}catch(o){}});return ce(()=>A(this,null,function*(){y.value=!0,u.type!=="add"&&(l.gym.checked=!1,l.gyt.checked=!1,l.klxt.checked=!1,l.klx.checked=!1,l.kt.checked=!1),(u.useProject||[]).forEach(b=>{b.appKey==="GYM"?l.gym.applicationId=b.id:b.appKey==="KLX_JG"?l.klxt.applicationId=b.id:b.appKey==="KLX"?l.klx.applicationId=b.id:b.appKey==="KT"?l.kt.applicationId=b.id:b.appKey==="GYT"&&(l.gyt.applicationId=b.id)}),yield D(),yield F(),yield j(),y.value=!1})),()=>t(He,{show:y.value},{default:()=>[t(Ce,{model:l,ref:a,"label-placement":"top","label-width":"85"},{default:()=>[e.value.GYM&&t(R,{cols:8,xGap:12,style:{marginBottom:"12px"}},{default:()=>[t(N,{span:1,style:{display:"flex",alignItems:"center"}},{default:()=>[t(pe,{checked:l.gym.checked,"onUpdate:checked":o=>l.gym.checked=o},{default:()=>[m("\u7BA1\u4E50\u8FF7")]})]}),t(N,{span:7,style:{background:"#f9f9f9",padding:"20px 16px 0",borderRadius:"8px"}},{default:()=>[t(R,{cols:6,xGap:12},{default:()=>[t(N,null,{default:()=>[t(v,{label:"\u6536\u8D39\u65B9\u5F0F",path:"paymentType",required:!0},{default:()=>[t(M,{value:l.gym.paymentType,"onUpdate:value":o=>l.gym.paymentType=o,clearable:!0,options:[{label:"\u514D\u8D39",value:"FREE"},{label:"\u6536\u8D39",value:"VIP"}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u652F\u6301\u8F6C\u8C31",path:"isConvertibleScore",required:!0},{default:()=>[t(M,{value:l.gym.isConvertibleScore,"onUpdate:value":o=>l.gym.isConvertibleScore=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u9ED8\u8BA4\u8C31\u9762",path:"scoreType",required:!0},{default:()=>[t(M,{value:l.gym.scoreType,"onUpdate:value":o=>l.gym.scoreType=o,options:re(ge)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u542F\u7528",path:"status",required:!0},{default:()=>[t(M,{value:l.gym.status,"onUpdate:value":o=>l.gym.status=o,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6392\u5E8F",path:"sortNo"},{default:()=>[t(de,{precision:0,min:0,max:999999999,value:l.gym.sortNo,"onUpdate:value":o=>l.gym.sortNo=o,showButton:!1},null)]})]})]})]})]}),e.value.GYT&&t(R,{cols:8,xGap:12,style:{marginBottom:"12px"}},{default:()=>[t(N,{span:1,style:{display:"flex",alignItems:"center"}},{default:()=>[t(pe,{checked:l.gyt.checked,"onUpdate:checked":o=>l.gyt.checked=o},{default:()=>[m("\u7BA1\u4E50\u56E2")]})]}),t(N,{span:7,style:{background:"#f9f9f9",padding:"20px 16px 0",borderRadius:"8px"}},{default:()=>[t(R,{cols:6,xGap:12},{default:()=>[t(N,null,{default:()=>[t(v,{label:"\u53EF\u7528\u9014\u5F84",path:"availableType",required:!0},{default:()=>[t(M,{value:l.gyt.availableType,"onUpdate:value":o=>l.gyt.availableType=o,clearable:!0,options:[{label:"\u5B66\u6821",value:"ORG"},{label:"\u5E73\u53F0",value:"PLATFORM"}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u652F\u6301\u8F6C\u8C31",path:"isConvertibleScore",required:!0},{default:()=>[t(M,{value:l.gyt.isConvertibleScore,"onUpdate:value":o=>l.gyt.isConvertibleScore=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u9ED8\u8BA4\u8C31\u9762",path:"scoreType",required:!0},{default:()=>[t(M,{value:l.gyt.scoreType,"onUpdate:value":o=>l.gyt.scoreType=o,options:re(ge)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u542F\u7528",path:"status",required:!0},{default:()=>[t(M,{value:l.gyt.status,"onUpdate:value":o=>l.gyt.status=o,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6392\u5E8F",path:"sortNo"},{default:()=>[t(de,{precision:0,min:0,max:999999999,value:l.gyt.sortNo,"onUpdate:value":o=>l.gyt.sortNo=o,showButton:!1},null)]})]})]})]})]}),e.value.KLX_JG&&t(R,{cols:8,xGap:12,style:{marginBottom:"12px"}},{default:()=>[t(N,{span:1,style:{display:"flex",alignItems:"center"}},{default:()=>[t(pe,{checked:l.klxt.checked,"onUpdate:checked":o=>l.klxt.checked=o},{default:()=>[m("\u9177\u4E50\u79C0\u673A\u6784")]})]}),t(N,{span:7,style:{background:"#f9f9f9",padding:"20px 16px 0",borderRadius:"8px"}},{default:()=>[t(R,{cols:6,xGap:12},{default:()=>[t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u652F\u6301\u8F6C\u8C31",path:"isConvertibleScore",required:!0},{default:()=>[t(M,{value:l.klxt.isConvertibleScore,"onUpdate:value":o=>l.klxt.isConvertibleScore=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u9ED8\u8BA4\u8C31\u9762",path:"scoreType",required:!0},{default:()=>[t(M,{value:l.klxt.scoreType,"onUpdate:value":o=>l.klxt.scoreType=o,options:re(ge)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u542F\u7528",path:"status",required:!0},{default:()=>[t(M,{value:l.klxt.status,"onUpdate:value":o=>l.klxt.status=o,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6392\u5E8F",path:"sortNo"},{default:()=>[t(de,{precision:0,min:0,max:999999999,value:l.klxt.sortNo,"onUpdate:value":o=>l.klxt.sortNo=o,showButton:!1},null)]})]})]})]})]}),e.value.KLX&&t(R,{cols:8,xGap:12,style:{marginBottom:"12px"}},{default:()=>[t(N,{span:1,style:{display:"flex",alignItems:"center"}},{default:()=>[t(pe,{checked:l.klx.checked,"onUpdate:checked":o=>l.klx.checked=o},{default:()=>[m("\u9177\u4E50\u79C0\u5E73\u53F0")]})]}),t(N,{span:7,style:{background:"#f9f9f9",padding:"20px 16px 0",borderRadius:"8px"}},{default:()=>[t(R,{cols:6,xGap:12},{default:()=>[t(N,null,{default:()=>[t(v,{label:"\u66F2\u76EE\u6807\u7B7E",required:!0},{default:()=>[t(M,{value:l.klx.musicTagIds,"onUpdate:value":o=>l.klx.musicTagIds=o,multiple:!0,maxTagCount:1,clearable:!0,options:k.value},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6536\u8D39\u65B9\u5F0F",path:"paymentType",required:!0},{default:()=>[t(M,{value:l.klx.paymentType,"onUpdate:value":[o=>l.klx.paymentType=o,o=>{l.klx.paymentType=o;const b="FREE";l.klx.paymentType[l.klx.paymentType.length-1]==b?l.klx.paymentType=[b]:l.klx.paymentType.length>1&&l.klx.paymentType.includes(b)&&l.klx.paymentType.splice(l.klx.paymentType.indexOf(b),1),l.klx.paymentType.includes("CHARGE")||(l.klx.musicPrice=0)}],multiple:!0,maxTagCount:1,clearable:!0,options:re(Rt)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u66F2\u76EE\u4EF7\u683C",path:"musicPrice",required:!0},{default:()=>{var o;return[t(de,{disabled:!((o=l.klx.paymentType)!=null&&o.includes("CHARGE")),precision:2,min:0,max:9999,value:l.klx.musicPrice,"onUpdate:value":b=>l.klx.musicPrice=b,showButton:!1},null)]}})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u7F6E\u9876",path:"topFlag",required:!0},{default:()=>[t(M,{value:l.klx.topFlag,"onUpdate:value":o=>l.klx.topFlag=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u7CBE\u54C1",path:"exquisiteFlag",required:!0},{default:()=>[t(M,{value:l.klx.exquisiteFlag,"onUpdate:value":o=>l.klx.exquisiteFlag=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u652F\u6301\u8F6C\u8C31",path:"isConvertibleScore",required:!0},{default:()=>[t(M,{value:l.klx.isConvertibleScore,"onUpdate:value":o=>l.klx.isConvertibleScore=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u9ED8\u8BA4\u8C31\u9762",path:"scoreType",required:!0},{default:()=>[t(M,{value:l.klx.scoreType,"onUpdate:value":o=>l.klx.scoreType=o,options:re(ge)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u542F\u7528",path:"status",required:!0},{default:()=>[t(M,{value:l.klx.status,"onUpdate:value":o=>l.klx.status=o,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6392\u5E8F",path:"sortNo"},{default:()=>[t(de,{precision:0,min:0,max:999999999,value:l.klx.sortNo,"onUpdate:value":o=>l.klx.sortNo=o,showButton:!1},null)]})]})]})]})]}),e.value.KT&&t(R,{cols:8,xGap:12,style:{marginBottom:"12px"}},{default:()=>[t(N,{span:1,style:{display:"flex",alignItems:"center"}},{default:()=>[t(pe,{checked:l.kt.checked,"onUpdate:checked":o=>l.kt.checked=o},{default:()=>[m("\u97F3\u4E50\u6570\u5B57\u8BFE\u5802")]})]}),t(N,{span:7,style:{background:"#f9f9f9",padding:"20px 16px 0",borderRadius:"8px"}},{default:()=>[t(R,{cols:6,xGap:12},{default:()=>[t(N,null,{default:()=>[t(v,{label:"\u4E50\u8C31\u6559\u6750",path:"musicSheetCategoryId",required:!0},{default:()=>[t(M,{value:l.kt.musicSheetCategoryId,"onUpdate:value":o=>l.kt.musicSheetCategoryId=o,clearable:!0,options:g.value,labelField:"name",valueField:"id"},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6536\u8D39\u65B9\u5F0F",path:"paymentType",required:!0},{default:()=>[t(M,{value:l.kt.paymentType,"onUpdate:value":o=>l.kt.paymentType=o,clearable:!0,options:[{label:"\u514D\u8D39",value:"FREE"},{label:"\u4F1A\u5458",value:"VIP"}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u652F\u6301\u8F6C\u8C31",path:"isConvertibleScore",required:!0},{default:()=>[t(M,{value:l.kt.isConvertibleScore,"onUpdate:value":o=>l.kt.isConvertibleScore=o,clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u9ED8\u8BA4\u8C31\u9762",path:"scoreType",required:!0},{default:()=>[t(M,{value:l.kt.scoreType,"onUpdate:value":o=>l.kt.scoreType=o,options:re(ge)},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u662F\u5426\u542F\u7528",path:"status",required:!0},{default:()=>[t(M,{value:l.kt.status,"onUpdate:value":o=>l.kt.status=o,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]})]}),t(N,null,{default:()=>[t(v,{label:"\u6392\u5E8F",path:"sortNo"},{default:()=>[t(de,{precision:0,min:0,max:999999999,value:l.kt.sortNo,"onUpdate:value":o=>l.kt.sortNo=o,showButton:!1},null)]})]})]})]})]}),t(W,{justify:"end",style:"margin-top: 10px"},{default:()=>[t(O,{type:"default",onClick:()=>I("close",!0)},{default:()=>[m("\u53D6\u6D88")]}),t(O,{type:"primary",onClick:()=>L(),loading:x.value,disabled:x.value},{default:()=>[m("\u786E\u8BA4")]})]})]})]})}});function qe(u){return typeof u=="function"||Object.prototype.toString.call(u)==="[object Object]"&&!Ze(u)}const la=(u,I)=>{var k;let d=0;const l=u.closest(I);let e=l;const a=l==null?void 0:l.closest("measure");let y=null;for(;!y&&d<((a==null?void 0:a.childNodes.length)||50);)d++,((k=e==null?void 0:e.nextElementSibling)==null?void 0:k.tagName)==="note"&&(y=e==null?void 0:e.nextElementSibling),e=e==null?void 0:e.nextElementSibling;return y},sa=(u,I)=>{var y,k;if(!u)return"";const d=new DOMParser().parseFromString(u,"text/xml"),l=((k=(y=d.getElementsByTagName("part-list"))==null?void 0:y[0])==null?void 0:k.getElementsByTagName("score-part"))||[],e=d.getElementsByTagName("part"),a=l[I];if(a){const g=a.getAttribute("id");Array.from(e).forEach(S=>{var c,L,D;if(S&&S.getAttribute("id")!==g&&((c=S.parentNode)==null||c.removeChild(S)),S&&S.getAttribute("id")===g){const F=S.getElementsByTagName("barline"),j=(L=F[F.length-1])==null?void 0:L.parentElement;if(((D=j==null?void 0:j.lastElementChild)==null?void 0:D.tagName)!=="barline"){const o=(j==null?void 0:j.children)||[];for(let b of o)if(b.tagName==="barline"){j==null||j.appendChild(b);break}}}}),Array.from(l).forEach(S=>{var c;S&&S.getAttribute("id")!==g&&((c=S.parentNode)==null||c.removeChild(S))});const x=d.getElementsByTagName("note"),P=S=>{var L;let c=x[S+1];for(let D=S;D<x.length;D++){const F=x[D];if(!((L=F.getElementsByTagName("grace"))!=null&&L.length)){c=F;break}}return c==null?void 0:c.getElementsByTagName("duration")[0]};Array.from(x).forEach((S,c)=>{var D;const L=S.getElementsByTagName("grace");L&&L.length&&P(c)&&(S==null||S.appendChild((D=P(c))==null?void 0:D.cloneNode(!0)))})}return new XMLSerializer().serializeToString(d)},ia={"rall.":1.333333333,"poco rit.":1.333333333,"rit.":1.333333333,"molto rit.":1.333333333,"molto rall":1.333333333,molto:1.333333333,lentando:1.333333333,allargando:1.333333333,morendo:1.333333333,"accel.":.8,calando:2,"poco accel.":.8,"gradually slowing":1.333333333,slowing:1.333333333,slow:1.333333333,slowly:1.333333333,faster:1.333333333};function ze(u){var S,c,L,D;const I=sa(u,0),d=new DOMParser().parseFromString(I,"text/xml"),l=Array.from(d.querySelectorAll("measure")),e=Array.from(d.querySelectorAll("note")),a=Array.from(d.querySelectorAll("words")),y=Array.from(d.querySelectorAll("metronome")),k=[];for(const F of[...a,...y]){const j=la(F,"direction");if(j){const o=j==null?void 0:j.closest("measure"),b=Array.from(o.querySelectorAll("note")),h=Array.from(o.childNodes).filter(T=>T.nodeName==="note").findIndex(T=>T===j);let K=0,i=0;for(let T=0;T<b.length;T++){const $=+(((S=b[T].querySelector("duration"))==null?void 0:S.textContent)||"0");K+=$,T<h&&(i=K)}k.push({ele:F,index:e.indexOf(j),noteInMeasureIndex:h,textContent:F.textContent,measureIndex:o!=null&&o.getAttribute("number")?Number(o==null?void 0:o.getAttribute("number")):l.indexOf(o),type:F.tagName,allDuration:K,leftDuration:i})}}k.push({ele:e[e.length-1],index:e.length,noteInMeasureIndex:0,textContent:"",type:"metronome",allDuration:1,leftDuration:1,measureIndex:l.length});const g=[];k.sort((F,j)=>F.index-j.index);const x=Object.keys(ia).map(F=>F.toLocaleLowerCase());let P=!1;for(const F of k){const j=(c=F.textContent)==null?void 0:c.toLocaleLowerCase().trim();F===k[k.length-1]&&((L=g[g.length-1])==null?void 0:L.length)===1&&(P=!0);const o=x.find(b=>{const h=b.split(" ");return j&&h.includes(j)});if(F.type==="metronome"||F.type==="words"&&(j.startsWith("a tempo")||o)||P){const b=g.findIndex(h=>h.length===1);b>-1&&F.index>((D=g[b])==null?void 0:D[0].start)&&(g[b][1]={start:F.index,measureIndex:F.measureIndex,noteInMeasureIndex:F.noteInMeasureIndex,allDuration:F.allDuration,leftDuration:F.leftDuration,type:j})}F.type==="words"&&o&&g.push([{start:F.index,measureIndex:F.measureIndex,noteInMeasureIndex:F.noteInMeasureIndex,allDuration:F.allDuration,leftDuration:F.leftDuration,type:j}])}return g}const ua=u=>{var e,a,y;const I={speed:0,title:"",composer:"",partNames:[]},d=new DOMParser().parseFromString(u,"text/xml");I.title=((e=d.getElementsByTagName("work-title")[0])==null?void 0:e.textContent)||"",I.composer=((a=d.getElementsByTagName("creator")[0])==null?void 0:a.textContent)||"";const l=d.getElementsByTagName("measure");for(const k of Array.from(d.getElementsByTagName("part-name")))(y=k.textContent)!=null&&y.trim()&&I.partNames.push(k.textContent);for(const k of Array.from(l)){const g=k.getElementsByTagName("per-minute");if(g.length&&g[g.length-1]){I.speed=parseFloat(g[g.length-1].textContent||"0");break}}return I},ra=se({name:"music-operation",props:{type:{type:String,default:"add"},data:{type:Object,default:()=>{}},tagList:{type:Array,default:()=>[]},subjectList:{type:Array,default:()=>[]}},emits:["close","getList"],setup(u,{slots:I,attrs:d,emit:l}){const e=ee({details:{},graduals:{},playMode:"MP3",xmlFileUrl:null,midiUrl:null,name:null,composer:null,playSpeed:null,musicCover:null,remark:null,musicSheetSoundList_YY:[],musicSheetSoundList_YZ:[],musicSheetSoundList_all_subject:null,status:!0,musicSheetType:"CONCERT",sourceType:"PLATFORM",appAuditFlag:0,midiFileUrl:null,subjectIds:[],musicalInstrumentIdList:[],musicCategoryId:null,musicSheetAccompanimentList:[],audioType:"HOMEMODE",isPlayBeat:!0,isUseSystemBeat:!0,isUseSingSystemBeat:!0,repeatedBeats:!1,repeatedBeatsToSing:!1,isPlaySingBeat:!0,evaluationStandard:"FREQUENCY",multiTracksSelection:[],musicSheetExtend:{},musicImg:"",musicFirstImg:"",musicJianImg:"",isEvxml:!1,isShowFingering:!0,solmizationFileUrl:null,isAllSubject:!1,fSongList:[],isScoreRender:!0,defaultScoreRender:!0,scoreAudioFileUrl:null}),a=ee({loading:!1,musicUpdateLoading:!1,previewMode:!1,tagList:[...u.tagList],xmlFirstSpeed:null,partListNames:[],musicSheetCategories:[],musicSheetAccompanimentUrl:null,instrumentData:[],instrumentList:[],instrumentIdNameMap:new Map,subjectList:[],showMusicSheetOwnerDialog:!1,multiTracks:null,multiInstruments:null,appData:[],ownerName:null,productOpen:!1,productItem:{},productIfameSrc:"",isAutoSave:!1,bSongFile:null,musicSheetSoundList:[],subjectDisabled:!1,instrumentDisabled:!1,initFSongMap:new Map,showUseProject:!1,showUseProjectId:null,useProjectData:[],isCreateImg:!1,isBeatTime:!1}),y=ee({list:[],gradualRefs:[]}),k=ee({beatTimeOpen:!1,musicId:""});We(()=>e.multiTracksSelection,p=>{if(a.musicUpdateLoading){a.musicUpdateLoading=!1;return}b(p),F()});const g=Q(!1),x=Q(),P=ne(),S=we(),c=()=>A(this,null,function*(){x.value.validate(p=>A(this,null,function*(){if(!p){if(e.musicSheetType=="CONCERT"){let r=[];const{data:s}=yield Le({page:1,rows:9999});s.rows.map(f=>{f.code&&f.code.split(",").forEach(U=>{r.push(U.replaceAll(" ","").toLocaleLowerCase())})});let n=[];if(e.multiTracksSelection.forEach(f=>{if(f&&!D(f)){let U=!1,_=f.replace(" ","").toLocaleLowerCase();for(let q=0;q<r.length;q++)if(_.startsWith(r[q])){U=!0;break}U||n.push(f)}}),n.length>0){S.warning({title:"\u63D0\u793A",content:`\u58F0\u8F68\u672A\u914D\u7F6E\uFF1A${n.join(",")}`,positiveText:"\u786E\u5B9A",onPositiveClick:()=>{}});return}}try{let r=new Set,s=[],n=e.musicSheetType,f=!1;n=="SINGLE"?e.isAllSubject?e.musicSheetSoundList_all_subject&&(r.add("PLAY"),s.push({audioFileUrl:e.musicSheetSoundList_all_subject,musicSheetId:u.data.id,audioPlayType:"PLAY"}),f=!0):e.musicSheetSoundList_YZ.length>0&&e.musicSheetSoundList_YZ.forEach(w=>{e.musicalInstrumentIdList.includes(w.musicalInstrumentId)&&w.audioFileUrl&&(f=!0,s.push(Z(G({},w),{musicSheetId:u.data.id})),r.has("PLAY")||r.add("PLAY"))}):n=="CONCERT"&&e.musicSheetSoundList_YY.forEach(w=>{w.audioFileUrl&&e.multiTracksSelection.includes(w.track)&&(s.push(Z(G({},w),{musicalInstrumentId:w.musicalInstrumentId||i(w.track),musicSheetId:u.data.id,audioPlayType:"PLAY"})),f=!0,r.has("PLAY")||r.add("PLAY"))});let U=!1;console.log(e.fSongList,"forms.fSongList");for(let w=0;w<e.fSongList.length;w++){let V=e.fSongList[w];(V.audioFileUrl||V.solmizationFileUrl||V.femaleSolmizationFileUrl)&&(s.push(V),r.add("SING"),U=!0)}if((e.scoreAudioFileUrl||a.bSongFile)&&(U=!0),!U&&!f){P.warning("\u8BF7\u4E0A\u4F20\u97F3\u9891\u6587\u4EF6");return}if(!a.isAutoSave&&a.isCreateImg){a.isAutoSave=!0,a.productOpen=!0;return}console.log(e.scoreAudioFileUrl,"forms.scoreAudioFileUrl"),e.scoreAudioFileUrl?e.musicSheetAccompanimentList.push({musicSheetId:u.data.id,audioFileUrl:a.bSongFile,scoreAudioFileUrl:e.multiTracksSelection.length>1&&e.isScoreRender&&e.scoreAudioFileUrl?e.scoreAudioFileUrl:null,audioPlayType:"SING"}):e.musicSheetAccompanimentList.push({musicSheetId:u.data.id,audioFileUrl:a.bSongFile,audioPlayType:"SING"}),a.musicSheetAccompanimentUrl&&e.musicSheetAccompanimentList.push({musicSheetId:u.data.id,audioFileUrl:a.musicSheetAccompanimentUrl,audioPlayType:"PLAY"});let _,q;e.multiTracksSelection.length>1&&(_=e.isScoreRender,e.isScoreRender&&(q=e.defaultScoreRender));const E={musicCategoryId:e.musicCategoryId,musicCover:e.musicCover,name:e.name,appAuditFlag:e.appAuditFlag,subjectIds:e.isAllSubject?"":e.subjectIds.join(","),remark:e.remark,audioPlayTypes:Array.from(r).join(","),musicalInstrumentIds:e.isAllSubject?"":e.musicalInstrumentIdList.join(","),composer:e.composer,musicSheetType:e.musicSheetType,isUseSystemBeat:e.isUseSystemBeat,isShowFingering:e.isShowFingering,isPlayBeat:e.isPlayBeat,multiTracksSelection:e.multiTracksSelection.join(","),playSpeed:e.playSpeed,playMode:e.playMode,xmlFileUrl:e.xmlFileUrl,musicImg:e.musicImg,musicFirstImg:e.musicFirstImg,musicJianImg:e.musicJianImg,extConfigJson:JSON.stringify({repeatedBeats:e.repeatedBeats?1:0,gradualTimes:e.graduals,isEvxml:e.isEvxml?1:0,repeatedBeatsToSing:e.repeatedBeatsToSing?1:0}),sourceType:e.sourceType,audioType:e.audioType,status:e.status,evaluationStandard:e.evaluationStandard,musicSheetAccompanimentList:e.musicSheetAccompanimentList,musicSheetSoundList:s,musicTag:"-1",isUseSingSystemBeat:e.isUseSingSystemBeat,isPlaySingBeat:e.isPlaySingBeat,isAllSubject:e.isAllSubject,musicSheetExtend:e.sourceType=="PLATFORM"?null:e.musicSheetExtend,isScoreRender:_,defaultScoreRender:q};e.audioType=="MIDI"&&(E.musicSheetSoundList=[]),console.log(E,"obj"),g.value=!0;let C;u.type==="add"?C=yield Ae(E):u.type==="edit"&&(C=yield Ae(Z(G({},E),{id:u.data.id}))),a.isBeatTime?(k.beatTimeOpen=!0,k.musicId=C.data,a.showUseProjectId=C.data):(a.showUseProjectId=C.data,a.showUseProject=!0,setTimeout(()=>{g.value=!1,a.isAutoSave=!1},100))}catch(r){console.log(r),setTimeout(()=>{g.value=!1,a.isAutoSave=!1},100)}}}))});function L(p){p||(u.type==="add"?P.success("\u6DFB\u52A0\u6210\u529F"):u.type==="edit"&&P.success("\u4FEE\u6539\u6210\u529F")),l("getList"),l("close"),setTimeout(()=>{g.value=!1,a.isAutoSave=!1},100)}const D=p=>A(this,null,function*(){return!!(p&&(p=="P1"||p=="P2"||p=="P3"||p=="P4"))}),F=()=>A(this,null,function*(){e.fSongList.forEach(r=>{a.initFSongMap.set(r.track,r)});let p=[];e.multiTracksSelection.forEach(r=>{a.initFSongMap.has(r)?p.push(a.initFSongMap.get(r)):p.push({musicSheetId:u.data.id,audioFileUrl:null,audioPlayType:"SING",musicalInstrumentId:null,track:r,musicalInstrumentName:null,solmizationFileUrl:null,femaleSolmizationFileUrl:null})}),e.fSongList=p}),j=p=>{a.isCreateImg=!0;const r=new FileReader;r.onload=s=>{var _,q,E;try{y.list=ze((_=s==null?void 0:s.target)==null?void 0:_.result).filter(w=>w.length===2);const C=ua((q=s==null?void 0:s.target)==null?void 0:q.result);e.composer||(e.composer=C.composer)}catch(C){}e.musicSheetSoundList_YY=e.musicSheetSoundList_YY.filter(C=>{var w,V;return!C.track||!o(C.track)||((V=(w=C.track)==null?void 0:w.toLocaleUpperCase)==null?void 0:V.call(w))!="COMMON"&&e.multiTracksSelection.includes(C.track)}),a.partListNames=T((E=s==null?void 0:s.target)==null?void 0:E.result);let n=new Map;for(let C=0;C<e.musicSheetSoundList_YY.length;C++){let w=e.musicSheetSoundList_YY[C].track;w&&n.set(w,e.musicSheetSoundList_YY[C])}let f=[],U=[];for(let C=0;C<a.partListNames.length;C++){let w=a.partListNames[C].value;n.has(w)?f.push(n.get(w)):f.push({audioFileUrl:null,track:w,musicalInstrumentId:null}),U.push(w),e.multiTracksSelection.includes(w)||e.multiTracksSelection.push(w)}for(let C=0;C<e.musicSheetSoundList_YY.length;C++){let w=e.musicSheetSoundList_YY[C].track;(!w||!U.includes(w))&&(e.musicSheetSoundList_YY[C].track=null,f.push(e.musicSheetSoundList_YY[C]))}e.musicSheetSoundList_YY=f,e.multiTracksSelection=e.multiTracksSelection.filter(C=>U.includes(C)),a.multiTracks="all",e.musicSheetSoundList_YY.length==0&&e.musicSheetSoundList_YY.push({audioFileUrl:"",track:""})},r.readAsText(p)},o=p=>{for(let r=0;r<a.partListNames.length;r++)if(a.partListNames[r].value==p)return!0;return!1},b=p=>A(this,null,function*(){if(!p||p.length<=1){e.musicSheetType="SINGLE",a.subjectDisabled=!1,a.instrumentDisabled=!1;return}e.musicSheetType="CONCERT",a.subjectDisabled=!0,a.instrumentDisabled=!0,yield K(p)}),h=(p,r="")=>{if(r=r.toLocaleLowerCase().replace(/ /g,"").replace(/\d*/gi,""),!r)return"";for(let s of p){const n=s.toLocaleLowerCase().replace(/ /g,"");if(n===r)return n}return""},K=p=>A(this,null,function*(){console.log("1111"),e.subjectIds=[];const r=new Map,s=[];a.instrumentData.forEach(n=>{n.disabled||n.code.split(/[,,]/).forEach(U=>{let _=U.replaceAll(" ","").toLowerCase();if(s.push(_),r.has(_))r.get(_).push(n.id+"");else{const q=[];q.push(n.id+""),r.set(_,q)}})});for(let n=0;n<p.length;n++){let f=p[n].replaceAll(" ","").toLowerCase();const U=h(s,f);r.has(U)&&r.get(U).forEach(_=>{const q=a.instrumentList.findIndex(E=>E.id.toString()===_);!e.musicalInstrumentIdList.includes(_)&&q!==-1&&e.musicalInstrumentIdList.push(_)})}e.musicalInstrumentIdList.length>0&&(yield $(e.musicalInstrumentIdList))}),i=p=>{const r=new Map,s=[];if(a.instrumentData.forEach(f=>{f.disabled||f.code.split(/[,,]/).forEach(_=>{let q=_.replaceAll(" ","").toLowerCase();if(s.push(q),r.has(q))r.get(q).push(f.id+"");else{const E=[];E.push(f.id+""),r.set(q,E)}})}),!p)return"";p=p.replaceAll(" ","").toLowerCase();const n=h(s,p);if(r.has(n)){const f=r.get(n);return console.log("result:",f),f[0]||""}return""},T=p=>{var f,U,_,q;if(!p)return[];const r=new DOMParser().parseFromString(p,"text/xml"),s=((U=(f=r.getElementsByTagName("part-list"))==null?void 0:f[0])==null?void 0:U.getElementsByTagName("score-part"))||[];let n=Array.from(s).map(E=>{var V,fe;let C=(V=E.getElementsByTagName("part-name"))==null?void 0:V[0],w="";if(C&&((fe=C.textContent)==null?void 0:fe.trim()))w=C.textContent||"";else{let Ee=E.getAttribute("id");Ee&&(w=Ee)}return{value:w.trim(),label:w.trim()}});return n=n.filter(E=>{var C,w;return((w=(C=E.value)==null?void 0:C.toLocaleUpperCase)==null?void 0:w.call(C))!="COMMON"}),a.xmlFirstSpeed=((q=(_=r.getElementsByTagName("per-minute"))==null?void 0:_[0])==null?void 0:q.textContent)||"",e.playSpeed||(a.xmlFirstSpeed?e.playSpeed=Number.parseFloat(a.xmlFirstSpeed):e.playSpeed=100),n},z=p=>{const r=be(a.partListNames)||[],s=e.multiTracksSelection;return r.forEach(n=>{s.includes(n.value)?n.disabled=!0:n.disabled=!1}),r||[]},$=p=>A(this,null,function*(){if(!p||p.length==0){e.subjectIds=[];return}try{const{data:r}=yield et({page:1,rows:999,musicalInstrumentIdList:p}),s=r.rows||[],n=[];s.forEach(f=>{f.enableFlag&&n.push(f.id+"")}),e.subjectIds=n}catch(r){}}),ae=p=>{S.warning({title:"\u63D0\u793A",content:"\u662F\u5426\u786E\u8BA4\u5220\u9664\u6B64\u539F\u97F3\uFF1F",positiveText:"\u786E\u5B9A",negativeText:"\u53D6\u6D88",onPositiveClick:()=>A(this,null,function*(){let s=e.musicSheetSoundList_YY[p].track;const n=e.multiTracksSelection.indexOf(s);n>-1?e.multiTracksSelection.splice(n,1):e.musicSheetSoundList_YY.splice(p,1),a.multiTracks=="all"&&a.partListNames.length!=e.multiTracksSelection.length&&(a.multiTracks=null)})})},ut=p=>{if(!p)return;let r=[];p==="all"?a.partListNames.forEach(s=>{r.push(s.value)}):p==="invert"&&a.partListNames.forEach(s=>{e.multiTracksSelection.includes(s.value)||r.push(s.value)}),e.multiTracksSelection=r},Ne=()=>{var s;if(e.sourceType=="PLATFORM"){a.ownerName="";return}if(!e.sourceType||!((s=e.musicSheetExtend)!=null&&s.userId))return;const p=e.musicSheetExtend.applicationId,r=a.appData.filter(n=>n.id==p);r.length>0&&(a.ownerName=r[0].appName),e.sourceType=="ORG"?a.ownerName=a.ownerName?a.ownerName+"-"+e.musicSheetExtend.organizationRole:e.musicSheetExtend.organizationRole:e.sourceType=="PERSON"&&(a.ownerName=a.ownerName?a.ownerName+"-"+Oe(e.musicSheetExtend.clientType,new Map(Object.entries(_e))):Oe(e.musicSheetExtend.clientType,new Map(Object.entries(_e))),e.musicSheetExtend.userName&&(a.ownerName=a.ownerName?a.ownerName+"-"+e.musicSheetExtend.userName:e.musicSheetExtend.userName),e.musicSheetExtend.phone&&(a.ownerName+="("+e.musicSheetExtend.phone+")"))};return ce(()=>A(this,null,function*(){a.loading=!0,u.type==="preview"&&(a.previewMode=!0);{if(a.instrumentList&&a.instrumentList.length>0)return;try{const{data:p}=yield Le({page:1,rows:999}),r=p.rows||[];r.forEach(s=>{s.label=s.name,s.value=s.id+"",a.instrumentIdNameMap.set(s.id+"",s.name),e.musicSheetSoundList_YZ.push({musicSheetId:u.data.id,musicalInstrumentId:s.id+"",musicalInstrumentName:s.name,audioFileUrl:null,audioPlayType:"PLAY"})}),a.instrumentData=r,a.instrumentList=be(r)}catch(p){}}a.subjectList=be(u.subjectList),a.subjectList.forEach(p=>{p.disabled=!p.enableFlag});{const p=Object.keys(Qe),{data:r}=yield tt({page:1,rows:999,parentId:0,hiddenFlag:!0}),s=r.rows||[],n=s.filter(U=>p.includes(U.appKey));n.forEach(U=>{U.label=U.appName,U.value=U.id}),a.useProjectData=n;const f=s.filter(U=>p.includes(U.appKey)&&U.appKey!=="KLX_JG");f.forEach(U=>{U.label=U.appName,U.value=U.id}),a.appData=f}try{const{data:p}=yield Fe({enable:!0});a.musicSheetCategories=at(p,"musicSheetCategoriesList")}catch(p){}if(u.type==="edit"||u.type==="preview"){const p=u.data;try{const{data:r}=yield yt({id:p.id});if(e.details=r,e.playMode=r.playMode,e.xmlFileUrl=r.xmlFileUrl,e.midiUrl=r.midiUrl,e.name=r.name,e.composer=r.composer,e.playSpeed=r.playSpeed?Number.parseFloat(r.playSpeed):100,e.defaultScoreRender=r.defaultScoreRender,e.isScoreRender=r.isScoreRender,e.musicCover=r.musicCover,e.remark=r.remark,e.status=r.status,e.sourceType=r.sourceType,e.appAuditFlag=r.appAuditFlag?1:0,e.midiFileUrl=r.midiFileUrl,e.isShowFingering=r.isShowFingering,e.isAllSubject=r.isAllSubject,e.isUseSingSystemBeat=r.isUseSingSystemBeat,e.isPlaySingBeat=r.isPlaySingBeat,e.subjectIds=[],r.subjectIds){const n=r.subjectIds.split(",")||[];console.log(n,"subjectIds",e.subjectIds),n.forEach(f=>{e.subjectIds.includes(f)||e.subjectIds.push(f)}),a.subjectList=a.subjectList.filter(f=>!f.disabled||n.includes(f.value))}e.musicCategoryId=r.musicCategoryId,e.audioType=r.audioType,e.isPlayBeat=r.isPlayBeat,e.isUseSystemBeat=r.isUseSystemBeat;try{const n=r.extConfigJson?JSON.parse(r.extConfigJson):{};e.graduals=n.gradualTimes||{},e.repeatedBeats=!!n.repeatedBeats,e.isEvxml=!!n.isEvxml,e.repeatedBeatsToSing=!!n.repeatedBeatsToSing}catch(n){}e.evaluationStandard=r.evaluationStandard,e.musicSheetExtend=r.musicSheetExtend,a.musicSheetSoundList=r.musicSheetSoundList?r.musicSheetSoundList:[],(r.musicSheetAccompanimentList?r.musicSheetAccompanimentList:[]).forEach(n=>{let f=n.audioPlayType;f&&f=="SING"?(a.bSongFile=n.audioFileUrl,e.scoreAudioFileUrl=n.scoreAudioFileUrl):a.musicSheetAccompanimentUrl=n.audioFileUrl});for(let n=0;n<a.musicSheetSoundList.length;n++)if(a.musicSheetSoundList[n].audioPlayType=="SING"&&a.musicSheetSoundList[n].track!=null)a.initFSongMap.set(a.musicSheetSoundList[n].track,G({},a.musicSheetSoundList[n]));else if(e.isAllSubject)e.musicSheetSoundList_all_subject=a.musicSheetSoundList[n].audioFileUrl;else for(let f=0;f<e.musicSheetSoundList_YZ.length;f++){let U=a.musicSheetSoundList[n].musicalInstrumentId;U&&U==e.musicSheetSoundList_YZ[f].musicalInstrumentId&&(e.musicSheetSoundList_YZ[f].audioFileUrl=a.musicSheetSoundList[n].audioFileUrl)}e.musicalInstrumentIdList=r.musicalInstrumentIds?r.musicalInstrumentIds.split(","):[],a.instrumentList=a.instrumentList.filter(n=>n.enableFlag||e.musicalInstrumentIdList.includes(n.id+"")),Ne(),Nt.get(r.xmlFileUrl).then(n=>{if(n!=null&&n.data){a.musicUpdateLoading=!0,y.list=ze(n==null?void 0:n.data).filter(E=>E.length===2),a.partListNames=T(n==null?void 0:n.data);let f=[];r.multiTracksSelection&&(r.multiTracksSelection=r.multiTracksSelection.toLocaleUpperCase()),!r.multiTracksSelection||r.multiTracksSelection.trim()==""||r.multiTracksSelection.trim()=="NULL"?f.push(""):r.multiTracksSelection.split(",").forEach(E=>{f.push(E.trim())}),f=a.partListNames.map(E=>E.label).filter(E=>f.includes(E.toLocaleUpperCase())),e.multiTracksSelection=f,e.musicSheetType=e.multiTracksSelection.length>1?"CONCERT":"SINGLE";const _=r.musicSheetSoundList?r.musicSheetSoundList:[],q=[];a.partListNames.forEach(E=>{let C=null,w=null;e.musicSheetType=="CONCERT"&&_.forEach(V=>{if(V.audioPlayType=="PLAY"){let fe="";V.track&&(fe=V.track.trim()),fe==E.value&&(C=V.audioFileUrl,w=V.musicalInstrumentId)}}),e.musicSheetSoundList_YY.push({audioFileUrl:C,musicalInstrumentId:w,track:E.value,audioPlayType:"PLAY"}),q.push(E.value)}),q.length==e.multiTracksSelection.length&&(a.multiTracks="all"),e.musicSheetType=="CONCERT"&&a.musicSheetSoundList.forEach(E=>{E.audioPlayType=="PLAY"&&E.track&&!q.includes(E.track.trim())&&E.audioPlayType=="PLAY"&&e.musicSheetSoundList_YY.push({audioFileUrl:E.audioFileUrl,musicalInstrumentId:E.musicalInstrumentId,track:E.track?E.track.trim():"",audioPlayType:"PLAY"})}),F()}})}catch(r){}}else a.subjectList=a.subjectList.filter(p=>p.enableFlag==!0),a.instrumentList=a.instrumentList.filter(p=>p.enableFlag==!0);a.loading=!1})),()=>{let p,r;return t("div",{style:"background: #fff; padding-top: 12px"},[t(He,{show:a.loading},{default:()=>[t(Ce,{class:ue.formContainer,model:e,ref:x,"label-placement":"left","label-width":"150",disabled:a.previewMode},{default:()=>[t(he,{showIcon:!1,style:{marginBottom:"12px"}},{default:()=>[m("\u57FA\u672C\u4FE1\u606F")]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u66F2\u76EE\u540D\u79F0",path:"name",rule:[{required:!0,message:"\u8BF7\u8F93\u5165\u66F2\u76EE\u540D\u79F0",trigger:["input","blur"]}]},{default:()=>[t(ie,{value:e.name,"onUpdate:value":s=>e.name=s,placeholder:"\u8BF7\u8F93\u5165\u66F2\u76EE\u540D\u79F0",maxlength:50,showCount:!0},null)]}),t(B,{label:"\u97F3\u4E50\u4EBA",path:"composer",rule:[{required:!1,message:"\u8BF7\u8F93\u5165\u97F3\u4E50\u4EBA",trigger:["input","blur"]}]},{default:()=>[t(ie,{value:e.composer,"onUpdate:value":s=>e.composer=s,placeholder:"\u8BF7\u8F93\u5165\u97F3\u4E50\u4EBA\u540D\u79F0",showCount:!0,maxlength:14},null)]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u66F2\u76EE\u5C01\u9762",path:"musicCover",rule:[{required:!1,message:"\u8BF7\u4E0A\u4F20\u66F2\u76EE\u5C01\u9762",trigger:["input","blur"]}]},{default:()=>[t(te,{desc:"\u5C01\u9762\u56FE",disabled:a.previewMode,accept:".jpg,.jpeg,.png",tips:"\u8BF7\u4E0A\u4F20\u5927\u5C0F1M\u4EE5\u5185\u7684JPG\u3001PNG\u56FE\u7247",size:1,fileList:e.musicCover,"onUpdate:fileList":s=>e.musicCover=s,cropper:!0,bucketName:"cbs",options:{autoCrop:!0,enlarge:2,autoCropWidth:200,fixedBox:!0,autoCropHeight:200,previewsCircle:!1,title:"\u66F2\u76EE\u5C01\u9762"}},null)]}),t(B,{label:"\u66F2\u76EE\u5206\u7C7B",path:"musicCategoryId",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u66F2\u76EE\u5206\u7C7B",trigger:["change"]}]},{default:()=>[t(Ue,{valueField:"id",labelField:"name","children-field":"musicSheetCategoriesList",placeholder:"\u8BF7\u9009\u62E9\u5206\u7C7B",value:e.musicCategoryId,"onUpdate:value":s=>e.musicCategoryId=s,options:a.musicSheetCategories,clearable:!0},null)]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u4F5C\u8005\u5C5E\u6027",path:"sourceType",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u4F5C\u8005\u5C5E\u6027",trigger:"change"}]},{default:()=>[t(M,{value:e.sourceType,"onUpdate:value":s=>e.sourceType=s,options:re(xe),placeholder:"\u8BF7\u9009\u62E9\u4F5C\u8005\u5C5E\u6027",onUpdateValue:()=>{e.musicSheetExtend={},a.ownerName=null}},null)]}),e.sourceType==="PERSON"&&t(B,{label:"\u6240\u5C5E\u4EBA",path:"musicSheetExtend.userId",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u66F2\u76EE\u6240\u5C5E\u4EBA",trigger:["input","change"]}]},{default:()=>[t(O,{disabled:a.previewMode||!e.sourceType,type:"primary",size:"small",text:!0,onClick:()=>{a.showMusicSheetOwnerDialog=!0}},{default:()=>[a.ownerName?a.ownerName:"\u8BF7\u9009\u62E9\u6240\u5C5E\u4EBA"]})]}),e.sourceType==="ORG"&&t(B,{label:"\u6240\u5C5E\u4EBA",path:"musicSheetExtend.organizationRoleId",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u66F2\u76EE\u6240\u5C5E\u673A\u6784",trigger:["input","change"]}]},{default:()=>[t(O,{disabled:a.previewMode||!e.sourceType,type:"primary",size:"small",text:!0,onClick:()=>{a.showMusicSheetOwnerDialog=!0}},{default:()=>[a.ownerName?a.ownerName:"\u8BF7\u9009\u62E9\u6240\u5C5E\u673A\u6784"]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u5BA1\u6838\u7248\u672C",path:"appAuditFlag",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u5BA1\u6838\u7248\u672C",trigger:"change",type:"number"}]},{default:()=>[t(M,{options:[{label:"\u662F",value:1},{label:"\u5426",value:0}],value:e.appAuditFlag,"onUpdate:value":s=>e.appAuditFlag=s},null)]})]}),t(he,{showIcon:!1,style:{marginBottom:"12px"}},{default:()=>[m("\u66F2\u76EE\u8BBE\u7F6E")]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u64AD\u653E\u6A21\u5F0F",path:"playMode",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u64AD\u653E\u6A21\u5F0F"}]},{default:()=>[t(H,{value:e.playMode,"onUpdate:value":s=>e.playMode=s,onUpdateValue:s=>{s==="MP3"?e.playMode="MP3":e.playMode="MIDI"}},{default:()=>[t(Y,{value:"MP3"},{default:()=>[m("MP3")]}),e.playMode=="MIDI"&&u.type==="preview"&&t(Y,{value:"MIDI"},{default:()=>[m("MID")]})]})]}),e.playMode==="MP3"&&t(B,{label:"\u4F34\u594F\u7C7B\u578B",path:"audioType",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u4F34\u594F\u7C7B\u578B"}]},{default:()=>[t(H,{value:e.audioType,"onUpdate:value":s=>e.audioType=s},{default:()=>[t(Y,{value:"HOMEMODE"},{default:()=>[m("\u81EA\u5236\u4F34\u594F")]}),t(Y,{value:"COMMON"},{default:()=>[m("\u666E\u901A\u4F34\u594F")]})]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u4E0A\u4F20XML",path:"xmlFileUrl",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u4E0A\u4F20XML",trigger:["change","input"]}]},{default:()=>[t(te,{desc:"XML\u6587\u4EF6",disabled:a.previewMode,size:30,key:"xmlFileUrl",fileList:e.xmlFileUrl,"onUpdate:fileList":s=>e.xmlFileUrl=s,tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.xml/.mxml\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".xml,.mxml,.evxml",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20XML\u6587\u4EF6",onReadFileInputEventAsArrayBuffer:j,onRemove:()=>{}},null)]}),t(B,{label:"\u8BC4\u5206\u6807\u51C6",path:"evaluationStandard",rule:[{required:!0}]},{default:()=>[t(H,{value:e.evaluationStandard,"onUpdate:value":s=>e.evaluationStandard=s},{default:()=>[t(Y,{value:"FREQUENCY"},{default:()=>[m("\u6807\u51C6\u8BC4\u6D4B")]}),t(Y,{value:"AMPLITUDE"},{default:()=>[m("\u6253\u51FB\u4E50(\u632F\u5E45)")]}),t(Y,{value:"DECIBELS"},{default:()=>[m("\u8282\u594F(\u5206\u8D1D)")]})]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u662F\u5426\u5168\u58F0\u90E8",path:"isAllSubject",rule:[{required:!0,message:"\u662F\u5426\u5168\u58F0\u90E8"}]},{default:()=>[t(H,{value:e.isAllSubject,"onUpdate:value":s=>e.isAllSubject=s},{default:()=>[t(Y,{value:!1},{default:()=>[m("\u5426")]}),t(Y,{value:!0},{default:()=>[m("\u662F")]})]})]}),t(B,{label:"\u901F\u5EA6",path:"playSpeed",rule:[{required:!1,message:"\u8BF7\u8F93\u5165\u901F\u5EA6"}]},{default:()=>[t(de,{placeholder:"\u8BF7\u8F93\u5165\u901F\u5EA6",value:e.playSpeed,"onUpdate:value":s=>e.playSpeed=s,min:0,style:"width:100%"},null)]})]}),!e.isAllSubject&&t(R,{cols:2},{default:()=>[t(B,{label:"\u53EF\u7528\u4E50\u5668",path:"musicalInstrumentIdList",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u53EF\u7528\u4E50\u5668",trigger:"change",type:"array"}]},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u53EF\u7528\u4E50\u5668",options:a.instrumentList,value:e.musicalInstrumentIdList,"onUpdate:value":s=>e.musicalInstrumentIdList=s,clearable:!0,multiple:!0,filterable:!0,maxTagCount:10,onUpdateValue:s=>A(this,null,function*(){yield $(s)})},null)]}),t(B,{label:"\u53EF\u7528\u58F0\u90E8",path:"subjectIds",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u53EF\u7528\u58F0\u90E8",trigger:"change",type:"array"}]},{default:()=>[t(M,{value:e.subjectIds,"onUpdate:value":s=>e.subjectIds=s,options:a.subjectList,multiple:!0,filterable:!0,clearable:!0,placeholder:"\u8BF7\u9009\u62E9\u53EF\u7528\u58F0\u90E8",maxTagCount:10,onUpdateValue:s=>A(this,null,function*(){})},null)]})]}),t(R,{cols:1},{default:()=>[t(B,{label:"\u5207\u6362\u58F0\u8F68",path:"multiTracksSelection",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u5207\u6362\u58F0\u8F68",trigger:"change",type:"array"}]},{default:()=>[t(R,{style:"padding-top: 4px;"},{default:()=>[t(N,{span:24},{default:()=>[t(H,{value:a.multiTracks,"onUpdate:value":s=>a.multiTracks=s,onUpdateValue:s=>{ut(s)}},{default:()=>[t(Y,{value:"all"},{default:()=>[m("\u5168\u9009")]}),t(Y,{value:"allUncheck"},{default:()=>[m("\u91CD\u7F6E")]}),t(Y,{value:"invert"},{default:()=>[m("\u53CD\u9009")]})]})]}),a.partListNames&&a.partListNames.length>0&&t(N,{span:24,style:"margin-top:5px"},{default:()=>[t(B,{label:"",path:"multiTracksSelection",rule:[{required:!1}]},{default:()=>[t(Et,{value:e.multiTracksSelection,"onUpdate:value":s=>e.multiTracksSelection=s,onUpdateValue:s=>{a.partListNames.length!=s.length?a.multiTracks=null:a.multiTracks="all"}},{default:()=>[t(R,{yGap:2,cols:4},qe(p=a.partListNames.map(s=>t(N,null,{default:()=>[t(pe,{value:s.value,label:s.label},null)]})))?p:{default:()=>[p]})]})]})]})]})]})]}),e.multiTracksSelection.length>1&&t(R,{cols:2},{default:()=>[t(B,{label:"\u603B\u8C31\u6E32\u67D3",path:"isScoreRender",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u603B\u8C31\u6E32\u67D3"}]},{default:()=>[t(H,{value:e.isScoreRender,"onUpdate:value":s=>e.isScoreRender=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u652F\u6301")]}),t(Y,{value:!1},{default:()=>[m("\u4E0D\u652F\u6301")]})]})]}),e.isScoreRender&&t(B,{label:"\u9ED8\u8BA4\u663E\u793A",path:"defaultScoreRender",rule:[{required:!1}]},{default:()=>[t(H,{value:e.defaultScoreRender,"onUpdate:value":s=>e.defaultScoreRender=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u603B\u8C31")]}),t(Y,{value:!1},{default:()=>[m("\u5206\u8F68")]})]})]})]}),t(he,{showIcon:!1,style:{marginBottom:"12px"}},{default:()=>[m("\u6F14\u5531\u6587\u4EF6")]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u662F\u5426\u64AD\u653E\u8282\u62CD\u5668",path:"isPlaySingBeat",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u662F\u5426\u64AD\u653E\u8282\u62CD\u5668"}]},{default:()=>[t(H,{value:e.isPlaySingBeat,"onUpdate:value":s=>e.isPlaySingBeat=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u662F")]}),t(Y,{value:!1},{default:()=>[m("\u5426")]})]})]}),e.isPlaySingBeat&&t(B,{label:"\u64AD\u653E\u65B9\u5F0F",path:"isUseSingSystemBeat",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u64AD\u653E\u65B9\u5F0F"}]},{default:()=>[t(H,{value:e.isUseSingSystemBeat,"onUpdate:value":s=>e.isUseSingSystemBeat=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u7CFB\u7EDF\u8282\u62CD\u5668")]}),t(Y,{value:!1},{default:()=>[m("MP3\u8282\u62CD\u5668")]})]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u91CD\u590D\u8282\u62CD\u65F6\u957F",path:"repeatedBeatsToSing",rule:[{required:!1,message:"\u8BF7\u9009\u62E9\u662F\u5426\u91CD\u590D\u8282\u62CD\u65F6\u957F"}]},{default:()=>[t(H,{value:e.repeatedBeatsToSing,"onUpdate:value":s=>e.repeatedBeatsToSing=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u662F")]}),t(Y,{value:!1},{default:()=>[m("\u5426")]})]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u4E0A\u4F20\u4F34\u5531",path:"bSongFile",rule:[{required:!1}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u4F34\u5531",disabled:a.previewMode,size:30,fileList:a.bSongFile,"onUpdate:fileList":[s=>a.bSongFile=s,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u4F34\u5531\u6587\u4EF6"},null)]})]}),e.fSongList.length>0&&e.fSongList.map(s=>t(R,{class:ue.audioSection},{default:()=>[t(B,{span:12,label:s.track+"\u8303\u5531",path:s.audioFileUrl,rule:[{required:!1}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u8303\u5531",disabled:a.previewMode,size:100,fileList:s.audioFileUrl,"onUpdate:fileList":[n=>s.audioFileUrl=n,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u8303\u5531\u6587\u4EF6"},null)]})]})),e.multiTracksSelection.length>1&&e.isScoreRender&&t(R,{cols:2,class:ue.audioSection},{default:()=>[t(B,{label:"\u603B\u8C31\u8303\u5531",path:"scoreRenderFile",rule:[{required:!1}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u603B\u8C31\u8303\u5531",disabled:a.previewMode,size:30,fileList:e.scoreAudioFileUrl,"onUpdate:fileList":[s=>e.scoreAudioFileUrl=s,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u603B\u8C31\u8303\u5531"},null)]})]}),e.fSongList.length>0&&e.fSongList.map(s=>t(R,{cols:2},{default:()=>[t(B,{label:s.track+"\u5531\u540D(\u7537)",path:s.solmizationFileUrl,rule:[{required:!1}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u8303\u5531",disabled:a.previewMode,size:100,fileList:s.solmizationFileUrl,"onUpdate:fileList":[n=>s.solmizationFileUrl=n,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u5531\u540D\u6587\u4EF6"},null)]}),t(B,{label:s.track+"\u5531\u540D(\u5973)",path:s.femaleSolmizationFileUrl,rule:[{required:!1}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u8303\u5531",disabled:a.previewMode,size:100,fileList:s.femaleSolmizationFileUrl,"onUpdate:fileList":[n=>s.femaleSolmizationFileUrl=n,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u5531\u540D\u6587\u4EF6"},null)]})]})),t(he,{showIcon:!1,style:{marginBottom:"12px"}},{default:()=>[m("\u6F14\u594F\u6587\u4EF6")]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u662F\u5426\u64AD\u653E\u8282\u62CD\u5668",path:"isPlayBeat",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u662F\u5426\u64AD\u653E\u8282\u62CD\u5668"}]},{default:()=>[t(H,{value:e.isPlayBeat,"onUpdate:value":s=>e.isPlayBeat=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u662F")]}),t(Y,{value:!1},{default:()=>[m("\u5426")]})]})]}),e.isPlayBeat&&t(B,{label:"\u64AD\u653E\u65B9\u5F0F",path:"isUseSystemBeat",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u64AD\u653E\u65B9\u5F0F"}]},{default:()=>[t(H,{value:e.isUseSystemBeat,"onUpdate:value":s=>e.isUseSystemBeat=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u7CFB\u7EDF\u8282\u62CD\u5668")]}),t(Y,{value:!1},{default:()=>[m("MP3\u8282\u62CD\u5668")]})]})]})]}),t(R,{cols:2},{default:()=>[t(B,{label:"\u91CD\u590D\u8282\u62CD\u65F6\u957F",path:"repeatedBeats",rule:[{required:!1,message:"\u8BF7\u9009\u62E9\u662F\u5426\u91CD\u590D\u8282\u62CD\u65F6\u957F"}]},{default:()=>[t(H,{value:e.repeatedBeats,"onUpdate:value":s=>e.repeatedBeats=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u662F")]}),t(Y,{value:!1},{default:()=>[m("\u5426")]})]})]}),t(B,{label:"\u662F\u5426\u663E\u793A\u6307\u6CD5",path:"isShowFingering",rule:[{required:!0,message:"\u8BF7\u9009\u62E9\u662F\u5426\u663E\u793A\u6307\u6CD5"}]},{default:()=>[t(H,{value:e.isShowFingering,"onUpdate:value":s=>e.isShowFingering=s},{default:()=>[t(Y,{value:!0},{default:()=>[m("\u662F")]}),t(Y,{value:!1},{default:()=>[m("\u5426")]})]})]})]}),t(R,{cols:2},{default:()=>[e.playMode==="MP3"&&t(B,{label:"\u4E0A\u4F20\u4F34\u594F",path:"musicSheetAccompanimentList",rule:[{required:!1,message:"\u8BF7\u9009\u62E9\u4E0A\u4F20.mp3"}]},{default:()=>[t(te,{disabled:a.previewMode,size:30,fileList:a.musicSheetAccompanimentUrl,"onUpdate:fileList":[s=>a.musicSheetAccompanimentUrl=s,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u4F34\u594F\u6587\u4EF6",max:1,desc:"\u4E0A\u4F20\u4F34\u594F\u6587\u4EF6"},null)]}),e.isAllSubject&&e.musicSheetType=="SINGLE"&&t(B,{label:"\u4E0A\u4F20\u539F\u97F3",path:"musicSheetSoundList_all_subject",rule:[{required:!1,message:"\u8BF7\u9009\u62E9\u4E0A\u4F20\u539F\u97F3",trigger:["change","input"]}]},{default:()=>[t(te,{desc:"\u4E0A\u4F20\u539F\u97F3",disabled:a.previewMode,size:30,max:1,fileList:e.musicSheetSoundList_all_subject,"onUpdate:fileList":[s=>e.musicSheetSoundList_all_subject=s,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach",text:"\u70B9\u51FB\u4E0A\u4F20\u539F\u97F3",onRemove:()=>{}},null)]})]}),!!y.list.length&&t(me,null,[t(he,{showIcon:!1,type:"info"},{default:()=>[m("\u8BC6\u522B\u5230\u51711\u5904\u6E10\u53D8\u901F\u5EA6\uFF0C\u8BF7\u8F93\u5165Dorico\u5BF9\u5E94\u5C0F\u8282\u65F6\u95F4\u4FE1\u606F")]}),t(v,{label:"rit.",required:!0,style:{marginTop:"10px"}},{default:()=>[t(W,{vertical:!0},qe(r=y.list.map((s,n)=>t(Te,null,{default:()=>[t(v,{path:`graduals.${s[0].measureIndex}`,rule:[{required:!0,message:"\u8BF7\u8F93\u5165\u5408\u594F\u66F2\u76EE\u65F6\u95F4"},{pattern:/^((\d{2}):?){2,3}$/,message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u66F2\u76EE\u65F6\u95F4",trigger:"blur"}]},{default:()=>[t(Te,null,{default:()=>[t(Ye,null,{default:()=>[s[0].measureIndex,m("\u5C0F\u8282\u5F00\u59CB")]}),t(ie,{placeholder:"00:00:00",value:e.graduals[s[0].measureIndex],"onUpdate:value":f=>e.graduals[s[0].measureIndex]=f},null)]})]}),t("div",{style:{lineHeight:"30px",padding:"0 4px"}},[m("~")]),t(v,{path:`graduals.${s[1].measureIndex}`,rule:[{required:!0,message:"\u8BF7\u8F93\u5165\u5408\u594F\u66F2\u76EE\u65F6\u95F4"},{pattern:/^((\d{2}):?){2,3}$/,message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u66F2\u76EE\u65F6\u95F4",trigger:"blur"}]},{default:()=>[t(Te,null,{default:()=>[t(ie,{placeholder:"00:00:00",value:e.graduals[s[1].measureIndex],"onUpdate:value":f=>e.graduals[s[1].measureIndex]=f},null),t(Ye,null,{default:()=>[s[1].measureIndex,m("\u5C0F\u8282\u7ED3\u675F")]})]})]})]})))?r:{default:()=>[r]})]})]),e.musicSheetType=="SINGLE"&&e.playMode==="MP3"&&!e.isAllSubject&&e.musicSheetSoundList_YZ.map((s,n)=>t(me,null,[e.musicalInstrumentIdList.includes(s.musicalInstrumentId)&&t(R,{class:ue.audioSection},{default:()=>[t(B,{span:12,label:s.musicalInstrumentName,path:`musicSheetSoundList_YZ[${n}].audioFileUrl`,rule:[{required:!1,message:"\u8BF7\u4E0A\u4F20\u4E50\u5668\u6F14\u594F\u6587\u4EF6"}]},{default:()=>[t(te,{desc:"\u4E50\u5668\u6F14\u594F\u6587\u4EF6",disabled:a.previewMode,size:100,fileList:s.audioFileUrl,"onUpdate:fileList":[f=>s.audioFileUrl=f,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",text:"\u70B9\u51FB\u4E0A\u4F20MP3\u6587\u4EF6",bucketName:"cloud-coach"},null)]})]})])),e.musicSheetType=="CONCERT"&&e.playMode==="MP3"&&e.musicSheetSoundList_YY.length>0&&t(me,null,[e.musicSheetSoundList_YY.map((s,n)=>{var f,U;return t(me,null,[(!o(s.track)||((U=(f=s.track)==null?void 0:f.toLocaleUpperCase)==null?void 0:U.call(f))!="COMMON"&&e.multiTracksSelection.includes(s.track))&&t(R,{class:ue.audioSection},{default:()=>[t(B,{span:12,label:"\u539F\u97F3",path:`musicSheetSoundList_YY[${n}].audioFileUrl`,rule:[{required:!1,message:`\u8BF7\u4E0A\u4F20${s.track?s.track+"\u7684":"\u7B2C"+(n+1)+"\u4E2A"}\u539F\u97F3`}]},{default:()=>[t(te,{desc:"\u539F\u97F3\u6587\u4EF6",disabled:a.previewMode,size:100,fileList:s.audioFileUrl,"onUpdate:fileList":[_=>s.audioFileUrl=_,()=>{a.isBeatTime=!0}],tips:"\u4EC5\u652F\u6301\u4E0A\u4F20.mp3\u683C\u5F0F\u6587\u4EF6",listType:"image",accept:".mp3",bucketName:"cloud-coach"},null)]}),a.partListNames.length>0&&t(B,{span:12,label:"\u6240\u5C5E\u8F68\u9053",path:`musicSheetSoundList_YY[${n}].track`,rule:[{required:!1,message:"\u8BF7\u9009\u62E9\u6240\u5C5E\u8F68\u9053"}]},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u6240\u5C5E\u8F68\u9053",value:s.track,options:z(s.track),onUpdateValue:_=>{const q=s.track;if(q){e.musicSheetSoundList_YY.forEach(C=>{C.track==_&&(C.track=q)});const E=e.multiTracksSelection.indexOf(s.track);e.multiTracksSelection.splice(E,1)}else e.musicSheetSoundList_YY=e.musicSheetSoundList_YY.filter(E=>E.track!=_);_!=null&&!e.multiTracksSelection.includes(_)&&e.multiTracksSelection.push(_),s.track=_,a.partListNames.length==e.multiTracksSelection.length&&(a.multiTracks="all")}},null)]}),t(N,{class:ue.btnRemove},{default:()=>[t(O,{type:"primary",text:!0,onClick:()=>ae(n)},{default:()=>[m("\u5220\u9664")]})]})]})])})])]})]}),u.type!=="preview"&&t(W,{justify:"end",style:"padding-top:12px"},{default:()=>[t(O,{type:"default",onClick:()=>l("close")},{default:()=>[m("\u53D6\u6D88")]}),t(O,{type:"primary",onClick:()=>c(),loading:g.value,disabled:g.value},{default:()=>[m("\u786E\u8BA4")]})]}),t(oe,{show:a.showMusicSheetOwnerDialog,"onUpdate:show":s=>a.showMusicSheetOwnerDialog=s,preset:"dialog",showIcon:!1,maskClosable:!1,title:"\u6240\u5C5E\u4EBA",style:{width:"800px"}},{default:()=>[t(Qt,{musicSheetExtend:e.musicSheetExtend,sourceType:e.sourceType,appData:a.appData,onClose:()=>{a.showMusicSheetOwnerDialog=!1},onChoseMusicSheetOwnerData:s=>{e.musicSheetExtend=G({},s),Ne()}},null)]}),t(oe,{class:ue.productModal,title:"\u81EA\u52A8\u751F\u6210\u66F2\u8C31\u56FE\u7247",show:a.productOpen,"onUpdate:show":s=>a.productOpen=s,preset:"dialog",closeOnEsc:!1,maskClosable:!1,onClose:()=>{a.isAutoSave=!1},showIcon:!1},{default:()=>[t(lt,{xmlFileUrl:e.xmlFileUrl||"",onClose:()=>a.productOpen=!1,onConfirm:s=>A(this,null,function*(){try{e.musicImg=s.musicImg,e.musicFirstImg=s.musicFirstImg,e.musicJianImg=s.musicJianImg,yield c()}catch(n){console.log(n,"e")}})},null)]}),k.beatTimeOpen&&t(st,{id:k.musicId,onClose:s=>{k.beatTimeOpen=!1,!s&&(a.showUseProject=!0)}},null),t(oe,{blockScroll:!0,show:a.showUseProject,"onUpdate:show":s=>a.showUseProject=s,preset:"dialog",showIcon:!1,title:"\u9002\u7528\u9879\u76EE",style:{width:"1200px"}},{default:()=>[t(it,{id:a.showUseProjectId,useProject:a.useProjectData,onClose:L},null)]})])}}}),oa="_productModal_35hv9_1",na="_productIframe_35hv9_9",ca={productModal:oa,productIframe:na};function Ge(u){return typeof u=="function"||Object.prototype.toString.call(u)==="[object Object]"&&!Ze(u)}const da=se({name:"music-list",props:["searchId","musicCategoryId"],setup(u,{emit:I}){const d=we(),l=ne(),e=ee({loading:!1,pagination:{page:1,rows:10,pageTotal:0},searchForm:{keyword:null,isScoreRender:null,subjectId:null,sourceType:null,composer:null,userId:null,applicationId:null,useAppId:[],status:null,appAuditFlag:null,categoriesId:null,musicCategoryId:null,musicalInstrumentId:null,dataCorrect:null,generateFirst:null,generateMetronomeAudio:null},dataList:[],subjectList:[],instrumentList:[],tagList:[],visiableMusic:!1,musicOperation:"add",musicData:{},musicSheetCategories:[],musicPreview:!1,musicPreviewScoreType:"staff",musicScore:null,showUseProject:!1,useProjectData:[],showUseProjectId:null,detailReadonly:!1,userIdDisable:!0,userIdData:[],productOpen:!1,beatTimeOpen:!1,productItem:{}}),a=()=>[{type:"selection"},{title:"\u66F2\u76EE\u540D\u79F0",minWidth:"200px",key:"id",render(i){return t(Se,{labelPlacement:"left",column:1},{default:()=>[t(le,{label:"\u540D\u79F0"},{default:()=>[t(ye,{content:i.name},null)]}),t(le,{label:"\u7F16\u53F7"},{default:()=>[t("div",{onDblclick:()=>{Yt(l,i.id)}},[t(ye,{content:i.id},null)])]})]})}},{title:"\u5C01\u9762\u56FE",key:"titleImg",render(i){return t(Mt,{width:60,height:60,src:i.musicCover},null)}},{title:"\u66F2\u76EE\u4FE1\u606F",minWidth:"200px",key:"composer",render(i){return t(Se,{labelPlacement:"left",column:1},{default:()=>[t(le,{label:"\u97F3\u4E50\u4EBA"},{default:()=>[i.composer]}),t(le,{label:"\u603B\u8C31\u6E32\u67D3"},{default:()=>[i.isScoreRender?"\u652F\u6301":"\u4E0D\u652F\u6301"]}),t(le,{label:"\u5206\u7C7B"},{default:()=>[t(ye,{content:i.musicCategoryName},null)]}),t(le,{label:"\u53EF\u7528\u58F0\u90E8"},{default:()=>[t(ye,{content:i.subjectNames},null)]})]})}},{title:"\u4F5C\u8005\u5C5E\u6027",key:"sourceType",minWidth:"120px",render(i){let T,z;return t(Se,{labelPlacement:"left",column:1},{default:()=>[t(le,{label:"\u5C5E\u6027"},Ge(T=zt(i.sourceType,new Map(Object.entries(xe))))?T:{default:()=>[T]}),t(le,{label:"\u6240\u5C5E\u4EBA"},Ge(z=qt(i.musicSheetExtend,i.sourceType))?z:{default:()=>[z]})]})}},{title:"\u9002\u7528\u9879\u76EE",key:"projectName",render(i){return t(W,null,{default:()=>[J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.showUseProject=!0,e.showUseProjectId=i.id}},{default:()=>[t(ye,{content:i.musicSheetExtend&&i.musicSheetExtend.useApplicationNames?i.musicSheetExtend.useApplicationNames:""},null),t(At,{size:15,style:"padding-left: 9px"},{default:()=>[t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[t("path",{d:"M2 26h28v2H2z",fill:"currentColor"},null),t("path",{d:"M25.4 9c.8-.8.8-2 0-2.8l-3.6-3.6c-.8-.8-2-.8-2.8 0l-15 15V24h6.4l15-15zm-5-5L24 7.6l-3 3L17.4 7l3-3zM6 22v-3.6l10-10l3.6 3.6l-10 10H6z",fill:"currentColor"},null)])]})]}),[[X("auth"),"musicSheetApplicationExtend/save1752901206883221506"]])]})}},{title:"\u66F4\u65B0\u4FE1\u606F",minWidth:"250px",key:"updateBy",render(i){return t(Se,{labelPlacement:"left",column:1},{default:()=>[t(le,{label:"\u66F4\u65B0\u4EBA"},{default:()=>[i.updateByName]}),t(le,{label:"\u66F4\u65B0\u65F6\u95F4"},{default:()=>[i.updateTime]})]})}},{title:"\u5BA1\u6838\u7248\u672C",minWidth:"100px",key:"appAuditFlag",render(i){return t("div",null,[i.appAuditFlag?"\u662F":"\u5426"])}},{title:"\u72B6\u6001",minWidth:"50px",key:"status",render(i){return t(Pt,{type:i.status?"primary":"default"},{default:()=>[i.status?"\u542F\u7528":"\u505C\u7528"]})}},{title:"\u64CD\u4F5C",key:"operation",fixed:"right",width:"300px",render(i){return t(W,null,{default:()=>[t(Bt,{trigger:"hover",options:[{label:"\u4E94\u7EBF\u8C31",key:"staff"},{label:"\u9996\u8C03",key:"firstTone"},{label:"\u56FA\u5B9A\u8C03",key:"fixedTone"}],onSelect:T=>{e.musicPreview=!0,e.musicScore=i,e.musicPreviewScoreType=T}},{default:()=>[t(O,{type:"primary",size:"small",text:!0,onClick:T=>T.stopPropagation()},{default:()=>[m("\u9884\u89C8")]})]}),J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.visiableMusic=!0,e.musicOperation="preview",e.musicData=i,e.detailReadonly=!0}},{default:()=>[m("\u67E5\u770B")]}),[[X("auth"),"musicSheet/detail1751241103201271810"]]),J(t(O,{type:"primary",size:"small",text:!0,disabled:i.playMode==="MIDI",onClick:()=>{e.visiableMusic=!0,e.musicOperation="edit",e.musicData=i,e.detailReadonly=!0}},{default:()=>[m("\u4FEE\u6539")]}),[[X("auth"),"musicSheet/save1751241178962984962"]]),J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>k(i)},{default:()=>[i.status?"\u505C\u7528":"\u542F\u7528"]}),[[X("auth"),"musicSheet/statusList1751241653309407234"]]),J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.productOpen=!0,e.productItem=i}},{default:()=>[m("\u751F\u6210\u56FE\u7247")]}),[[X("auth"),"musicSheet/img1751240591299051522"]]),J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.productItem=i,e.beatTimeOpen=!0}},{default:()=>[m("\u751F\u6210\u8282\u62CD\u5668\u97F3\u9891")]}),[[X("auth"),"musicSheet/addMix1819259767120539649"]]),J(t(O,{type:"primary",size:"small",text:!0,disabled:!!i.status,onClick:()=>P(i)},{default:()=>[m("\u5220\u9664")]}),[[X("auth"),"musicSheet/remove1753457445635645442"]])]})}}],y=Q([]),k=i=>{const T=i.status?"\u505C\u7528":"\u542F\u7528";d.warning({title:"\u63D0\u793A",content:`\u662F\u5426${T}\uFF1F`,positiveText:"\u786E\u5B9A",negativeText:"\u53D6\u6D88",onPositiveClick:()=>A(this,null,function*(){try{yield Be({ids:new Array(i.id),status:!i.status}),S(),l.success(`${T}\u6210\u529F`)}catch(z){}})})},g=i=>{const T=y.value.length;T==0&&l.warning("\u672A\u9009\u62E9\u6570\u636E");const z=i?"\u542F\u7528":"\u505C\u7528";d.warning({title:"\u63D0\u793A",content:`\u662F\u5426${z}`+T+"\u6761\u6570\u636E\uFF1F",positiveText:"\u786E\u5B9A",negativeText:"\u53D6\u6D88",onPositiveClick:()=>A(this,null,function*(){try{yield Be({ids:y.value,status:i}),S(),l.success(`${z}\u6210\u529F`)}catch($){}})})},x=i=>A(this,null,function*(){if(!!e.searchForm.applicationId&&(e.userIdData=[],e.searchForm.userId=null,i&&i!=="PLATFORM")){const{data:T}=yield Ve({page:1,rows:9999,sourceType:i,applicationId:e.searchForm.applicationId});(T.rows||[]).forEach($=>{e.userIdData.push(Z(G({},$),{label:i==="PERSON"?$.userName:$.organizationRole,value:i==="PERSON"?$.userId:$.organizationRoleId}))})}}),P=i=>{d.warning({title:"\u63D0\u793A",content:`\u5220\u9664"${i.name}"\uFF0C\u662F\u5426\u7EE7\u7EED\uFF1F`,positiveText:"\u786E\u5B9A",negativeText:"\u53D6\u6D88",onPositiveClick:()=>A(this,null,function*(){try{yield vt({id:i.id}),S(),l.success("\u5220\u9664\u6210\u529F")}catch(T){}})})},S=()=>A(this,null,function*(){try{e.loading=!0;const i=e.searchForm.sourceType,T=e.searchForm.userId;let z=Z(G({},e.searchForm),{useAppId:e.searchForm.useAppId?e.searchForm.useAppId.join(","):e.searchForm.useAppId});i&&i=="ORG"&&(z.organizationRoleId=T,z.userId=null);const $=G(G({},e.pagination),z);$.generateFirst&&($.musicCategoryId="100061");const{data:ae}=yield bt($);e.pagination.pageTotal=Number(ae.total),e.dataList=ae.rows||[]}catch(i){}e.loading=!1}),c=()=>A(this,null,function*(){try{const{data:i}=yield Fe({});e.musicSheetCategories=i||[],L(e.musicSheetCategories)}catch(i){}}),L=i=>{for(let T=0;T<i.length;T++)i[T].musicSheetCategoriesList.length<1?i[T].musicSheetCategoriesList=null:L(i[T].musicSheetCategoriesList)},D=()=>A(this,null,function*(){try{const{data:i}=yield et({page:1,rows:999}),T=i.rows||[];T.forEach(z=>{z.label=z.name,z.value=z.id+""}),e.subjectList=T}catch(i){}}),F=()=>A(this,null,function*(){try{const{data:i}=yield Le({page:1,rows:999}),T=i.rows||[];T.forEach(z=>{z.label=z.name,z.value=z.id+""}),e.instrumentList=T}catch(i){}}),j=()=>A(this,null,function*(){try{const i=Object.keys(Qe),{data:T}=yield tt({page:1,rows:999,hiddenFlag:!0}),z=T.rows||[];e.useProjectData=[],z.filter(ae=>i.includes(ae.appKey)).forEach(ae=>{e.useProjectData.push(Z(G({},ae),{label:ae.appName,value:ae.id}))})}catch(i){}}),o=Q(),b=()=>{e.pagination.page=1,S()};We(()=>u.searchId,i=>{console.log(i,"searchId")});const h=()=>{var i;y.value=[],(i=o.value)==null||i.submit()},K=()=>{var i;(i=o.value)==null||i.reset()};return ce(()=>A(this,null,function*(){e.loading=!0,u.searchId&&(e.searchForm.categoriesId=u.searchId||null),u.musicCategoryId&&(e.searchForm.musicCategoryId=u.musicCategoryId||null),D(),F(),j(),c(),S()})),()=>t("div",{class:"system-menu-container"},[t(Ke,{ref:o,model:e.searchForm,onSubmit:b,saveKey:"music-list",onSetModel:i=>e.searchForm=i},{default:()=>[t(v,{label:"\u5173\u952E\u8BCD",path:"keyword"},{default:()=>[t(ie,{placeholder:"\u66F2\u76EE\u7F16\u53F7/\u540D\u79F0",value:e.searchForm.keyword,"onUpdate:value":i=>e.searchForm.keyword=i,clearable:!0},null)]}),t(v,{label:"\u603B\u8C31\u6E32\u67D3",path:"isScoreRender"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u603B\u8C31\u6E32\u67D3",value:e.searchForm.isScoreRender,"onUpdate:value":i=>e.searchForm.isScoreRender=i,options:[{label:"\u652F\u6301",value:!0},{label:"\u4E0D\u652F\u6301",value:!1}],clearable:!0},null)]}),t(v,{label:"\u66F2\u76EE\u5206\u7C7B",path:"musicCategoryId"},{default:()=>[t(Ue,{valueField:"id",labelField:"name","children-field":"musicSheetCategoriesList",placeholder:"\u8BF7\u9009\u62E9\u66F2\u76EE\u5206\u7C7B",value:e.searchForm.musicCategoryId,"onUpdate:value":i=>e.searchForm.musicCategoryId=i,options:e.musicSheetCategories,clearable:!0},null)]}),t(v,{label:"\u53EF\u7528\u58F0\u90E8",path:"musicSubject"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u53EF\u7528\u58F0\u90E8",value:e.searchForm.subjectId,"onUpdate:value":i=>e.searchForm.subjectId=i,options:e.subjectList,filterable:!0,clearable:!0},null)]}),t(v,{label:"\u53EF\u7528\u4E50\u5668",path:"musicalInstrumentId"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u53EF\u7528\u4E50\u5668",value:e.searchForm.musicalInstrumentId,"onUpdate:value":i=>e.searchForm.musicalInstrumentId=i,options:e.instrumentList,filterable:!0,clearable:!0},null)]}),t(v,{label:"\u97F3\u4E50\u4EBA",path:"composer"},{default:()=>[t(ie,{placeholder:"\u8BF7\u9009\u62E9\u97F3\u4E50\u4EBA",value:e.searchForm.composer,"onUpdate:value":i=>e.searchForm.composer=i,clearable:!0},null)]}),t(v,{label:"\u4F5C\u8005\u5C5E\u6027",path:"sourceType"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u4F5C\u8005\u5C5E\u6027",value:e.searchForm.sourceType,"onUpdate:value":i=>e.searchForm.sourceType=i,options:re(xe),onUpdateValue:i=>A(this,null,function*(){e.userIdData=[],e.searchForm.userId=null,i&&i!=="PLATFORM"?(yield x(i),e.userIdDisable=!e.searchForm.applicationId):e.userIdDisable=!0}),clearable:!0},null)]}),t(v,{label:"\u6240\u5C5E\u9879\u76EE",path:"applicationId"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u6240\u5C5E\u9879\u76EE",value:e.searchForm.applicationId,"onUpdate:value":i=>e.searchForm.applicationId=i,options:e.useProjectData,clearable:!0,onUpdateValue:i=>A(this,null,function*(){e.searchForm.applicationId=i,i?(yield x(e.searchForm.sourceType),e.userIdDisable=!(e.searchForm.sourceType&&e.searchForm.sourceType!=="PLATFORM")):(e.searchForm.userId=null,e.userIdDisable=!0,e.userIdData=[])})},null)]}),t(v,{label:"\u6240\u5C5E\u4EBA",path:"userId"},{label:()=>t("div",null,[m("\u6240\u5C5E\u4EBA")]),default:()=>t(M,{filterable:!0,placeholder:"\u8BF7\u9009\u62E9\u6240\u5C5E\u4EBA",disabled:e.userIdDisable||!e.searchForm.applicationId&&!e.searchForm.sourceType,value:e.searchForm.userId,"onUpdate:value":i=>e.searchForm.userId=i,options:e.userIdData,clearable:!0},null)}),t(v,{label:"\u9002\u7528\u9879\u76EE",path:"useAppId"},{default:()=>[t(M,{placeholder:"\u8BF7\u9009\u62E9\u9002\u7528\u9879\u76EE",value:e.searchForm.useAppId,"onUpdate:value":i=>e.searchForm.useAppId=i,options:e.useProjectData,multiple:!0,maxTagCount:1},null)]}),t(v,{label:"\u72B6\u6001",path:"status"},{default:()=>[t(M,{value:e.searchForm.status,"onUpdate:value":i=>e.searchForm.status=i,placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001",clearable:!0,options:[{label:"\u542F\u7528",value:!0},{label:"\u505C\u7528",value:!1}]},null)]}),t(v,{label:"\u5BA1\u6838\u7248\u672C",path:"appAuditFlag"},{default:()=>[t(M,{value:e.searchForm.appAuditFlag,"onUpdate:value":i=>e.searchForm.appAuditFlag=i,placeholder:"\u8BF7\u9009\u62E9\u5BA1\u6838\u7248\u672C",clearable:!0,options:[{label:"\u662F",value:1},{label:"\u5426",value:0}]},null)]}),t(v,{label:"\u6570\u636E\u4FEE\u590D",path:"dataCorrect"},{default:()=>[t(M,{value:e.searchForm.dataCorrect,"onUpdate:value":i=>e.searchForm.dataCorrect=i,placeholder:"\u8BF7\u9009\u62E9\u6570\u636E\u4FEE\u590D",clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]}),t(v,{label:"\u751F\u6210\u8282\u62CD\u5668\u97F3\u9891",path:"generateMetronomeAudio"},{default:()=>[t(M,{value:e.searchForm.generateMetronomeAudio,"onUpdate:value":i=>e.searchForm.generateMetronomeAudio=i,placeholder:"\u8BF7\u9009\u62E9\u662F\u5426\u751F\u6210\u8282\u62CD\u5668\u97F3\u9891",clearable:!0,options:[{label:"\u5DF2\u751F\u6210",value:!0},{label:"\u672A\u751F\u6210",value:!1}]},null)]}),t(v,{label:"\u5999\u6781\u5BA2\u8282\u62CD\u5668",path:"generateFirst"},{default:()=>[t(M,{value:e.searchForm.generateFirst,"onUpdate:value":i=>e.searchForm.generateFirst=i,placeholder:"\u8BF7\u9009\u62E9\u5999\u6781\u5BA2\u8282\u62CD\u5668",clearable:!0,options:[{label:"\u662F",value:!0},{label:"\u5426",value:!1}]},null)]}),t(v,null,{default:()=>[t(W,null,{default:()=>[t(O,{type:"primary",onClick:h},{default:()=>[m("\u641C\u7D22")]}),t(O,{type:"default",onClick:K},{default:()=>[m("\u91CD\u7F6E")]})]})]})]}),t("div",{class:["section-container"]},[t(W,{style:{paddingBottom:"12px"}},{default:()=>[J(t(O,{type:"primary",onClick:()=>{e.visiableMusic=!0,e.musicOperation="add",e.musicData={},e.detailReadonly=!0}},{default:()=>[m("\u65B0\u589E\u66F2\u76EE")]}),[[X("auth"),"musicSheet/save1751241178962984962"]]),J(t(O,{disabled:y.value.length==0,onClick:()=>{g(!1)}},{default:()=>[m("\u6279\u91CF\u505C\u7528")]}),[[X("auth"),"musicSheet/statusList1751241653309407234"]]),J(t(O,{disabled:y.value.length==0,onClick:()=>{g(!0)}},{default:()=>[m("\u6279\u91CF\u542F\u7528")]}),[[X("auth"),"musicSheet/statusList1751241653309407234"]])]}),t(ve,{loading:e.loading,columns:a(),data:e.dataList,rowKey:i=>i.id,checkedRowKeys:y.value,"onUpdate:checkedRowKeys":i=>y.value=i,scrollX:"1200"},null),t($e,{page:e.pagination.page,"onUpdate:page":i=>e.pagination.page=i,pageSize:e.pagination.rows,"onUpdate:pageSize":i=>e.pagination.rows=i,pageTotal:e.pagination.pageTotal,"onUpdate:pageTotal":i=>e.pagination.pageTotal=i,onList:S,sync:!0,saveKey:"music-list"},null)]),t(oe,{show:e.visiableMusic,"onUpdate:show":i=>e.visiableMusic=i,preset:"dialog",showIcon:!1,maskClosable:!1,title:()=>e.musicOperation==="add"?"\u6DFB\u52A0\u66F2\u76EE":e.musicOperation==="preview"?"\u66F2\u76EE\u8BE6\u60C5":"\u4FEE\u6539\u66F2\u76EE",style:{width:"980px"}},{default:()=>[t(ra,{type:e.musicOperation,data:e.musicData,subjectList:e.subjectList,onClose:()=>e.visiableMusic=!1,onGetList:S},null)]}),t(oe,{blockScroll:!0,show:e.musicPreview,"onUpdate:show":i=>e.musicPreview=i,preset:"dialog",showIcon:!1,title:"\u66F2\u76EE\u9884\u89C8",style:{width:"auto"}},{default:()=>[t(Ot,{item:e.musicScore,isMove:1,scoreType:e.musicPreviewScoreType},null)]}),t(oe,{blockScroll:!0,show:e.showUseProject,"onUpdate:show":i=>e.showUseProject=i,preset:"dialog",showIcon:!1,title:"\u9002\u7528\u9879\u76EE",style:{width:"1200px"}},{default:()=>[t(it,{id:e.showUseProjectId,useProject:e.useProjectData,onClose:()=>e.showUseProject=!1,onGetList:S},null)]}),t(oe,{class:ca.productModal,title:"\u81EA\u52A8\u751F\u6210\u66F2\u8C31\u56FE\u7247",show:e.productOpen,"onUpdate:show":i=>e.productOpen=i,preset:"dialog",closeOnEsc:!1,maskClosable:!1,showIcon:!1},{default:()=>[t(lt,{xmlFileUrl:e.productItem.xmlFileUrl,onClose:()=>e.productOpen=!1,onConfirm:i=>A(this,null,function*(){try{yield St(Z(G({},i),{id:e.productItem.id}))}catch(T){}})},null)]}),e.beatTimeOpen&&t(st,{id:e.productItem.id,onClose:()=>{e.beatTimeOpen=!1}},null)])}}),pa="_instrumentSave_1gfcu_1",ma="_updateFile_1gfcu_5",fa={instrumentSave:pa,updateFile:ma},ha=se({emits:["close","getList"],props:["activeRow","saveMode","list"],name:"save-categroy-dialog",setup(u,{emit:I}){const d=ne(),l=Q(),e=Q([{name:"\u9876\u7EA7\u5206\u7C7B",id:0},...at(u.list,"musicSheetCategoriesList")]),a=ee({loading:!1,dataList:[],btnLoading:!1,options:{enlarge:2,autoCropWidth:350,autoCropHeight:140},messageTip:"\u8BF7\u4E0A\u4F20\u5C3A\u5BF8\u4E3A700*280\u5927\u5C0F5M\u4EE5\u5185\u7684JPG\u3001PNG\u56FE\u7247"}),y=ee({id:"",name:"",coverImg:"",enable:!0,parentId:"0"}),k=()=>A(this,null,function*(){var g;(g=l.value)==null||g.validate(x=>A(this,null,function*(){if(!x){a.btnLoading=!0;try{if(u.saveMode==="add"){const{data:P}=yield Tt(G({},y));I("getList"),d.success("\u6DFB\u52A0\u6210\u529F")}else{const{data:P}=yield It(G({},y));I("getList"),d.success("\u4FEE\u6539\u6210\u529F")}}catch(P){}a.btnLoading=!1}}))});return ce(()=>{if(u.saveMode==="add")u.activeRow&&u.activeRow.id&&(y.parentId=(u==null?void 0:u.activeRow.id)+"");else{for(let g in u==null?void 0:u.activeRow)y[g]=u==null?void 0:u.activeRow[g];(u==null?void 0:u.activeRow.currentLevel)>1&&(a.options.autoCropWidth=210,a.options.autoCropHeight=268,a.messageTip="\u8BF7\u4E0A\u4F20\u5C3A\u5BF8\u4E3A210*268\u5927\u5C0F5M\u4EE5\u5185\u7684JPG\u3001PNG\u56FE\u7247")}}),()=>t("div",null,[t(Ce,{ref:l,model:y},{default:()=>[u.saveMode==="add"&&u.activeRow&&t(v,{label:"\u7236\u7EA7\u5206\u7C7B",path:"parentId"},{default:()=>[t(Ue,{placeholder:"\u8BF7\u9009\u62E9\u7236\u7EA7\u5206\u7C7B",value:y.parentId,"onUpdate:value":g=>y.parentId=g,options:e.value,checkStrategy:"all",expandTrigger:"hover",childrenField:"musicSheetCategoriesList",valueField:"id",labelField:"name",disabled:!0},null)]}),t(v,{label:"\u5206\u7C7B\u540D\u79F0",rule:[{required:!0,message:"\u8BF7\u8F93\u5165\u5206\u7C7B\u540D\u79F0",trigger:["blur","input"]}],path:"name"},{default:()=>[t(ie,{value:y.name,"onUpdate:value":g=>y.name=g,placeholder:"\u8BF7\u8F93\u5165\u5206\u7C7B\u540D\u79F0",maxlength:25,showCount:!0,clearable:!0},null)]}),t(v,{label:"\u5C01\u9762\u56FE",path:"coverImg",rule:[{required:!0,message:"\u8BF7\u4E0A\u4F20\u5C01\u9762\u56FE",trigger:["input","blur"]}]},{default:()=>[t(te,{fileList:y.coverImg,"onUpdate:fileList":g=>y.coverImg=g,accept:".jpg,.jpeg,.png",cropper:!0,size:5,class:fa.updateFile,bucketName:"news-info",options:a.options,tips:a.messageTip},null)]})]}),t(W,{justify:"end"},{default:()=>[t(O,{type:"default",onClick:()=>I("close")},{default:()=>[m("\u53D6\u6D88")]}),t(O,{type:"primary",onClick:()=>k(),loading:a.btnLoading,disabled:a.btnLoading},{default:()=>[m("\u786E\u8BA4")]})]})])}}),ga=se({emits:["setTabName","jump"],name:"music-category",setup(u,{slots:I,attrs:d,emit:l}){const e=ee({loading:!1,pagination:{page:1,rows:10},dataList:[],showSaveDialog:!1,saveMode:"add",saveRowData:null}),a=we(),y=ne(),k=()=>A(this,null,function*(){try{e.loading=!0;const c={page:e.pagination.page,rows:e.pagination.rows},{data:L}=yield Fe(c);e.dataList=L||[]}catch(c){}e.loading=!1});ce(()=>{k()});const g=c=>{l("jump",c)},x=()=>[{title:"\u5206\u7C7B\u540D\u79F0",key:"id",render(c){return c.name+"("+c.id+")"}},{title:"\u66F2\u76EE\u6570\u91CF",key:"musicSheetNum",render(c){return t("div",null,[t(O,{type:"primary",size:"small",text:!0,onClick:()=>{g({tabName:"MusicList",musicCategoryId:c.id})}},{default:()=>[c.musicSheetNum]})])}},{title:"\u6700\u540E\u66F4\u65B0\u65F6\u95F4",key:"updateTime"},{title:"\u66F4\u65B0\u4EBA",key:"operatorName"},{title:"\u64CD\u4F5C",key:"operation",fixed:"right",render(c){return t(W,null,{default:()=>[J(t(O,{type:"error",size:"small",text:!0,onClick:()=>S(c)},{default:()=>[m("\u5220\u9664")]}),[[X("auth"),"musicSheetCategories/remove1751239397398806530"]]),J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.saveRowData=c,e.saveMode="edit",e.showSaveDialog=!0}},{default:()=>[m("\u4FEE\u6539")]}),[[X("auth"),"musicSheetCategories/update1751239533856292866"]]),c.currentLevel<4&&J(t(O,{type:"primary",size:"small",text:!0,onClick:()=>{e.saveRowData=c,e.showSaveDialog=!0,e.saveMode="add"}},{default:()=>[m("\u6DFB\u52A0\u5B50\u5206\u7C7B")]}),[[X("auth"),"musicSheetCategories/save1751239479284203521"]])]})}}],P=()=>{e.pagination.page=1,k()},S=c=>A(this,null,function*(){a.warning({title:"\u63D0\u793A",content:"\u662F\u5426\u786E\u8BA4\u5220\u9664'"+c.name+"'?",positiveText:"\u786E\u5B9A",negativeText:"\u53D6\u6D88",onPositiveClick:()=>A(this,null,function*(){(yield kt(c.id)).data&&(P(),y.success("\u5220\u9664\u6210\u529F"))})})});return()=>t("div",{class:"system-menu-container"},[t("div",{class:["section-container"]},[t(W,{style:{paddingBottom:"12px"}},{default:()=>[J(t(O,{type:"primary",onClick:()=>{e.saveMode="add",e.showSaveDialog=!0,e.saveRowData=null}},{default:()=>[m("\u65B0\u589E\u5206\u7C7B")]}),[[X("auth"),"musicSheetCategories/save1751239479284203521"]])]}),t(ve,{loading:e.loading,columns:x(),data:e.dataList,rowKey:c=>c.id,childrenKey:"musicSheetCategoriesList"},null)]),t(oe,{show:e.showSaveDialog,"onUpdate:show":c=>e.showSaveDialog=c,preset:"dialog",showIcon:!1,title:e.saveRowData?"\u4FEE\u6539\u5206\u7C7B":"\u65B0\u589E\u5206\u7C7B",style:{width:"600px"}},{default:()=>[t(ha,{onGetList:()=>{e.showSaveDialog=!1,k()},onClose:()=>{e.showSaveDialog=!1},list:e.dataList,saveMode:e.saveMode,activeRow:e.saveRowData},null)]})])}}),Ka=se({name:"music-sheet",setup(){const u=ee({tabName:"MusicList",searchId:null,musicCategoryId:null}),I=Dt();Gt(e=>{e.form.tabName&&(u.tabName=e.form.tabName)});const d=e=>{console.log("setTabName",e),u.tabName=e.tabName,u.searchId=e.id},l=e=>{Kt(e,"tabName",I)};return()=>t("div",{class:"system-menu-container"},[t("div",{class:["section-container"],style:"padding-top: 0"},[t(jt,{type:"line",size:"large",value:u.tabName,"onUpdate:value":[e=>u.tabName=e,e=>l(e)]},{default:()=>[J(t(Re,{name:"MusicList",tab:"\u66F2\u76EE\u5217\u8868"},{default:()=>[t(da,{searchId:u.searchId,musicCategoryId:u.musicCategoryId},null)]}),[[X("auth"),"musicSheet/page1751238894313013249"]]),J(t(Re,{name:"CategroryList",tab:"\u66F2\u76EE\u5206\u7C7B"},{default:()=>[t(ga,{onSetTabName:d,onJump:e=>{u.tabName=e.tabName,u.musicCategoryId=e.musicCategoryId}},null)]}),[[X("auth"),"musicSheetCategories/queryTree1751238805699952641"]])]})])])}});export{Ka as default};