1 |
- import{d as o,y as c,z as n,f as d,v as m,n as l,j as e,A as i,B as h}from"./ResizeObserver.es.39b48a47.js";import{C as p}from"./index.db115763.js";import{i as _,a as y,b as g}from"./icon_discount.535f7618.js";import{i as F}from"./icon_teacher.40b6f077.js";const v="_musicShare_1k540_1",E="_header_1k540_5",I="_btnMore_1k540_23",T="_section_1k540_29",b="_music_1k540_1",k="_discount_1k540_56",A="_shareTeacher_1k540_61",S="_teacherImg_1k540_69",D="_recommend_1k540_75",f="_img_1k540_81",C="_name_1k540_86",B="_titleTips_1k540_91";var s={musicShare:v,header:E,btnMore:I,section:T,music:b,discount:k,shareTeacher:A,teacherImg:S,recommend:D,img:f,name:C,titleTips:B},M=o({name:"share-music-sheet",data(){const t=this.$route.query;return{id:t.id,recomUserId:t.recomUserId,activityId:t.activityId||0,discounts:0,musicSheet:{},teacherName:""}},async mounted(){try{const t=await c.post("/api-teacher/open/musicShareProfit",{data:{bizId:this.id,userId:this.recomUserId}});if(this.musicSheet=t.data.musicSheet||{},this.teacherName=t.data.name||"",this.activityId){const u=await c.post(`/api-student/open/activity/state/${this.activityId}`,{data:{}});this.discounts=u.data.check||0}}catch{}this.onDetail()},methods:{onDetail(){const t=n(),u=d(),a="/klx-music-score/",r=m.stringifyUrl({url:location.origin+a,query:{id:this.id,recomUserId:this.$route.query.userType&&this.$route.query.userType=="STUDENT"?"":this.recomUserId,activityId:this.activityId,discounts:this.discounts,systemType:u.isStudent?"student":"teacher",behaviorId:t}});l({api:"openAccompanyWebView",content:{url:r,orientation:0,isHideTitle:!0,statusBarTextColor:!1,isOpenLight:!0}})}},render(){return e("div",{class:s.musicShare},[e("div",{class:s.header},[e("h2",null,[i("\u79D1\u5B66\u7684\u7EC3\u4E60\u6709\u52A9"),e("br",null,null),i("\u4E8E\u6C34\u5E73\u5FEB\u901F\u63D0\u5347")]),e("p",null,[i("\u4F60\u7684\u6C34\u5E73\u4E00\u5B9A\u80FD\u9A7E\u9A6D\u8FD9\u9996\u66F2\u5B50\uFF01")])]),e("div",{class:s.section},[e("div",{class:s.music},[e("img",{src:_},null),e("div",null,[e("h2",null,[this.musicSheet.musicSheetName]),e("p",null,[i("\u4F5C\u66F2\u4EBA: "),this.musicSheet.composer]),this.discounts==1&&e("img",{src:y,class:s.discount},null)])]),e(p,{center:!0,border:!1,class:s.shareTeacher},{icon:()=>e("div",{class:s.teacherImg},[e("img",{src:this.musicSheet.avatar||F,class:s.img,style:{objectFit:"cover"},crossorigin:"anonymous"},null),e("img",{class:s.recommend,src:g},null)]),title:()=>e("div",null,[e("p",{class:s.name},[i("\u8FD9\u4E2A\u66F2\u5B50\u633A\u4E0D\u9519\uFF01\u63A8\u8350\u7ED9\u4F60\uFF5E")]),e("p",{class:s.titleTips},[e("span",null,[this.teacherName]),i(" \u8001\u5E08\u4E3A\u60A8\u63A8\u8350")])])})]),e("div",{class:["btnGroup"],style:{paddingTop:"60px",margin:"0 28px"}},[e(h,{block:!0,round:!0,type:"primary",onClick:this.onDetail,class:s.btnMore,color:"linear-gradient(180deg, #59E5D5 0%, #2DC7AA 100%)"},{default:()=>[i("\u6253\u5361\u5C0F\u9177Ai\u5F00\u59CB\u7EC3\u4E60\u5427\uFF01")]})])])}});export{M as default};
|