import{e as f,r as s,P as r,Q as u,a3 as n,a9 as v,a8 as _}from"./vue-bf422dc1.js";import{g as h}from"./shop-fcfd0d1e.js";import d from"./index-87f19ea8.js";import{_ as g}from"./index.vue_vue_type_script_setup_true_lang-bc209960.js";import k from"./index-fc3bfb91.js";const y={key:3},D=f({__name:"pc",setup(B){const c=_(),o=s(""),{token:m}=c.currentRoute.value.params,p=s(""),e=s({shop:{shop_name:""},categorys:[],goods:[],error:""}),i=t=>{document.title=t};return(async()=>{const a=await h({token:m});if(a.code===0)p.value=a.msg,o.value="error",e.value.error=a.msg;else{const{data:l}=a;o.value=l.pcTemplate,e.value=l,i(e.value.shop.shop_name?e.value.shop.shop_name:"未命名商铺"),e.value.categorys.length||(o.value="error",e.value.error="请添加商品分类后重试！")}})(),(t,a)=>(r(),u("div",null,[o.value=="default"?(r(),n(d,{key:0,info:e.value},null,8,["info"])):v("",!0),o.value=="year"?(r(),n(k,{key:1,info:e.value},null,8,["info"])):o.value=="error"?(r(),n(g,{key:2,tip:e.value},null,8,["tip"])):(r(),u("div",y))]))}});export{D as _};
