| 1 |
- import{d as T,o as I,c as h,u as y,a as _,b as f,g as v,r as p,e as g,f as S,h as A,i as E,j as P,_ as i,p as w,s as R,k as b,l as C,m as D}from"./use-app.7c01c22a.js";import"./lib-flexible.08f197e6.js";var m=T({setup(){var d;const e=y();(d=e==null?void 0:e.query)!=null&&d.Authorization&&sessionStorage.setItem("Authorization",e.query.Authorization);let o=Date.now();const c=""+Date.now(),u=async()=>{const r=_();if(r!="student")return;const t=f(),n=v(),l=(Date.now()-o)/1e3;if(o=Date.now(),await p.post("/musicPracticeRecord/save",{prefix:n,requestType:"json",data:{musicSheetId:t.id,sysMusicScoreId:t.id,feature:"PRACTICE",practiceSource:"PRACTICE",playTime:l,deviceType:g(),behaviorId:c}}),t.lessonTrainingId)try{console.log(n);const s=S(),q=await p.post("/studentLessonTraining/lessonTrainingRecord",{prefix:n,requestType:"json",data:{materialType:"SONG",record:{clientType:r==null?void 0:r.toLocaleUpperCase(),practiceSource:"LESSON_TRAINING",feature:"PRACTICE",deviceType:s.android?"ANDROID":s.isApp?"IOS":"WEB",behaviorId:c,playTime:l,musicSheetId:t.id},courseScheduleId:t.courseScheduleId,lessonTrainingId:t.lessonTrainingId,materialId:t.materialId}})}catch{}};let a=null;return I(()=>{clearInterval(a),e.name&&(console.log("\u8FDB\u5165\u4E91\u6559\u7EC3"),a=setInterval(()=>{u()},60*1e3),window.addEventListener("beforeunload",()=>{clearInterval(a),u()}))}),()=>h(A("router-view"),null,null)}}),O=Object.freeze(Object.defineProperty({__proto__:null,default:m},Symbol.toStringTag,{value:"Module"}));const L=[{path:"/",name:"home",component:()=>i(()=>Promise.resolve().then(function(){return O}),void 0),children:[{path:"",name:"musicScore",component:()=>i(()=>import("./index.ae39e5c0.js"),["assets/index.ae39e5c0.js","assets/index.3ba46ee8.css","assets/use-app.7c01c22a.js","assets/use-app.3609285a.css","assets/index.a3d1ea16.js","assets/index.829bb698.css","assets/index.109aa76c.js","assets/index.db98ffbc.js","assets/index.a1f41ec5.js","assets/index.020a6c9c.css","assets/index.3552af69.js"])}]},{path:"/:path(.*)*",name:"ErrorPage",component:()=>i(()=>import("./index.1f476df4.js"),["assets/index.1f476df4.js","assets/use-app.7c01c22a.js","assets/use-app.3609285a.css","assets/index.109aa76c.js"])}];var N=E({history:P("/orchestra-music-score"),routes:L});w({api:"getToken"}).then(e=>{var o;(o=e==null?void 0:e.content)!=null&&o.accessToken&&sessionStorage.setItem("Authorization",e.content.tokenType+" "+e.content.accessToken)});R.clintNmae="colexiu";window.DYEnvironment="colexiu";document.body.style.setProperty("--osdm-zoom",""+b());C();D(m).use(N).mount("#app");
|