123 |
- ;(function(){function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable;})),keys.push.apply(keys,symbols);}return keys;}function _objectSpread(target){for(var i=1;i<arguments.length;i++){var source=null!=arguments[i]?arguments[i]:{};i%2?ownKeys(Object(source),!0).forEach(function(key){_defineProperty(target,key,source[key]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key));});}return target;}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value:value,enumerable:true,configurable:true,writable:true});}else{obj[key]=value;}return obj;}function asyncGeneratorStep(gen,resolve,reject,_next,_throw,key,arg){try{var info=gen[key](arg);var value=info.value;}catch(error){reject(error);return;}if(info.done){resolve(value);}else{Promise.resolve(value).then(_next,_throw);}}function _asyncToGenerator(fn){return function(){var self=this,args=arguments;return new Promise(function(resolve,reject){var gen=fn.apply(self,args);function _next(value){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"next",value);}function _throw(err){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"throw",err);}_next(undefined);});};}System.register(['./moreArrow-legacy.12b046be.js','./index-legacy.292fd86b.js','./index-legacy.2d27d03b.js','./index-legacy.e37fc1fe.js','./scrollbar.min-legacy.082b1fa0.js','./index-legacy.29a20a1f.js','./index-legacy.d7e8f584.js','./index-legacy.8179fe1d.js','./titleDot-legacy.26cf1726.js','./vendor-legacy.b19481d4.js','./player-legacy.c7d3b4b9.js','./icon-legacy.aed5a5b3.js','./music-legacy.146bf361.js','./lineStart-legacy.f91a0e0f.js','./icon_album_active-legacy.72d719cb.js'],function(exports){'use strict';var arrow,albumItem,styles,videoDetailItem,musicListItem,hotSearch,silder,state,request,getUserType,searchInput,useSubjectId,SubjectEnum,banner,courseIcon,defineComponent,reactive,useRouter,onMounted,createVNode,Fragment,createTextVNode;return{setters:[function(module){arrow=module.a;},function(module){albumItem=module.a;styles=module.s;},function(module){videoDetailItem=module.v;},function(module){musicListItem=module.m;},function(module){hotSearch=module.h;},function(module){silder=module.b;state=module.c;request=module.r;getUserType=module.g;},function(module){searchInput=module.s;useSubjectId=module.u;SubjectEnum=module.S;},function(module){banner=module.b;},function(module){courseIcon=module.c;},function(module){defineComponent=module.d;reactive=module.r;useRouter=module.f;onMounted=module.o;createVNode=module.c;Fragment=module.F;createTextVNode=module.a;},function(){},function(){},function(){},function(){},function(){}],execute:function execute(){var index=exports('default',defineComponent({name:'musicLibrary',components:{albumItem:albumItem,videoDetailItem:videoDetailItem,musicLIstItem:musicListItem,hotSearch:hotSearch,silder:silder,searchInput:searchInput,banner:banner},setup:function setup(){var _state$user$data;var subjectId=0;var subjectIds=((_state$user$data=state.user.data)===null||_state$user$data===void 0?void 0:_state$user$data.subjectId)||'';if(subjectIds){subjectId=Number(subjectIds.split(',')[0]);}// 判断是否在默认的声部
- var subjects=useSubjectId(SubjectEnum.SEARCH);subjectId=subjects.id||subjectId;var state$1=reactive({albumList:[],musicList:[]});var router=useRouter();var getAlbumList=/*#__PURE__*/function(){var _ref=_asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee(){var res;return regeneratorRuntime.wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:_context.prev=0;_context.next=3;return request.post('/api-website/open/music/album/list',{data:{albumStatus:1,page:1,subjectIds:subjectId?subjectId:null,rows:10},params:{clientType:getUserType()}});case 3:res=_context.sent;state$1.albumList=res.data.rows;_context.next=10;break;case 7:_context.prev=7;_context.t0=_context["catch"](0);console.log(_context.t0);case 10:case"end":return _context.stop();}}},_callee,null,[[0,7]]);}));return function getAlbumList(){return _ref.apply(this,arguments);};}();var getMusicList=/*#__PURE__*/function(){var _ref2=_asyncToGenerator(/*#__PURE__*/regeneratorRuntime.mark(function _callee2(){var res;return regeneratorRuntime.wrap(function _callee2$(_context2){while(1){switch(_context2.prev=_context2.next){case 0:_context2.prev=0;_context2.next=3;return request.post('/api-website/open/music/sheet/list',{data:{albumStatus:'PASS',subjectIds:subjectId?subjectId:null,page:1,rows:5,state:1}});case 3:res=_context2.sent;// state.musicList = res.data.rows
- state$1.musicList=res.data.rows.map(function(n){if(typeof n.paymentType==='string')n.paymentType=n.paymentType.split(',');return n;});_context2.next=10;break;case 7:_context2.prev=7;_context2.t0=_context2["catch"](0);console.log(_context2.t0);case 10:case"end":return _context2.stop();}}},_callee2,null,[[0,7]]);}));return function getMusicList(){return _ref2.apply(this,arguments);};}();var gotoSearch=function gotoSearch(val){if(typeof val=='string'){router.push({name:'searchdetail',params:{search:val}});}else{router.push({name:'searchdetail',params:_objectSpread({},val)});}};var gotoMusic=function gotoMusic(){router.push({name:'searchdetail',params:{type:'music'}});};var gotoAlbum=function gotoAlbum(){router.push({name:'searchdetail',params:{type:''}});};onMounted(function(){getAlbumList();getMusicList();});return function(){return createVNode("div",null,[createVNode(banner,null,null),createVNode("div",{"class":"bg-white"},[createVNode("div",{"class":styles.w1200},[createVNode("div",{"class":styles.section},[createVNode(searchInput,{"isWhile":false,"type":"search","onStartSearch":function onStartSearch(val){return gotoSearch(val);}},null),createVNode("div",{"class":styles.hotSearch},[createVNode(hotSearch,{"onHotTag":function onHotTag(val){gotoSearch(val);},"type":''},null)]),state$1.albumList&&state$1.albumList.length>0&&createVNode(Fragment,null,[createVNode("div",{"class":[styles.videoNav,styles.mt25]},[createVNode("div",{"class":styles.titleWrap},[createVNode("h5",{"class":styles.hotAlbum},[createTextVNode("\u70ED\u95E8\u4E13\u8F91")]),createVNode("img",{"src":courseIcon,"class":styles.dotImg,"alt":""},null)]),createVNode("div",{"class":styles.wrapRight,"onClick":function onClick(){return gotoAlbum();}},[createVNode("span",null,[createTextVNode("\u66F4\u591A")]),createVNode("img",{"class":styles.arrow,"src":arrow,"alt":""},null)])]),createVNode("div",{"class":styles.albumList},[state$1.albumList.map(function(item){return createVNode(albumItem,{"detail":item},null);})])])])])]),createVNode("div",null,[createVNode("div",{"class":styles.w1200},[state$1.musicList&&state$1.musicList.length>0&&createVNode(Fragment,null,[createVNode("div",{"class":[styles.section,styles.pb40],"style":"padding-top: 0"},[createVNode("div",{"class":styles.videoNav},[createVNode("div",{"class":styles.titleWrap},[createVNode("h5",null,[createTextVNode("\u70ED\u95E8\u4E50\u8C31")]),createVNode("img",{"src":courseIcon,"class":styles.dotImg,"alt":""},null)]),createVNode("div",{"class":styles.wrapRight,"onClick":function onClick(){return gotoMusic();}},[createVNode("span",null,[createTextVNode("\u66F4\u591A")]),createVNode("img",{"class":styles.arrow,"src":arrow,"alt":""},null)])]),createVNode("div",{"class":styles.musicList},[state$1.musicList.map(function(item){return createVNode(musicListItem,{"item":item},null);})])])])])]),createVNode(silder,null,null)]);};}}));}};});})();
|