;(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(['./index-legacy.af1a9ddf.js','./scrollbar.min-legacy.b98aa664.js','./index-legacy.3d3409b2.js','./index-legacy.e813d1c2.js','./index-legacy.47df0088.js','./index-legacy.b5758dd8.js','./vendor-legacy.2ed87b03.js','./index-legacy.cb1d353d.js','./index-legacy.dbb8d812.js','./moreArrow-legacy.0258a34d.js','./hold-legacy.fa388436.js','./lineStart-legacy.cf9abd3c.js','./player-legacy.c7d3b4b9.js','./icon-legacy.aed5a5b3.js','./music-legacy.146bf361.js','./icon_album_active-legacy.72d719cb.js'],function(exports){'use strict';var albumItem,styles,hotSearch,silder,request,getUserType,searchInput,useSubjectId,SubjectEnum,Pagination,ColEmpty,defineComponent,reactive,onMounted,toRefs,createVNode,useRoute,ref,watch,nextTick,ElTabs,ElTabPane,albumItem$1,musicLIstItem;return{setters:[function(module){albumItem=module.a;styles=module.s;},function(module){hotSearch=module.h;},function(module){silder=module.b;request=module.r;getUserType=module.g;},function(module){searchInput=module.s;useSubjectId=module.u;SubjectEnum=module.S;},function(module){Pagination=module.P;},function(module){ColEmpty=module.C;},function(module){defineComponent=module.d;reactive=module.r;onMounted=module.o;toRefs=module.t;createVNode=module.c;useRoute=module.u;ref=module.a3;watch=module.a0;nextTick=module.n;ElTabs=module.O;ElTabPane=module.P;},function(module){albumItem$1=module.a;},function(module){musicLIstItem=module.m;},function(){},function(){},function(){},function(){},function(){},function(){},function(){}],execute:function execute(){var searchAlbum=defineComponent({name:'searchdetail',components:{hotSearch:hotSearch,silder:silder,searchInput:searchInput,albumItem:albumItem,pagination:Pagination,ColEmpty:ColEmpty},setup:function setup(){var state=reactive({albumList:[],musicList:[],search:{},isshowData:false,pageInfo:{// 分页规则
limit:40,// 限制显示条数
page:1,// 当前页
total:0,// 总条数
page_size:[5,10,20,40,50]// 选择限制显示条数
}});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:_objectSpread(_objectSpread({albumStatus:1},state.search),{},{page:state.pageInfo.page,rows:state.pageInfo.limit}),params:{clientType:getUserType()}});case 3:res=_context.sent;state.albumList=res.data.rows;state.pageInfo.total=res.data.total;if(state.pageInfo.total==0){state.isshowData=true;}else{state.isshowData=false;}_context.next=12;break;case 9:_context.prev=9;_context.t0=_context["catch"](0);console.log(_context.t0);case 12:case"end":return _context.stop();}}},_callee,null,[[0,9]]);}));return function getAlbumList(){return _ref.apply(this,arguments);};}();var getList=function getList(val){state.search=_objectSpread(_objectSpread({},val),{},{idAndName:val.search,subjectIds:val.subject,exquisiteFlag:val.exquisiteFlag});state.pageInfo.page=1;getAlbumList();};onMounted(function(){// getAlbumList()
// getMusicList()
});return _objectSpread(_objectSpread({},toRefs(state)),{},{getList:getList,getAlbumList:getAlbumList});},render:function render(){var _this=this;return createVNode("div",null,[createVNode("div",null,[createVNode("div",{"class":styles.w1200},[createVNode("div",{"class":styles.section},[createVNode("div",{"class":styles.albumList},[this.albumList.map(function(item){return createVNode(albumItem,{"detail":item},null);})]),this.isshowData&&createVNode(ColEmpty,null,null)])])]),createVNode(Pagination,{"total":this.pageInfo.total,"page":this.pageInfo.page,"onUpdate:page":function onUpdatePage($event){return _this.pageInfo.page=$event;},"limit":this.pageInfo.limit,"onUpdate:limit":function onUpdateLimit($event){return _this.pageInfo.limit=$event;},"pageSizes":this.pageInfo.page_size,"pagination":this.getAlbumList},null)]);}});var searchMusic=defineComponent({name:'searchMusic',components:{hotSearch:hotSearch,silder:silder,searchInput:searchInput,albumItem:albumItem$1,musicListItem:musicLIstItem,pagination:Pagination,ColEmpty:ColEmpty},setup:function setup(){var state=reactive({musicList:[],search:{},isshowData:false,pageInfo:{// 分页规则
limit:10,// 限制显示条数
page:1,// 当前页
total:0,// 总条数
page_size:[5,10,20,40,50]// 选择限制显示条数
}});// const getAlbumList = async () => {
//   try {
//     const res = await request.post('/api-website/open/music/album/list', {
//       data: {
//         albumStatus: 1,
//         page: 1,
//         rows: 10
//       }
//     })
//     state.albumList = res.data.rows
//   } catch (e) {
//     console.log(e)
//   }
// }
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:_objectSpread(_objectSpread({albumStatus:'PASS'},state.search),{},{page:state.pageInfo.page,rows:state.pageInfo.limit,state:1}),params:{clientType:getUserType()}});case 3:res=_context2.sent;state.musicList=res.data.rows.map(function(n){if(typeof n.paymentType==="string")n.paymentType=n.paymentType.split(',');return n;});state.pageInfo.total=res.data.total;if(state.pageInfo.total==0){state.isshowData=true;}else{state.isshowData=false;}_context2.next=12;break;case 9:_context2.prev=9;_context2.t0=_context2["catch"](0);console.log(_context2.t0);case 12:case"end":return _context2.stop();}}},_callee2,null,[[0,9]]);}));return function getMusicList(){return _ref2.apply(this,arguments);};}();var getList=function getList(val){state.search={subjectIds:val.subject,musicTagIds:val.albumTagIds,exquisiteFlag:val.exquisiteFlag,idAndName:val.search};state.pageInfo.page=1;getMusicList();};onMounted(function(){// getAlbumList()
// getList(state.search)
});return _objectSpread(_objectSpread({},toRefs(state)),{},{getList:getList,getMusicList:getMusicList});},render:function render(){var _this2=this;return createVNode("div",null,[createVNode("div",null,[createVNode("div",{"class":styles.w1200},[createVNode("div",{"class":styles.section},[createVNode("div",{"class":styles.musicList},[this.musicList.map(function(item){return createVNode(musicLIstItem,{"item":item},null);})])])]),this.isshowData&&createVNode(ColEmpty,null,null)]),createVNode(Pagination,{"total":this.pageInfo.total,"page":this.pageInfo.page,"onUpdate:page":function onUpdatePage($event){return _this2.pageInfo.page=$event;},"limit":this.pageInfo.limit,"onUpdate:limit":function onUpdateLimit($event){return _this2.pageInfo.limit=$event;},"pageSizes":this.pageInfo.page_size,"pagination":this.getMusicList},null)]);}});var searchdetail=exports('default',defineComponent({name:'searchdetail',components:{hotSearch:hotSearch,silder:silder,searchInput:searchInput,searchAlbum:searchAlbum,searchMusic:searchMusic},setup:function setup(){var subjects=useSubjectId(SubjectEnum.SEARCH);var state=reactive({albumList:[],musicList:[],chiose:'album',searchs:{albumTagIds:'',search:'',exquisiteFlag:null,subject:subjects.id||''}});var route=useRoute();var searchAlbumRef=ref();var searchMusicRef=ref();// const getAlbumList = async () => {
//   try {
//     const res = await request.post('/api-website/open/music/album/list', {
//       data: {
//         albumStatus: 1,
//         page: 1,
//         rows: 10
//       }
//     })
//     state.albumList = res.data.rows
//   } catch (e) {
//     console.log(e)
//   }
// }
// const getMusicList = async () => {
//   try {
//     const res = await request.post('/api-website/open/music/sheet/list', {
//       data: {
//         albumStatus: 'PASS',
//         page: 1,
//         rows: 5,
//         state: 1
//       }
//     })
//     state.musicList = res.data.rows
//   } catch (e) {
//     console.log(e)
//   }
// }
var searchRust=function searchRust(val){console.log(val,'search');var smallTag=(val||[]).filter(function(tag){return tag<0;});var maxTag=(val||[]).filter(function(tag){return tag>0;});state.searchs.albumTagIds=maxTag.join(',');state.searchs.exquisiteFlag=null;if(smallTag[0]==-2){state.searchs.exquisiteFlag=1;}startSearch(state.searchs);};var startSearch=function startSearch(val){state.searchs=_objectSpread(_objectSpread({},state.searchs),val);search();};var search=function search(){console.log(state.searchs,'1212');if(state.chiose=='album'){searchAlbumRef.value.getList(state.searchs);}if(state.chiose=='music'){searchMusicRef.value.getList(state.searchs);}};watch(function(){return state.chiose;},function(chiose){nextTick(function(){search();});});onMounted(function(){if(route.params.search){state.searchs.search=route.params.search;}if(route.params.subject){state.searchs.subject=route.params.subject;}if(route.params.type){state.chiose=route.params.type;}nextTick(function(){search();});// getAlbumList()
// getMusicList()
});return _objectSpread(_objectSpread({},toRefs(state)),{},{startSearch:startSearch,searchRust:searchRust,searchAlbumRef:searchAlbumRef,searchMusicRef:searchMusicRef,search:search});},render:function render(){var _this3=this;return createVNode("div",null,[createVNode("div",{"class":""},[createVNode("div",{"class":"wall","style":{height:'60px'}},null),createVNode("div",{"class":styles.w1200},[createVNode("div",{"class":styles.section},[createVNode(searchInput,{"isWhile":true,"searchVal":_objectSpread({},this.searchs),"onUpdate:searchVal":function onUpdateSearchVal(val){console.log(val,'1212');},"type":"search","onStartSearch":function onStartSearch(val){_this3.startSearch(val);}},null),createVNode("div",{"class":styles.hotSearch},[createVNode(hotSearch,{"type":'search',"onSearchRust":function onSearchRust(val){return _this3.searchRust(val);},"onHotTag":function onHotTag(val){_this3.searchs.search=val;_this3.search();},"isChiose":true},null)]),createVNode("div",{"class":styles.myTabWrap},[createVNode(ElTabs,{"class":styles.myTab,"modelValue":this.chiose,"onUpdate:modelValue":function onUpdateModelValue($event){return _this3.chiose=$event;}},{default:function _default(){return[createVNode(ElTabPane,{"label":"专辑","name":"album"},{default:function _default(){return[_this3.chiose=='album'?createVNode(searchAlbum,{"ref":"searchAlbumRef"},null):null];}}),createVNode(ElTabPane,{"label":"乐谱","name":"music"},{default:function _default(){return[_this3.chiose=='music'?createVNode(searchMusic,{"ref":"searchMusicRef"},null):null];}})];}})])])])])]);}}));}};});})();
