(function(){"use strict";var e={2008:function(e,t,n){n(4114);var a=n(6674),i=function(){var e=this,t=e._self._c;return t("div",{attrs:{id:"app"}},["Register"!==e.$route.name?t("HeaderNav"):e._e(),"Login"!==e.$route.name?t("main",{staticClass:"main-container"},[t("router-view")],1):e._e(),"Login"==e.$route.name?t("main",{staticClass:"main-containers"},[t("router-view")],1):e._e(),"Register"!==e.$route.name?t("Sidebar"):e._e(),"Register"!==e.$route.name?t("Footer"):e._e(),t("BackToTop")],1)},r=[],o=function(){var e=this,t=e._self._c;return t("header",{staticClass:"header-nav"},[t("div",{staticClass:"top-notice"},[t("div",{staticClass:"container"},[t("p",[e._v(" 欢迎来到时味苏州平台! "),e._e()],1),t("div",{staticClass:"top-links"},[e.isLogin?t("router-link",{staticClass:"user-link",attrs:{to:"/User"}},[t("img",{directives:[{name:"lazy",rawName:"v-lazy",value:e.userInfo.avatar,expression:"userInfo.avatar"}],staticClass:"avatar",attrs:{alt:"用户头像"}}),e._v(" "+e._s(e.userInfo.username)+" ")]):t("router-link",{attrs:{to:"/Login"}},[e._v("登录")]),e._e(),e._e(),t("router-link",{attrs:{to:"/User"}},[e._v("采购人中心")]),t("router-link",{staticClass:"cart-link",attrs:{to:"/User/ShoppingCart"}},[e._v(" 购物车"),e.cartTotalCount>0?t("span",[e._v("("+e._s(e.cartTotalCount)+"件)")]):e._e()]),e.isLogin?t("router-link",{attrs:{to:"/User/OrderList"}},[e._v("我的订单")]):e._e(),e.isLogin?t("div",{staticClass:"logout-btn",on:{click:e.handleLogout}},[e._v(" 退出 ")]):e._e()],1)])]),t("div",{staticClass:"main-nav"},[t("div",{staticClass:"container"},[t("div",{staticClass:"logo"},[t("router-link",{attrs:{to:"/"}},[t("img",{staticClass:"logo-img",attrs:{src:"https://static.ticket.sz-trip.com/shiweisuzhou/pc/logo.png",alt:"logo"}})])],1),t("div",{staticClass:"search-box"},[t("el-input",{staticClass:"search-input",attrs:{placeholder:"请输入搜索内容"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSearch.apply(null,arguments)}},model:{value:e.searchText,callback:function(t){e.searchText=t},expression:"searchText"}},[t("el-button",{attrs:{slot:"append",icon:"el-icon-search"},on:{click:e.handleSearch},slot:"append"})],1),t("div",{staticClass:"hot-tags"},[t("span",[e._v("热门搜索:")]),t("div",{staticClass:"hot-tag",on:{click:function(t){e.searchText="手机",e.handleSearch()}}},[e._v(" 手机 ")]),t("div",{staticClass:"hot-tag",on:{click:function(t){e.searchText="电脑",e.handleSearch()}}},[e._v(" 电脑 ")]),t("div",{staticClass:"hot-tag",on:{click:function(t){e.searchText="服装",e.handleSearch()}}},[e._v(" 服装 ")])])],1),t("div",{staticClass:"phone-entry"},[t("router-link",{attrs:{to:"#"}},[t("img",{attrs:{src:"https://static.ticket.sz-trip.com/shiweisuzhou/pc/login/phone.png",alt:"联系电话"}}),t("span",[e._v("0512-680541")]),(e.cartTotalCount,e._e())])],1)])]),e.categories.length>0?t("div",{staticClass:"category-nav"},[t("div",{staticClass:"container"},[e._e()])]):e._e()])},s=[],c=n(3518),l={name:"HeaderNav",data(){return{searchText:""}},computed:{...(0,c.L8)(["getCategories","getCartTotalCount","isUserLogin","getUserInfo"]),categories(){return this.getCategories||[]},cartTotalCount(){return this.getCartTotalCount||0},isLogin(){return this.isUserLogin},userInfo(){return this.getUserInfo||{}}},created(){this.fetchCategories()},methods:{...(0,c.i0)(["fetchCategories","logout"]),handleSearch(){if(!this.searchText.trim())return;this.$store.commit("setSearchText",this.searchText);const e="/ProductList"===this.$route.path&&"search"===this.$route.query.type;e?this.$emit("search",this.searchText):this.$router.push({path:"/ProductList",query:{keyword:this.searchText,type:"search"}})},handleLogout(){this.$confirm("确定要退出登录吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(()=>{this.logout().then(()=>{this.$message.success("退出登录成功"),this.$router.push("/Login")}).catch(e=>{this.$message.error("退出失败:"+(e.message||"未知错误"))})}).catch(()=>{})}}},u=l,d=n(1656),h=(0,d.A)(u,o,s,!1,null,"397f4a13",null),p=h.exports,m=function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-container"},[t("div",{staticClass:"footer-top"},[e._m(0),e._m(1),e._m(2),e._m(3),e._m(4),t("div",{staticClass:"qrcode-group"},[t("div",{staticClass:"qrcode-item"},[t("el-empty",{staticStyle:{width:"100px",height:"100px"},attrs:{description:"二维码"}}),t("p",[e._v("时味苏州小程序")])],1),t("div",{staticClass:"qrcode-item"},[t("el-empty",{staticStyle:{width:"100px",height:"100px"},attrs:{description:"二维码"}}),t("p",[e._v("时味苏州服务号")])],1)])]),e._m(5)])},f=[function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-column"},[t("h3",[e._v("关于我们")]),t("ul",[t("li",[e._v("平台简介")]),t("li",[e._v("政策文件")]),t("li",[e._v("平台标识指南")]),t("li",[e._v("营业执照")]),t("li",[e._v("食品经营许可证")])])])},function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-column"},[t("h3",[e._v("新手上路")]),t("ul",[t("li",[e._v("供应商入驻流程")]),t("li",[e._v("供应商操作手册")]),t("li",[e._v("采购人入驻流程")]),t("li",[e._v("采购人操作手册")]),t("li",[e._v("供应商入驻联系方式")])])])},function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-column"},[t("h3",[e._v("交易流程")]),t("ul",[t("li",[e._v("直购交易流程")]),t("li",[e._v("竞购交易流程")]),t("li",[e._v("货款结算流程")])])])},function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-column"},[t("h3",[e._v("常见问题")]),t("ul",[t("li",[e._v("预留份额填报")]),t("li",[e._v("支付结算问题")]),t("li",[e._v("账号管理问题")]),t("li",[e._v("在线客服问题")])])])},function(){var e=this,t=e._self._c;return t("div",{staticClass:"contact-info"},[t("p",[e._v("联系方式:")]),t("p",[e._v("客服电话:222-222-222")]),t("p",[e._v("工作时间:工作日 9:00-18:00")]),t("p",[e._v("客服邮箱:xxxxxxxxx@stn.com")]),t("p",[e._v("商务合作:18999999999")])])},function(){var e=this,t=e._self._c;return t("div",{staticClass:"footer-bottom"},[t("p",[e._v("版权所有 苏州市特色农产品发展有限公司 | 苏ICP备2023023300号-1")]),t("p",[e._v("本网站由 江苏大运远见文化科技发展有限公司 运营维护")])])}],g={name:"Footer",data(){return{}}},v=g,b=(0,d.A)(v,m,f,!1,null,"683e198c",null),C=b.exports,k=function(){var e=this,t=e._self._c;return t("div",{staticClass:"sidebar-container"},[t("div",{staticClass:"sidebar-item",on:{click:e.handleCartClick}},[t("el-badge",{staticClass:"item-badge",attrs:{value:e.cartCount}},[t("i",{staticClass:"el-icon-shopping-cart-full"})]),t("div",{staticClass:"item-text"},[e._v("购物车")])],1),t("div",{staticClass:"sidebar-item",on:{click:e.handleServiceClick}},[t("i",{staticClass:"el-icon-headset"}),t("div",{staticClass:"item-text"},[e._v("在线客服")])]),t("div",{staticClass:"sidebar-item back-to-top",class:{active:e.isShowBackTop},on:{click:e.handleBackToTop}},[t("i",{staticClass:"el-icon-caret-top"}),t("div",{staticClass:"item-text"},[e._v("回到顶部")])])])},y=[],T={name:"Sidebar",data(){return{cartCount:3,isShowBackTop:!1,scrollTimer:null}},mounted(){window.addEventListener("scroll",this.handleScroll)},beforeDestroy(){window.removeEventListener("scroll",this.handleScroll),this.scrollTimer&&clearTimeout(this.scrollTimer)},methods:{handleCartClick(){this.$router.push("/User/ShoppingCart")},handleServiceClick(){this.$message.info("正在唤起在线客服...")},handleBackToTop(){window.scrollTo({top:0,behavior:"smooth"})},handleScroll(){this.scrollTimer&&clearTimeout(this.scrollTimer),this.scrollTimer=setTimeout(()=>{this.isShowBackTop=window.pageYOffset>300},200)}}},A=T,I=(0,d.A)(A,k,y,!1,null,"0ddafffa",null),w=I.exports,R=function(){var e=this,t=e._self._c;return e.showBackToTop?t("div",{staticClass:"back-to-top",on:{click:e.scrollToTop}},[t("el-icon",{attrs:{name:"el-icon-arrow-up"}})],1):e._e()},x=[],E={name:"BackToTop",data(){return{showBackToTop:!1}},mounted(){window.addEventListener("scroll",this.handleScroll)},beforeDestroy(){window.removeEventListener("scroll",this.handleScroll)},methods:{handleScroll(){this.showBackToTop=window.pageYOffset>500},scrollToTop(){const e=window.setInterval(()=>{const t=window.pageYOffset;t>0?window.scrollTo(0,t-Math.max(20,t/10)):window.clearInterval(e)},16)}}},U=E,O=(0,d.A)(U,R,x,!1,null,"7ea6dee0",null),L=O.exports,P={name:"App",components:{HeaderNav:p,Footer:C,BackToTop:L,Sidebar:w},computed:{...(0,c.L8)(["getLoadingStatus"]),loading(){return this.getLoadingStatus}}},S=P,B=(0,d.A)(S,i,r,!1,null,null,null),N=B.exports,z=n(6178);a["default"].use(z.Ay);const Z=z.Ay.prototype.push;z.Ay.prototype.push=function(e){return Z.call(this,e).catch(e=>{if("NavigationDuplicated"!==e.name)throw e})};const G=new z.Ay({mode:"history",base:"/",routes:[{path:"/",name:"Index",meta:{title:"首页 - 精品商城",keepAlive:!1},component:()=>n.e(40).then(n.bind(n,5040))},{path:"/Login",name:"Login",meta:{title:"登录 - 精品商城",keepAlive:!1},component:()=>n.e(900).then(n.bind(n,900))},{path:"/Register",name:"Register",meta:{title:"注册 - 精品商城",keepAlive:!1},component:()=>n.e(29).then(n.bind(n,3029))},{path:"/Home",name:"Home",meta:{title:"首页 - 精品商城",keepAlive:!1},component:()=>n.e(828).then(n.bind(n,9828))},{path:"/Detail/:id",name:"Detail",meta:{title:"首页 - 精品商城",keepAlive:!1},component:()=>n.e(639).then(n.bind(n,4639))},{path:"/ProductList",name:"ProductList",meta:{title:"商品列表",keepAlive:!1},component:()=>n.e(4).then(n.bind(n,9004))},{path:"/User",name:"User",component:()=>n.e(110).then(n.bind(n,9110)),redirect:"/User/UserCenter",children:[{path:"UserCenter",name:"UserCenter",component:()=>n.e(64).then(n.bind(n,1064))},{path:"OrderList",name:"OrderList",meta:{title:"我的订单 - 精品商城",keepAlive:!1},component:()=>n.e(86).then(n.bind(n,3086))},{path:"UserInfo",name:"UserInfo",meta:{title:"个人信息 - 精品商城",keepAlive:!1},component:()=>n.e(893).then(n.bind(n,5893))},{path:"ViewHistory",name:"ViewHistory",meta:{title:"我的足迹 - 精品商城",keepAlive:!1},component:()=>n.e(33).then(n.bind(n,4033))},{path:"UserAddress",name:"UserAddress",meta:{title:"我的收货地址 - 精品商城",keepAlive:!1},component:()=>n.e(700).then(n.bind(n,700))},{path:"UserInvoice",name:"UserInvoice",meta:{title:"发票抬头 - 精品商城",keepAlive:!1},component:()=>n.e(113).then(n.bind(n,6113))},{path:"UserInvoiceList",name:"UserInvoiceList",meta:{title:"我的发票 - 精品商城",keepAlive:!1},component:()=>n.e(217).then(n.bind(n,8217))},{path:"ShoppingCart",name:"ShoppingCart",meta:{title:"购物车 - 精品商城",keepAlive:!1},component:()=>n.e(135).then(n.bind(n,2135))},{path:"CommentManage",name:"CommentManage",meta:{title:"评价管理 - 精品商城",keepAlive:!1},component:()=>n.e(592).then(n.bind(n,4592))},{path:"ContractList",name:"ContractList",meta:{title:"合同管理 - 精品商城",keepAlive:!1},component:()=>n.e(406).then(n.bind(n,3406))},{path:"MessageList",name:"MessageList",meta:{title:"消息中心 - 精品商城",keepAlive:!1},component:()=>n.e(838).then(n.bind(n,7838))},{path:"PurchaserAdd",name:"PurchaserAdd",meta:{title:"添加采购单位信息 - 精品商城",keepAlive:!1},component:()=>n.e(181).then(n.bind(n,6181))}]},{path:"/Order",name:"Order",meta:{title:"下单",keepAlive:!1},component:()=>n.e(143).then(n.bind(n,8524))},{path:"/OrderDetail",name:"OrderDetail",meta:{title:"订单详情 - 精品商城",keepAlive:!1},component:()=>n.e(241).then(n.bind(n,6241))},{path:"/OrderPay",name:"OrderPay",meta:{title:"订单支付 - 精品商城",keepAlive:!1},component:()=>n.e(677).then(n.bind(n,3677))},{path:"/OrderPayB2B",name:"OrderPayB2B",meta:{title:"订单支付 - 精品商城",keepAlive:!1},component:()=>n.e(452).then(n.bind(n,1452))},{path:"/OrderPayCode",name:"OrderPayCode",meta:{title:"订单支付 - 精品商城",keepAlive:!1},component:()=>n.e(244).then(n.bind(n,244))},{path:"/OrderPaySuccess",name:"OrderPaySuccess",meta:{title:"订单支付 - 精品商城",keepAlive:!1},component:()=>n.e(169).then(n.bind(n,7169))}],scrollBehavior(e,t,n){return{x:0,y:0}}});G.beforeEach((e,t,n)=>{if(e.meta.title&&(document.title=e.meta.title),e.meta.requireAuth){const t=localStorage.getItem("token");t?n():n({path:"/Login",query:{redirect:e.fullPath}})}else n()});var W=G,V=(n(8111),n(2489),n(116),n(8237),n(5131));a["default"].use(c.Ay);var Q=new c.Ay.Store({plugins:[(0,V.A)({storage:window.localStorage,reducer(e){return{cart:e.cart,user:e.user}}})],state:{cart:{items:[],totalCount:0,totalPrice:0},user:{isLogin:!1,info:null,token:""},categories:[],loading:!1,searchText:""},mutations:{UPDATE_CATEGORIES(e,t){e.categories=t},UPDATE_LOADING(e,t){e.loading=t},USER_LOGIN(e,{userInfo:t,token:n}){e.user.isLogin=!0,e.user.info=t,e.user.token=n,localStorage.setItem("token",n)},USER_LOGOUT(e){e.user.isLogin=!1,e.user.info=null,e.user.token="",localStorage.removeItem("token")},ADD_TO_CART(e,t){const n=e.cart.items.find(e=>e.id===t.id);n?n.quantity+=t.quantity||1:e.cart.items.push({...t,quantity:t.quantity||1}),this.commit("UPDATE_CART_TOTAL")},REMOVE_FROM_CART(e,t){e.cart.items=e.cart.items.filter(e=>e.id!==t),this.commit("UPDATE_CART_TOTAL")},UPDATE_CART_ITEM_QUANTITY(e,{productId:t,quantity:n}){const a=e.cart.items.find(e=>e.id===t);a&&(a.quantity=n,this.commit("UPDATE_CART_TOTAL"))},CLEAR_CART(e){e.cart.items=[],this.commit("UPDATE_CART_TOTAL")},UPDATE_CART_TOTAL(e){e.cart.totalCount=e.cart.items.reduce((e,t)=>e+t.quantity,0),e.cart.totalPrice=e.cart.items.reduce((e,t)=>e+t.price*t.quantity,0)},setSearchText(e,t){e.searchText=t}},actions:{fetchCategories({commit:e}){return e("UPDATE_LOADING",!0),new Promise(t=>{setTimeout(()=>{const n=[{id:1,name:"电子产品",icon:"el-icon-laptop"},{id:2,name:"服装鞋帽",icon:"el-icon-shopping-bag-1"},{id:3,name:"家居用品",icon:"el-icon-home"},{id:4,name:"美妆个护",icon:"el-icon-present"},{id:5,name:"食品饮料",icon:"el-icon-dish"},{id:6,name:"图书音像",icon:"el-icon-document"}];e("UPDATE_CATEGORIES",n),e("UPDATE_LOADING",!1),t(n)},500)})},logout({commit:e}){e("USER_LOGOUT")},addToCart({commit:e},t){e("ADD_TO_CART",t)},removeFromCart({commit:e},t){e("REMOVE_FROM_CART",t)},updateCartItemQuantity({commit:e},t){e("UPDATE_CART_ITEM_QUANTITY",t)},clearCart({commit:e}){e("CLEAR_CART")}},getters:{getCategories:e=>e.categories,getCart:e=>e.cart,getCartTotalCount:e=>e.cart.totalCount,getCartTotalPrice:e=>e.cart.totalPrice,isUserLogin:e=>e.user.isLogin,getUserInfo:e=>e.user.info,getLoadingStatus:e=>e.loading,getSearchText:e=>e.searchText}}),D=n(9143),M=n.n(D),Y=n(5847),J=n(4373);const j=J.A.create({timeout:6e3});j.interceptors.request.use(e=>{const{customBaseURL:t}=e.params||e.data||{};t?(e.baseURL=t,e.params?delete e.params.customBaseURL:e.data&&delete e.data.customBaseURL):e.baseURL="https://swsz.api.js-dyyj.com";const n=Q.state.user?.userInfo?.token||"";return e.headers["token"]=n||"745f2b4c-49b7-4393-bf58-bc380a87149a",e.headers["Content-Type"]="application/json;charset=UTF-8","get"===e.method?.toLowerCase()?e.params={platform_type:2,...e.params}:e.data={platform_type:2,...e.data},!1!==e.loading&&(e.loadingInstance=D.Loading.service({lock:!0,text:"加载中...",background:"rgba(0, 0, 0, 0.7)"})),e},e=>Promise.reject(e)),j.interceptors.response.use(e=>{if(e.config.loadingInstance&&e.config.loadingInstance.close(),200!==e.status&&1!==e.status){const t=`请求失败,状态码:${e.status}`;return D.MessageBox.alert(t,"错误提示",{confirmButtonText:"确定",type:"error"}),Promise.reject(new Error(t))}{const t=e.data;if(1===t.code||200===t.code)return t;{const e=t.msg||`业务处理失败,错误码:${t.code}`;D.MessageBox.alert(e,"错误提示",{confirmButtonText:"确定",type:"error"})}}},e=>{if(e.config&&e.config.loadingInstance&&e.config.loadingInstance.close(),e.response&&e.response.status)switch(e.response.status){case 401:D.MessageBox.confirm("请登录后操作","提示",{confirmButtonText:"去登录",cancelButtonText:"取消",type:"warning"}).then(()=>{}).catch(()=>{});break;case 404:(0,D.Message)({message:"网络繁忙,请刷新再试",type:"error",duration:2e3});break;default:(0,D.Message)({message:"网络繁忙,请刷新再试",type:"error",duration:2e3});break}return Promise.reject(e)}),a["default"].prototype.get=(e,t,n=!1)=>new Promise((a,i)=>{j.get(t,{params:e,loading:n}).then(e=>{a(e)}).catch(e=>{i(e)})}),a["default"].prototype.post=(e,t,n=!1)=>new Promise((a,i)=>{j.post(t,e,{loading:n}).then(e=>{a(e)}).catch(e=>{i(e)})});var _={install(e){e.prototype.util={formateRichText(e){if(!e)return"";var t=new RegExp("'),t=new RegExp("section","g"),e=e.replace(t,"div"),t=new RegExp("↵","g"),e=e.replace(t,"
"),e=e.replace(/