You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
13 KiB

1 year ago
  1. var e=Object.defineProperty,t=Object.prototype.hasOwnProperty,o=Object.getOwnPropertySymbols,i=Object.prototype.propertyIsEnumerable,s=(t,o,i)=>o in t?e(t,o,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[o]=i,l=(e,l)=>{for(var a in l||(l={}))t.call(l,a)&&s(e,a,l[a]);if(o)for(var a of o(l))i.call(l,a)&&s(e,a,l[a]);return e};import{_ as a}from"./returnBar.35b6215f.js";import{B as c,x as n,v as d,T as A,G as r,p as b,m as I,c as k,t as u,F as p,q as m,s as g,w as h,r as T,o as v,u as R}from"./vendor.269b2875.js";import"./pinlun@2x.628190cf.js";import"./paixu@2x.fd1743af.js";const M={name:"mineCollection",components:{ReturnBar:a},setup(){const{proxy:e}=c(),t=n({topTitle:"书架",path:"doc",TabCur:0,tabList:[{name:"阅文"},{name:"视频"},{name:"读书"}],materialList:[],videoList:[],bookList:[],bookType:"",ResourceId:"",ebookId:"",currentIndex:"",ifkon:!0,ifkon2:!0,ifkon3:!0,collectStateShow:!1,isTryOutLogin:!0});d((()=>{const s=e;t.isTryOutLogin=!localStorage.getItem("isTryout"),t.TabCur=e.$route.query.index,t.TabCur?o():(t.TabCur=0,s.path="doc",i())}));let o=()=>{const t=e;0==t.TabCur?t.path="doc":1==t.TabCur?t.path="video":2==t.TabCur&&(t.path="ebook"),i()},i=()=>{const t=e;let o={Path:t.path,Where:"",Order:"Date_desc",pageIndex:1,pageSize:10};t.$http.get(e.$API.GETMYCOLLECTSPAGES,{params:o}).then((e=>{200==e.type?"doc"==t.path?(t.materialList=e.data,t.ifkon=0==t.materialList.length):"video"==t.path?(t.videoList=e.data,t.ifkon2=0==t.videoList.length):"ebook"==t.path&&(t.bookList=e.data,t.ifkon3=0==t.bookList.length):A(e.content)})).catch((e=>{}))},s=t=>{const o=e;o.ebookId=t,o.$http.get(e.$API.GETBASEANDDETAILSID,{params:{BaseId:o.ebookId}}).then((e=>{if(200==e.type){let t=e.data;if(o.bookType=t.tResource.bookType,o.ResourceId=t.tResource.id,null==o.ResourceId)return;a()}else A(e.content)}))},a=()=>{const t=e;t.$http.get(e.$API.GETRESOURCEANDUSEDBYRESOURCEID,{params:{BaseId:t.ebookId,ResourceId:t.ResourceId}}).then((o=>{if(200==o.type){let i=o.data;t.currentIndex=i.tUsed.length?i.tUsed[0].scheduleOne:null,1==t.bookType?e.$router.push({path:"/epubReading",query:{ebookId:t.ebookId,ResourceId:t.ResourceId,currentIndex:t.currentIndex}}):e.$router.push({path:"/readingSetting",query:{ebookId:t.ebookId,ResourceId:t.ResourceId,currentIndex:t.currentIndex}})}}))};return l(l({},r(t)),{initCollectList:o,toSearch:t=>{e.$router.push({path:"/searchBook",query:{tablist:t}})},tabChange:t=>{e.TabCur=t,o()},MyCollect:i,ToEbook:()=>{e.$router.push("/reading")},Toyuewen:()=>{e.$router.push("/material")},Toshipin:()=>{e.$router.push("/VideoIndex")},todatadetails:(t,o,i)=>{const l=e;let a={Path:t,BaseId:i,Id:o};l.$http.put(e.$API.CHECKMYCOLLECTSSTATE,a,{headers:{"Content-Type":"application/x-www-form-urlencoded"}}).then((o=>{if(200==o.type)if(o.data)switch(t){case"doc":e.$router.push("/materialDetails?id="+i);break;case"video":e.$router.push("/videoDetails?id="+i);break;case"ebook":s(i)}else l.collectStateShow=!0,l.tabChange(l.TabCur);else A(o.content)})).catch((e=>{}))},GetBaseAndDetailsId:s,GetResourceAndUsedByResourceId:a,closePopup:()=>{t.collectStateShow=!1}})}},y=h("data-v-2f9fb294");b("data-v-2f9fb294");const C={class:"main"},E={class:"status"},w={class:"tabList"},B={key:0,class:"myCollect_item"},G={class:"materialCover"},U={class:"materialItem"},Y={class:"materialTitle"},Z={class:"materialcontent"},N={class:"SubBottom"},D={class:"materialBtn"},S=u("img",{src:"/assets/kongzhuangtai-yuewen@2x.418cde47.png",class:"konyw"},null,-1),L=u("div",{class:"kontext"},"暂无内容",-1),O=u("img",{src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB8AAAAgCAYAAADqgqNBAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTM4IDc5LjE1OTgyNCwgMjAxNi8wOS8xNC0wMTowOTowMSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hh