1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["other-page-template-1-template-1","other-page-ProductsListOnce-ProductsListOnce~other-page-ShowcaseGoodsList-ShowcaseGoodsList","other-page-CouponList-CouponList"],{"009f":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"goods-list"},[o("v-uni-view",{staticClass:"list-left",style:[t.categoryListWrapperStyle]},[o("v-uni-scroll-view",{staticClass:"scroll-view",attrs:{"scroll-y":!0}},[o("category-list",{attrs:{data:t.categoryList,"sticky-height":t.stickyDistance,height:t.height,avctColor:t.avctColor,categoryGoodsNum:t.categoryGoodsNum},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.handleCategoryChangeEvent.apply(void 0,arguments)}},model:{value:t.currentCategoryIndex,callback:function(e){t.currentCategoryIndex=e},expression:"currentCategoryIndex"}})],1)],1),o("v-uni-view",{staticClass:"list-right"},[t.showConpon&&t.couponNum>0?o("coupon-list",{attrs:{"coupon-num":t.couponNum,"coupon-money":t.couponMoney},on:{subCoupon:function(e){arguments[0]=e=t.$handleEvent(e),t.changCoupon.apply(void 0,arguments)}}}):t._e(),o("products-list-once",{attrs:{currentCategoryIndex:t.currentCategoryIndex,data:t.goodsList,goods:t.goods,"sticky-height":t.stickyDistance,sid:t.sid,"spellrice-id":t.spellriceId,"table-id":t.tableId,"is-rest":t.isRest,paddingtop:t.paddingtop,delivery_type:t.delivery_type,avctColor:t.avctColor,showloadStatu:t.showload,showloadStatu2:t.showloadNext,showloadStatu3:t.showloadNext1,is_renovate:t.is_renovate,showloadNext2:t.showloadNext2,is_top:t.is_top,brand:t.brand,navbarHeight:t.navbarHeight,navType:t.navType,refreshCategoryTitleRectInfo:t.refreshCategoryTitleRectInfo},on:{onR:function(e){arguments[0]=e=t.$handleEvent(e),t.onR.apply(void 0,arguments)},"init-finish":function(e){arguments[0]=e=t.$handleEvent(e),t.handleProductListInitFinishEvent.apply(void 0,arguments)},"good-num-change":function(e){arguments[0]=e=t.$handleEvent(e),t.handleProductListGoodNumChangeEvent.apply(void 0,arguments)},"category-next":function(e){arguments[0]=e=t.$handleEvent(e),t.handleCategoryNextEvent.apply(void 0,arguments)},"category-top":function(e){arguments[0]=e=t.$handleEvent(e),t.handleCategoryTopEvent.apply(void 0,arguments)},"chang-tabs":function(e){arguments[0]=e=t.$handleEvent(e),t.changTabs.apply(void 0,arguments)}}})],1)],1)},n=[]},"027c":function(t,e,o){"use strict";var i=o("d0c5"),n=o.n(i);n.a},"033a":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.AddMerchandise=u,e.Editcategory=b,e.RenderQueue=l,e.changeGoodsSort=w,e.default=void 0,e.delCategory=I,e.deleteGoods=f,e.displayorder=C,e.editCategorySub=y,e.editGoodsDisplayorder=g,e.editGoodsHot=m,e.editGoodsStuta=h,e.editGoodsSub=p,e.editGoodsTotal=v,e.editGoodsTruncate=_,e.getDefaultDisplaySelection=D,e.goodsList=r,e.goodsListNoLoginApi=N,e.importCloudGoods=T,e.onChangeStatus=c,e.searchCloudGoods=S,e.searchGoodsImageByName=x,e.turnNotify=d,e.updateDefaultDisplaySelection=k,e.waitingList=s;var n=i(o("9b1b")),a=i(o("5b42"));function r(t){return a.default.get("api/manage.goods.goods/list",{params:t})}function s(t,e){return util.request((0,n.default)({method:"get",url:"manage/tangshi/assign/index",data:t},e))}function d(t,e){return util.request((0,n.default)({method:"post",url:"manage/tangshi/assign/status",data:t},e))}function c(t,e){return util.request((0,n.default)({method:"post",url:"manage/tangshi/assign/status",data:t},e))}function l(t,e){return util.request((0,n.default)({method:"post",url:"manage/tangshi/assign/queue_post",data:t},e))}function u(t){return a.default.get("api/manage.goods.goods/editDetail",{params:t})}function p(t){return a.default.post("api/manage.goods.goods/edit",t)}function f(t){return a.default.get("api/manage.goods.goods/delete",{params:t})}function h(t){return a.default.post("api/manage.goods.goods/status",t)}function g(t){return a.default.post("api/manage.goods.goods/displayorder",t)}function v(t){return a.default.post("api/manage.goods.goods/total",t)}function m(t){return a.default.post("api/manage.goods.goods/hot",t)}function _(t){return a.default.post("api/manage.goods.goods/truncate",t)}function b(t){return a.default.get("api/manage.goods.category/editDetail",{params:t})}function y(t){return a.default.post("api/manage.goods.category/edit",t)}function I(t){return a.default.get("api/manage.goods.category/delete",{params:t})}function C(t){return a.default.post("api/manage.goods.category/displayorders",t)}function w(t){return a.default.post("api/manage.goods.goods/changeGoodsSort",t)}function x(t){return a.default.post("api/manage.goods.goods/searchGoodsImageByName",t)}function S(t){return a.default.post("api/manage.goods.goods/searchCloudGoods",t)}function T(t){return a.default.post("api/manage.goods.goods/importCloudGoods",t)}function k(t){return a.default.post("api/manage.shop.config/updateDefaultDisplaySelection",t)}function D(t){return a.default.get("api/manage.shop.config/getDefaultDisplaySelection",{params:t})}function N(t){return a.default.get("api/manage.goods.goods/listNoLogin",{params:t})}var E={delCategory:I,editCategorySub:y,deleteGoods:f,editGoodsTruncate:_,editGoodsStuta:h,editGoodsSub:p,goodsList:r,waitingList:s,turnNotify:d,onChangeStatus:c,RenderQueue:l,AddMerchandise:u,Editcategory:b,displayorder:C,changeGoodsSort:w,searchGoodsImageByName:x,searchCloudGoods:S,importCloudGoods:T,updateDefaultDisplaySelection:k,getDefaultDisplaySelection:D,editGoodsDisplayorder:g,editGoodsTotal:v,editGoodsHot:m,goodsListNoLoginApi:N};e.default=E},"05a0":function(t,e,o){"use strict";o.r(e);var i=o("2407"),n=o("20df");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("fcaf");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"3d4bd26f",null,!1,i["a"],void 0);e["default"]=s.exports},"06e0":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa"),o("fd3c"),o("d4b5"),o("c223"),o("795c"),o("c9b5"),o("bf0f"),o("ab80"),o("aa9c"),o("3efd"),o("8f71"),o("e838"),o("5c47"),o("a1c1"),o("4626"),o("5ac7"),o("01a2"),o("e39c"),o("f3f7"),o("18f7"),o("de6c");var n=i(o("a66a")),a=i(o("e4cc")),r=i(o("35a4")),s=o("eda6"),d=(o("47da"),{props:{data:{type:Array,default:function(){return[]}},showloadNext:{type:Boolean,default:!1},showloadNext1:{type:Boolean,default:!1},storeData:{type:[Object,Boolean,Array],default:!1},pageShowType:{type:[Number,String],default:1},avctColor:{type:String,default:""},stickyDistance:{type:Number,default:0},height:{type:Number,default:0},navbarHeight:{type:Number,default:0},sid:{type:[String,Number],default:""},searchComdId:{type:[String,Number],default:""},spellriceId:{type:[String,Number],default:""},tableId:{type:[String,Number],default:""},isRest:{type:Boolean,default:!1},categoryIndex:{type:[String,Number],default:0},delivery_type:{type:Number},isReachBottom:{type:Boolean,default:!1},is_renovate:{type:Boolean,default:!1},is_top:{type:Boolean,default:!1},isNextCategory:{type:Boolean,default:!1},paddingtop:{type:Boolean,default:!1},navType:{type:String,default:""},storeShow:{type:Object,default:function(){return{}}},brand:{type:String,default:""},default_display_selection:{type:Number},categoryGoodsNum:{type:Array,default:function(){return[]}},refreshCategoryTitleRectInfo:{type:Boolean,default:!1},goods:{type:Array,default:function(){return[]}}},components:{CategoryList:n.default,ProductsListOnce:a.default,CouponList:r.default},data:function(){return{isClick:!1,categoryList:[],goodsList:[],currentCategoryIndex:0,oldCategoryIndex:0,scrollTopInfo:[],showConpon:!1,nextCategory:!1,count:0,showload:!1,showloadNext2:!1}},computed:{categoryListWrapperStyle:function(){var t={};return t.top="".concat(this.stickyDistance,"px"),t.height="".concat(this.height,"px"),console.log("style.height",t.height),t},couponNum:function(){var t;return null===(t=this.storeData.coupons)||void 0===t?void 0:t.length},couponMoney:function(){var t;return null===(t=this.storeData)||void 0===t?void 0:t.price},showCon:function(){this.storeData&&(this.showConpon=!0)}},watch:{data:{handler:function(t,e){(t&&t.length>0||e&&e.length>0)&&this._splitData(t)},immediate:!0,deep:!0},categoryIndex:{handler:function(t,e){uni.pageScrollTo({scrollTop:0,duration:0}),this.currentCategoryIndex=t,this.oldCategoryIndex=e}},stickyDistance:{handler:function(t,e){console.log(t,e)},immediate:!0}},methods:{onR:function(){this.$emit("onReachBottom")},handleCategoryNextEvent:function(t){var e=this;if(this.isReachBottom)if(this.isNextCategory&&(this.nextCategory=!0),this.currentCategoryIndex>=this.categoryList.length-1)console.log("已经是最后一个分类,不再切换");else if(this.nextCategory=!this.nextCategory,!(t>15&&this.nextCategory)){this.showload=!0;var o=setTimeout((function(){e.currentCategoryIndex+=1,e.$emit("category-change",e.categoryList[e.currentCategoryIndex].id,e.currentCategoryIndex),e.nextCategory=!1,e.showload=!1,clearTimeout(o)}),500)}},handleCategoryTopEvent:function(t){var e=this;this.is_top&&this.currentCategoryIndex>0&&(this.showloadNext2=!0,this.currentCategoryIndex-=1,this.$emit("category-change",this.categoryList[this.currentCategoryIndex].id,this.currentCategoryIndex)),setTimeout((function(){e.showloadNext2=!1}),500)},handRequireCategoryEvent:function(t){t>=0&&(this.handleProductListUpdateCategoryIndexEvent(t),this.handleCategoryChangeEvent(t))},handleProductListUpdateCategoryIndexEvent:function(t){this.currentCategoryIndex=t},changTabs:function(t,e){this.$emit("changTabsId",t,e)},handleProductListInitFinishEvent:function(t){var e=this;this.scrollTopInfo=t.map((function(t){return t-e.stickyDistance})),this.$nextTick((function(){e.$emit("render-finish")}))},handleProductListGoodNumChangeEvent:function(t){this.$emit("good-num-change",t)},handleCategoryChangeEvent:function(t,e){var o=this;this.isClick=!0;var i=1===this.pageShowType?t:0;uni.pageScrollTo({scrollTop:this.scrollTopInfo[i],duration:0}),2===this.pageShowType&&(this.currentCategoryIndex=t,this.$emit("category-change",this.categoryList[this.currentCategoryIndex].id,t)),3===this.pageShowType&&(console.log("切换"),this.$emit("category-change",this.categoryList[this.currentCategoryIndex].id,t,this.pageShowType)),setTimeout((function(){o.isClick=!1}),150)},_splitData:function(t){var e=JSON.parse(JSON.stringify(t)),o=new Date,i=0===o.getDay()?7:o.getDay(),n=+"".concat(o.getHours().toString().padStart(2,"0"),".").concat(o.getMinutes().toString().padStart(2,"0"));if(this.searchComdId&&1==this.pageShowType)t:for(var a=0;a<e.length;a++)for(var r=0;r<e[a].goods.length;r++)if(e[a].goods[r].id==this.searchComdId){var s=[];s.push(e[a].goods[r]),e.unshift({category_min_fee:"",description:"",goods:s,id:-1,is_mandatory:0,thumb:"https://qny.wdsp666.com/%E7%A6%8F%E8%A2%8B%E8%83%8C%E6%99%AF%E5%9B%BE/xcx/search.png",title:"刚刚搜索"});break t}this.categoryList=e.map((function(t){var e=!1;if(1===t.is_showtime){var o=parseFloat(t.start_time.replace(":",".")),a=parseFloat(t.end_time.replace(":",".")),r=t.week.split(",");console.log("时间数据当前星期几和时间 ",i,n,"开始结束时间",o,a),r.includes(String(i))&&n>=o&&n<=a&&(e=!0)}else e=!0;return e?{id:t.id,title:t.title,thumb:t.thumb,is_mandatory:t.is_mandatory,description:t.description,is_showtime:t.is_showtime,week:t.week,start_time:t.start_time,end_time:t.end_time}:null})).filter((function(t){return null!==t}));var d=new Set(this.categoryList.map((function(t){return t.id})));this.goodsList=e.filter((function(t){return d.has(t.id)})),console.log("this.goodsList",this.goodsList),console.log("对对对对对对对对",this.categoryList),console.log("好好好好好好",this.categoryGoodsNum)},changCoupon:function(){var t=this;(0,s.postStoreCouponApi)({sid:this.storeData.sid}).then((function(e){uni.showToast({title:"领取成功",icon:"none"}),t.showConpon=!1}))},handleSearchPromotion:function(t){this.$emit("searchPromotion",t)}}});e.default=d},"06f9":function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.createQuery=void 0;e.createQuery=function(t){var e=uni.createSelectorQuery().in(t);return e}},"0c8e":function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.setUserInfoToCache=e.setUserAddressAuthMin=e.setTokenToCache=e.setTangshiInfoDataToCache=e.setSubmitOrderChooseAddressId=e.setLocationInfoToCache=e.setKeywordToUserHistorySearchCache=e.setCopyRightCache=e.getUserInfoFromCache=e.getUserHistorySearchCacheData=e.getTokenFromCache=e.getTangshiCacheInfoData=e.getSubmitOrderChooseAddressId=e.getLocationInfoFromCache=e.getCopyRightCache=e.clearUserHistorySearchData=e.clearTangshiCacheInfoData=e.clearSubmitOrderChooseAddressId=e.clearCacheUserInfo=e.clearCacheToken=e.clearCacheLocationInfo=void 0,o("e966"),o("4626"),o("5ac7"),o("3efd");var i=o("8729"),n=o("edc8");e.setTokenToCache=function(t){(0,i.setCache)(n.TOKEN_KEY,t)};e.getTokenFromCache=function(){return(0,i.getCache)(n.TOKEN_KEY)};e.clearCacheToken=function(){(0,i.removeCache)(n.TOKEN_KEY)};e.setUserInfoToCache=function(t){var e=(0,i.getCache)(n.USER_INFO);e||(e={}),(0,i.setCache)(n.USER_INFO,Object.assign(e,t))};e.getUserInfoFromCache=function(){return(0,i.getCache)(n.USER_INFO)};e.clearCacheUserInfo=function(){(0,i.removeCache)(n.USER_INFO)};e.setLocationInfoToCache=function(t){var e=t.lat,o=t.lng,a=t.address,r=(0,i.getCache)(n.LOCATION_INFO);r||(r={});var s=0,d=(0,i.getCache)("user_address_auth_min")||0;d=parseInt(d),d&&(s=(new Date).getTime()+60*d*1e3),r.lat=e||0,r.lng=o||0,r.address=a||"",r.expireTime=s,(0,i.setCache)(n.LOCATION_INFO,r)};e.getLocationInfoFromCache=function(){var t=(0,i.getCache)(n.LOCATION_INFO);return t||(t={lat:1,lng:1,address:""}),t};e.clearCacheLocationInfo=function(){(0,i.removeCache)(n.LOCATION_INFO)};e.setSubmitOrderChooseAddressId=function(t){(0,i.setCache)(n.ORDER_ADDRESS_CHOOSE_ID,t)};e.getSubmitOrderChooseAddressId=function(){return(0,i.getCache)(n.ORDER_ADDRESS_CHOOSE_ID)};e.clearSubmitOrderChooseAddressId=function(){(0,i.removeCache)(n.ORDER_ADDRESS_CHOOSE_ID)};e.getUserHistorySearchCacheData=function(){return(0,i.getCache)(n.USER_SEARCH_HISTORY)||[]};e.setKeywordToUserHistorySearchCache=function(t){var e=(0,i.getCache)(n.USER_SEARCH_HISTORY);e||(e=[]),e.includes(t)||(e.length>=10&&e.pop(),e.unshift(t),(0,i.setCache)(n.USER_SEARCH_HISTORY,e))};e.clearUserHistorySearchData=function(){(0,i.removeCache)(n.USER_SEARCH_HISTORY)};var a=function(){var t=(0,i.getCache)(n.TANGSHI_INFO);return t||{status:!1,sid:0,tableId:0}};e.getTangshiCacheInfoData=a;e.setTangshiInfoDataToCache=function(t,e,o){var r=a();r.status=t,r.sid=e||r.sid,r.tableId=o||r.tableId,(0,i.setCache)(n.TANGSHI_INFO,r)};e.clearTangshiCacheInfoData=function(){(0,i.removeCache)(n.TANGSHI_INFO)};e.setCopyRightCache=function(t){(0,i.setCache)("copyright",t)};e.getCopyRightCache=function(t){return(0,i.getCache)("copyright")};e.setUserAddressAuthMin=function(t){(0,i.setCache)("user_address_auth_min",t)}},"13d2":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.tn-badge[data-v-5ef10296]{width:auto;height:auto;box-sizing:border-box;display:flex;align-items:center;justify-content:center;z-index:10;font-size:%?20?%;background-color:#fff;border-radius:%?100?%;padding:%?4?% %?8?%;line-height:normal}.tn-badge--dot[data-v-5ef10296]{width:%?8?%;height:%?8?%;border-radius:50%;padding:0}.tn-badge--absolute[data-v-5ef10296]{position:absolute;top:0;right:0}.tn-badge--center-position[data-v-5ef10296]{-webkit-transform:translate(50%,-50%);transform:translate(50%,-50%)}',""]),t.exports=e},1557:function(t,e,o){var i=o("7762");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("516f0b95",i,!0,{sourceMap:!1,shadowMode:!1})},"1bf8":function(t,e,o){"use strict";o.r(e);var i=o("9a20"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"1ee6":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"tn-badge-class tn-badge",class:[t.backgroundColorClass,t.fontColorClass,t.badgeClass],style:[t.badgeStyle],on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.handleClick.apply(void 0,arguments)}}},[t.dot?t._e():t._t("default")],2)},n=[]},"204c":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa"),o("5c47"),o("473f"),o("bf0f"),o("aa77");var n=i(o("7dcc")),a=o("06f9"),r={props:{value:{type:Number,default:0},data:{type:Array,default:[]},avctColor:{type:String,default:""},stickyHeight:{type:Number,default:0},height:{type:Number,default:0},categoryGoodsNum:{type:Array,default:function(){return[]}}},mixins:[n.default],data:function(){return{currentSelectIndex:0,id:"",bottomEmptyAreaRectInfo:{height:0},initRectCount:0}},computed:{itemStyle:function(){var t=this;return function(e){var o={};if(e!=t.currentSelectIndex){var i=t.data.length;e<i&&e===t.currentSelectIndex+1&&(o.borderTopRightRadius="15rpx"),e>=0&&e===t.currentSelectIndex-1&&(o.borderBottomRightRadius="15rpx")}return o}}},watch:{value:{handler:function(t){this.currentSelectIndex=t},immediate:!0},data:{handler:function(t){var e=this;t&&t.length>0&&this.stickyHeight&&setTimeout((function(){e._initBottomEmptyAreaRectInfo()}),150)},immediate:!0}},created:function(){this.id=this.$t.uuid()},methods:{categoryClickEvent:function(t){console.log("🚀 ~ categoryClickEvent ~ index:",t),t!==this.currentSelectIndex&&(this.$emit("input",t),this.$emit("change",t,this.currentSelectIndex),console.log("钱钱钱钱钱钱钱",this.categoryGoodsNum))},_initBottomEmptyAreaRectInfo:function(){var t=this;if(this.height){var e=(0,a.createQuery)(this);e.selectAll("#item-".concat(this.id)).boundingClientRect((function(e){if(!e||0===e.length)return t.initRectCount>10?console.error("[showcaseGoodsList-categoryList]获取标题容器信息失败"):void setTimeout((function(){t._initBottomEmptyAreaRectInfo(),t.initRectCount++}),150);t.initRectCount=0;var o=e.reduce((function(t,e){return t+e.height}),0),i=t.height-o;t.bottomEmptyAreaRectInfo.height=i<0?100:i})).exec()}else setTimeout((function(){t._initBottomEmptyAreaRectInfo()}))},getCategoryGoodsNum:function(t){var e=this.categoryGoodsNum.find((function(e){return e.cid===t}));return e?e.num:null}}};e.default=r},"20df":function(t,e,o){"use strict";o.r(e);var i=o("cfdc"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"220b":function(t,e,o){var i=o("3ebb");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("81ae11f6",i,!0,{sourceMap:!1,shadowMode:!1})},2407:function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticStyle:{width:"100%",height:"auto","max-height":"100vh"}},[o("v-uni-view",{class:3!=t.pageShowType?"shopping-cart":"shopping-cart2"},[t.isRest?[t.is_loaded?o("div",{staticClass:"cart-is_rest tn-flex-center theme-cart-btn-rest"},[t._v("门店已打烊...")]):o("div",{staticClass:"cart-is_rest tn-flex-center theme-cart-btn-rest"},[t._v("正在加载中...")])]:[o("v-uni-view",{staticClass:"cart-info theme-cart-info",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.handleClickInfoEvent.apply(void 0,arguments)}}},[o("v-uni-view",{staticClass:"cart-icon"},[3!=t.pageShowType?o("v-uni-text",{staticClass:"tn-icon-cart"}):t._e(),3==t.pageShowType?o("v-uni-view",{staticClass:"icon"},[o("v-uni-text",{staticClass:"tn-icon-cart",staticStyle:{position:"absolute"}}),o("v-uni-image",{staticStyle:{width:"56rpx",height:"56rpx"},attrs:{src:t.shop_image,mode:"widthFix"}})],1):t._e(),t.totalNum>0?o("v-uni-view",{staticClass:"cart-good-num tn-flex-center theme-cart-num"},[t._v(t._s(t.totalNum))]):t._e()],1),o("v-uni-view",{staticClass:"cart-price"},[o("v-uni-view",{staticClass:"product-price"},[o("v-uni-view",{staticClass:"price theme-cart-info-price"},[o("v-uni-view",{staticClass:"unit"},[t._v("RM")]),o("v-uni-view",{staticClass:"value"},[t._v(t._s(t.totalPrice))])],1),t.oldTotalPrice&&3!=t.pageShowType?o("v-uni-view",{staticClass:"price old tn-color-gray theme-cart-info-oldprice"},[o("v-uni-view",{staticClass:"unit"},[t._v("RM")]),o("v-uni-view",{staticClass:"value"},[t._v(t._s(t.oldTotalPrice))])],1):t._e()],1),3!=t.pageShowType?o("v-uni-view",[0==t.multiple_cart?o("v-uni-view",{staticClass:"delivery-price theme-cart-info-delivery-price",staticStyle:{"align-items":"center"}},[t._v("预估配送费"),t.deliveryPrice&&t.deliveryPrice.start_fee>=0?o("v-uni-text",{staticClass:"price"},[t._v("RM"+t._s(t.deliveryPrice.start_fee))]):t.deliveryPrice?o("v-uni-text",{staticClass:"price"},[t._v("RM"+t._s(t.deliveryPrice))]):t._e()],1):o("v-uni-view",{staticClass:"delivery-price theme-cart-info-delivery-price",staticStyle:{"align-items":"center"}},[t._v("预估配送费"),t.deliveryPrice&&t.deliveryPrice.start_fee>=0?o("v-uni-text",{staticClass:"price"},[t._v("RM"+t._s(t.deliveryPrice.start_fee))]):t.deliveryPrice?o("v-uni-text",{staticClass:"price"},[t._v("RM"+t._s(t.multiple_cart_delivery_price))]):t._e()],1)],1):o("v-uni-view",[o("v-uni-view",{staticClass:"delivery-price theme-cart-info-delivery-price",staticStyle:{"align-items":"center"}},[t._v("已省 "+t._s(t.CurrencyUnit)+t._s(t.oldTotalPrice-t.totalPrice))])],1)],1)],1),3!=t.pageShowType?o("v-uni-view",{staticClass:"operation-btn tn-flex-center theme-cart-btn-avcti",class:[{"theme-cart-btn":!t.isToSubmit}],style:[t.themeBtnStyle],on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.handleSubmitEvent.apply(void 0,arguments)}}},[t._v(t._s(t.cidMinPrice?t.cidMinPriceText:t.submitBtnTipText))]):t._e(),3==t.pageShowType?o("v-uni-view",{staticClass:"operation-btn"},[2==t.deliveryType||3==t.deliveryType?o("v-uni-view",{staticClass:"left",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.handleSubmitEvent.apply(void 0,arguments)}}},[o("v-uni-text",[t._v("团购")]),o("v-uni-text",[t._v("下单到店")])],1):t._e(),1==t.deliveryType?o("v-uni-view",{staticClass:"left disabled"},[o("v-uni-text",[t._v("团购")]),o("v-uni-text",[t._v("当前不支持")])],1):t._e(),1==t.deliveryType||3==t.deliveryType?o("v-uni-view",{staticClass:"right",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.handleSubmitEvent.apply(void 0,arguments)}}},[o("v-uni-text",[t._v("配送")]),o("v-uni-text",[t._v(t._s(t.cidMinPrice?t.cidMinPriceText:t.submitBtnTipText))])],1):t._e(),2==t.deliveryType?o("v-uni-view",{staticClass:"left disabled"},[o("v-uni-text",[t._v("配送")]),o("v-uni-text",[t._v("当前不支持")])],1):t._e()],1):t._e()]],2),o("bottom-modal",{attrs:{"close-btn":!1,"z-index":99997,"no-padding":!0},model:{value:t.showProductList,callback:function(e){t.showProductList=e},expression:"showProductList"}},[0==t.multiple_cart?o("v-uni-view",{staticClass:"product-list__top-operation tn-flex-center-between",staticStyle:{"background-color":"#f8f7f8"}},[o("v-uni-view",{staticClass:"package-price"},[t._v("包装费RM"+t._s(t.shoppingCartData.boxPrice))]),t.shoppingCartData.discount_by_num_id>0&&t.shoppingCartData.discount_by_num_price>0?o("v-uni-view",[t._v("活动立减"+t._s(t.CurrencyUnit)+t._s(t.shoppingCartData.discount_by_num_price))]):t._e(),o("v-uni-view",{staticClass:"operation-clear",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.clearStoreShoppingCart.apply(void 0,arguments)}}},[o("v-uni-text",{staticClass:"tn-icon-delete"}),t._v("清空购物车")],1)],1):t._e(),0==t.multiple_cart?o("v-uni-view",{staticClass:"product-list__content"},[o("v-uni-scroll-view",{staticClass:"scroll-view",attrs:{"scroll-y":!0}},t._l(t.shoppingCartData.data,(function(e,i){return o("v-uni-view",{key:i,staticClass:"product-item"},[o("v-uni-view",{staticClass:"item-image"},[o("v-uni-image",{staticClass:"image",staticStyle:{width:"100rpx",height:"100rpx","border-radius":"inherit"},attrs:{src:e.image,mode:"aspectFill"}})],1),o("v-uni-view",{staticClass:"item-info"},[o("v-uni-view",{staticClass:"item-title tn-full-width tn-text-ellipsis-1"},["bargain"==e.bargain_type?o("v-uni-text",{staticClass:"red-box"},[t._v("含特价")]):t._e(),t._v(t._s(e.title))],1),o("v-uni-view",{staticClass:"item-spec"},[t._v(t._s(e.spec))]),o("v-uni-view",{staticClass:"item-operation"},[o("v-uni-view",{staticClass:"item-price tn-color-red"},["bargain"==e.bargain_type&&e.caigou_discount_price!=e.price?o("v-uni-text",[t._v("RM"+t._s(e.caigou_discount_price.toFixed(2))),e.discount_num>0?o("v-uni-text",{staticStyle:{"margin-left":"5rpx","font-size":"18rpx"}},[t._v("(第"+t._s(e.discount_num)+"个开始恢复原价)")]):t._e()],1):o("v-uni-text",[t._v("RM"+t._s(e.price.toFixed(2)))])],1),o("product-spec-number-box",{attrs:{"operation-from":"shoppingCart",type:0,sid:t.sid,"table-id":t.tableId,"spellrice-id":t.spellriceId,"good-id":e.goodId,"option-id":e.optionId,disabled:t.isRest},on:{"reduce-num":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodNumChangeEvent(e,"-",i)},"add-num":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodNumChangeEvent(e,"+",i)}},model:{value:e.num,callback:function(o){t.$set(e,"num",o)},expression:"item.num"}})],1)],1)],1)})),1)],1):t._e(),1==t.multiple_cart?o("v-uni-view",{staticClass:"product-list__content"},[o("v-uni-scroll-view",{staticClass:"scroll-view",attrs:{"scroll-y":!0}},t._l(t.multipleShoppingCartData,(function(e,i){return o("v-uni-view",{key:i},[o("v-uni-view",{staticClass:"store-title",staticStyle:{display:"flex","justify-content":"space-between"}},[o("v-uni-view",[o("v-uni-text",{staticStyle:{"font-weight":"bolder"}},[t._v(t._s(e.store_title))]),o("v-uni-text",{staticStyle:{"margin-left":"20rpx"}},[t._v("包装费RM"+t._s(e.boxPrice))])],1),o("v-uni-view",[o("v-uni-checkbox-group",[o("v-uni-checkbox",{attrs:{checked:e.checked},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.handleStoreCheckedChangeEvent(i)}},model:{value:e.checked,callback:function(o){t.$set(e,"checked",o)},expression:"i.checked"}})],1)],1)],1),t._l(e.data,(function(i,n){return o("v-uni-view",{key:n,staticClass:"product-item"},[o("v-uni-view",{staticClass:"item-image"},[o("v-uni-image",{staticClass:"image",staticStyle:{width:"100rpx",height:"100rpx","border-radius":"inherit"},attrs:{src:i.image,mode:"aspectFill"}})],1),o("v-uni-view",{staticClass:"item-info"},[o("v-uni-view",{staticClass:"item-title tn-full-width tn-text-ellipsis-1"},[t._v(t._s(i.title))]),o("v-uni-view",{staticClass:"item-spec"},[t._v(t._s(i.spec))]),o("v-uni-view",{staticClass:"item-operation"},[o("v-uni-view",{staticClass:"item-price tn-color-red"},[t._v("RM"+t._s(i.price.toFixed(2)))]),o("product-spec-number-box",{attrs:{"operation-from":"shoppingCart",type:0,sid:e.sid,"table-id":t.tableId,"spellrice-id":t.spellriceId,"good-id":i.goodId,"option-id":i.optionId,disabled:t.isRest},on:{"reduce-num":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodNumChangeEvent(e,"-",n)},"add-num":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodNumChangeEvent(e,"+",n)}},model:{value:i.num,callback:function(e){t.$set(i,"num",e)},expression:"item.num"}})],1)],1)],1)}))],2)})),1)],1):t._e(),o("v-uni-view",{staticClass:"product-list__bottom-empty"})],1)],1)},n=[]},"27e2c":function(t,e,o){var i=o("af6d");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("39c713e8",i,!0,{sourceMap:!1,shadowMode:!1})},"285f":function(t,e,o){var i=o("5d89");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("c55f153e",i,!0,{sourceMap:!1,shadowMode:!1})},"2baa":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.bottom-modal[data-v-7cd1a66a]{position:fixed;left:0;top:0;width:100vw;height:100vh;z-index:99998\n /* mask */\n /* close-btn */\n /* wrapper */}.bottom-modal__mask[data-v-7cd1a66a]{position:absolute;left:0;top:0;width:100%;height:100%;background-color:rgba(0,0,0,.5);opacity:0;-webkit-animation:showMask-data-v-7cd1a66a .25s ease .1s forwards;animation:showMask-data-v-7cd1a66a .25s ease .1s forwards}.bottom-modal__mask.transparent[data-v-7cd1a66a]{background-color:transparent}.bottom-modal__close-btn[data-v-7cd1a66a]{position:absolute;top:%?30?%;right:%?30?%;z-index:99999}.bottom-modal__wrapper[data-v-7cd1a66a]{position:absolute;left:0;bottom:0;width:100%;background-color:#fff;border-radius:%?20?% %?20?% %?0?% %?0?%;padding:%?40?%;padding-top:%?60?%;padding-bottom:%?40?%;padding-bottom:calc(constant(safe-area-inset-bottom) + %?40?%);padding-bottom:calc(env(safe-area-inset-bottom) + %?40?%);-webkit-transform-origin:center bottom;transform-origin:center bottom;-webkit-transform:scaleY(0);transform:scaleY(0);-webkit-animation:showWrapper-data-v-7cd1a66a .25s ease .1s forwards;animation:showWrapper-data-v-7cd1a66a .25s ease .1s forwards;z-index:99999;overflow:hidden}.bottom-modal__wrapper.no-padding[data-v-7cd1a66a]{padding:%?0?%;padding-bottom:%?40?%;padding-bottom:calc(constant(safe-area-inset-bottom) + %?40?%);padding-bottom:calc(env(safe-area-inset-bottom) + %?40?%)}@-webkit-keyframes showMask-data-v-7cd1a66a{0%{opacity:0}100%{opacity:1}}@keyframes showMask-data-v-7cd1a66a{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes showWrapper-data-v-7cd1a66a{0%{-webkit-transform:scaleY(0);transform:scaleY(0)}100%{-webkit-transform:scaleY(1);transform:scaleY(1)}}@keyframes showWrapper-data-v-7cd1a66a{0%{-webkit-transform:scaleY(0);transform:scaleY(0)}100%{-webkit-transform:scaleY(1);transform:scaleY(1)}}',""]),t.exports=e},"2d34":function(t,e){t.exports={data:function(){return{navBarInfo:{height:0,statusHeight:0},windowsOperationHeight:0,boundingInfo:{width:0,height:32,top:0,left:0,bottom:0,right:0}}},computed:{navBarStyle:function(){var t={};return t.height=this.navBarInfo.height+"px",this.$emit("getNavBarInfoHeight",this.navBarInfo.height),t},navbarContentStyle:function(){var t={},e=0;return e=this.boundingInfo.top?this.boundingInfo.top:(this.navBarInfo.height-this.boundingInfo.height)/2,t.height=this.boundingInfo.height+"px",t.top=e+"px",t},navbarTopStyle:function(){var t={},e=0;return e=this.boundingInfo.top?this.boundingInfo.top:(this.navBarInfo.height-this.boundingInfo.height)/2,t.top=e+"px",t},pageWrapperStyle:function(){return{top:"".concat(this.navBarInfo.height,"px")}}},methods:{initCustomNavBarInfo:function(){console.log("开始获取自定义导航栏");var t={height:0,statusHeight:45},e={width:0,height:32,top:0,left:0,bottom:0,right:0};try{var o,i=uni.getSystemInfoSync(),n=i.statusBarHeight;i.titleBarHeight;o=n+45,e.left=i.windowWidth,t={height:o,statusHeight:n},this.navBarInfo=t,this.boundingInfo=e,this.windowsOperationHeight=i.windowHeight-o}catch(a){console.error("更新导航栏信息失败",a),this.navBarInfo=t,this.boundingInfo=e}}}}},"2d64":function(t,e,o){"use strict";var i=o("d5c5"),n=o.n(i);n.a},"328d":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"tn-margin-sm tn-flex-row coupon-discount",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.subCoupon.apply(void 0,arguments)}}},[o("v-uni-view",{staticClass:"tn-flex-1"},[o("v-uni-view",{staticClass:"tn-color-red tn-padding-left"},[o("v-uni-text",{staticClass:"tn-text-lg"},[t._v("RM")]),o("v-uni-text",{staticClass:"tn-text-bold tn-margin-left-xs",staticStyle:{"font-size":"30px"}},[t._v(t._s(t.couponMoney))])],1)],1),o("v-uni-view",{staticClass:"tn-flex-1 tn-flex-column tn-color-white"},[o("v-uni-view",{},[t._v("商家代金券")]),o("v-uni-view",{staticClass:"tn-text-sm"},[t._v("内含"+t._s(t.couponNum)+"张券")])],1),o("v-uni-view",{staticClass:"tn-flex-1"})],1)},n=[]},"35a4":function(t,e,o){"use strict";o.r(e);var i=o("328d"),n=o("61e8");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("6ebd");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"fb66f786",null,!1,i["a"],void 0);e["default"]=s.exports},"3cd1":function(t,e,o){"use strict";var i=o("6e8a"),n=o.n(i);n.a},"3ebb":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */\n/* 商品展示信息 start */.goods-info[data-v-0256af13]{position:relative;width:100%}\n/* 商品展示信息 end */\n/* 购物车 start */.shopping-cart[data-v-0256af13]{position:fixed;left:5%;bottom:%?40?%;width:90%;z-index:99998;transition:bottom .25s ease}.shopping-cart.hidden[data-v-0256af13]{bottom:%?-200?%}\n/* 购物车 end */.store-nav[data-v-0256af13]{position:-webkit-sticky;position:sticky;width:100%;height:47px;z-index:9999}',""]),t.exports=e},"3fa2":function(t,e,o){"use strict";o.r(e);var i=o("9ac8"),n=o("4e74");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("e511");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"0256af13",null,!1,i["a"],void 0);e["default"]=s.exports},"46ea":function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.REFRESH_STORE_EVENT=void 0;e.REFRESH_STORE_EVENT="refresh_store"},"4ad5":function(t,e,o){"use strict";o.d(e,"b",(function(){return n})),o.d(e,"c",(function(){return a})),o.d(e,"a",(function(){return i}));var i={tnLoadMore:o("5041").default},n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"products-list sgpl-products-list theme-products-list-once",on:{touchstart:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchStart.apply(void 0,arguments)},touchend:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchEnd.apply(void 0,arguments)}}},[t._l(t.goodsDataLists,(function(e,i){return o("v-uni-view",{key:i,staticClass:"item"},[0!=t.currentCategoryIndex?o("v-uni-view",{staticClass:"tnloads"},[t.is_top&&!t.showloadNext2?o("v-uni-view",{staticClass:"tn-margin-top tn-flex tn-text-center tn-flex-row-center tn-flex-col-center"},[o("v-uni-view",[t._v("继续下拉切换至")]),o("v-uni-view",{staticStyle:{color:"#FFCA28"}},[t._v(t._s(t.data[t.currentCategoryIndex-1].title))])],1):t._e(),t.showloadNext2?o("tn-load-more",{staticClass:"tn-margin-xs",attrs:{status:"loading",loadingIconColor:"#ffca28",loadText:t.loadText7}}):t._e()],1):t._e(),o("v-uni-view",{staticClass:"item-title sgpl-item-title",class:{"open-box":t.showMoreScrTab},style:{top:t.vuex_custom_bar_height+t.navbarHeight+"px"},attrs:{id:"sgpl-item-title-"+i}},[t.showMoreScrTab?o("v-uni-view",{staticClass:"tn-flex tn-flex-col-end icon-up-box",staticStyle:{color:"#9c9c9c"}},[o("v-uni-text",{staticClass:"tn-icon-up",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.showMoreScrTab=!t.showMoreScrTab}}})],1):t._e(),e.child&&e.child.length>0&&!t.is_special?o("v-uni-view",{staticClass:"tn-flex tn-margin-bottom-xs scrTab-box"},[o("v-uni-scroll-view",{staticClass:"scroll-box",style:t.showMoreScrTab?"":"white-space: nowrap;",attrs:{"scroll-x":"true"}},t._l(e.child,(function(e,i){return o("v-uni-view",{key:i,staticClass:"scrTab-item",class:t.currentTab==i?"scrTab-item-active":"",on:{click:function(o){arguments[0]=o=t.$handleEvent(o),t.seleTabs(i,e)}}},[o("v-uni-text",{},[t._v(t._s(e.title))])],1)})),1),t.showMoreScrTab?t._e():o("v-uni-view",{staticClass:"icon-down-box",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.showMoreScrTab=!t.showMoreScrTab}}},[o("v-uni-text",{staticClass:"tn-icon-down",staticStyle:{color:"#9c9c9c"}})],1)],1):t._e(),o("v-line-title",[o("v-uni-view",{staticClass:"tn-text-ellipsis-1"},[t._v(t._s(e.title))])],1)],1),e.goods&&e.goods.length>0?o("v-uni-view",{staticClass:"item-goods",style:{paddingTop:t.paddingtop?t.pdtop+"px":""}},t._l(e.goods,(function(e,n){return o("v-uni-view",{key:n,staticClass:"good"},[o("v-uni-view",{staticClass:"good-image tn-border-gray--light",on:{click:function(o){o.stopPropagation(),arguments[0]=o=t.$handleEvent(o),t.Good(e,n)}}},[o("v-uni-image",{staticStyle:{width:"196rpx",height:"196rpx","border-radius":"15rpx"},attrs:{src:e.image||e.thumb,mode:"aspectFill"}})],1),e.label?o("v-uni-view",{staticStyle:{position:"absolute",top:"0",left:"0",color:"#fff","background-color":"#ff6a65","border-radius":"15rpx",padding:"5rpx 10rpx","font-size":"14px"}},[t._v(t._s(e.label))]):t._e(),o("v-uni-view",{staticClass:"good-info",on:{click:function(o){o.stopPropagation(),arguments[0]=o=t.$handleEvent(o),t.navPage("/store-page/goodsDetail/index?sid="+t.sid+"&id="+e.id)}}},[o("v-uni-view",{staticClass:"good-title",on:{click:function(o){o.stopPropagation(),arguments[0]=o=t.$handleEvent(o),t.navPage("/store-page/goodsDetail/index?sid="+t.sid+"&id="+e.id)}}},[t._v(t._s(e.title))]),o("v-uni-view",{staticStyle:{"font-size":"24rpx",color:"#ff9d5c"}},[o("v-uni-view",{staticClass:"content-big"},[o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("仓库库存")]),o("v-uni-view",[t._v(t._s(e.total))])],1),o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("店长库存")]),o("v-uni-view",[t._v(t._s(t.getShopkeeperStock(e)))])],1)],1),o("v-uni-view",{staticClass:"content-big"},[o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("利润")]),o("v-uni-view",[t._v(t._s(t.CurrencyUnit)+t._s(parseFloat((e.oldPrice-e.price).toFixed(2))))])],1),o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("毛利率")]),o("v-uni-view",[t._v(t._s(t.calculateGrossMargin(e)))])],1)],1),o("v-uni-view",{staticClass:"content-big"},[o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("采购价")]),o("v-uni-view",[t._v(t._s(t.CurrencyUnit)+t._s(e.price))])],1),o("v-uni-view",{staticClass:"content-min"},[o("v-uni-view",[t._v("售卖价")]),o("v-uni-view",[t._v(t._s(t.CurrencyUnit)+t._s(e.oldPrice))])],1)],1)],1),o("v-uni-view",{staticClass:"tn-flex-center-between tn-margin-top-xs theme-product-box"},[o("v-uni-view",{staticClass:"good-month-sale"},[o("v-uni-view",[t._v("销售数量")]),o("v-uni-view",[t._v(t._s(e.sailed))])],1),o("product-spec-number-box",{ref:"goods",refInFor:!0,attrs:{value:e.num,min:e.min,max:e.max,is_tuangouquan:e.is_tuangouquan,type:e.specOptions,total:e.total,"image-url":e.image?e.image:e.thumb,desc:e.content,sid:t.sid,"good-id":e.id,"spellrice-id":t.spellriceId,"table-id":t.tableId,title:e.title,"good-price":e.price,disabled:t.isRest,is_api:e.is_api,"good-old-price":e.oldPrice,good_code:e.good_code,brand:e.brand,storeCode:e.storeCode,navType:t.navType},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.handleProductNumChangeEvent(e,i,n)},"input-num":function(e){arguments[0]=e=t.$handleEvent(e),t.handleProductInputUpdaeEvent(e)}}})],1)],1)],1)})),1):t._e(),t.currentCategoryIndex!=t.data.length-1?o("v-uni-view",{staticClass:"tnloads tn-padding-bottom-xl"},[t.showloadStatu3&&!t.showloadStatu?o("v-uni-view",{staticClass:"tn-margin-top tn-flex tn-text-center tn-flex-row-center tn-flex-col-center"},[o("v-uni-view",[t._v("继续上拉切换至")]),o("v-uni-view",{staticStyle:{color:"#FFCA28"}},[t._v(t._s(t.data[t.currentCategoryIndex+1].title))])],1):t._e(),t.showloadStatu?o("tn-load-more",{staticClass:"tn-margin-top",attrs:{status:"loading",loadingIconColor:"#ffca28",loadText:t.loadText2}}):t._e(),t.showloadStatu2?o("tn-load-more",{staticClass:"tn-margin-top",attrs:{status:"loading",loadingIconColor:"#ffca28",loadText:t.loadText}}):t._e()],1):t._e()],1)})),o("v-uni-view",{staticClass:"bottom-area-content",on:{touchstart:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchStart.apply(void 0,arguments)},touchend:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchEnd.apply(void 0,arguments)}}}),o("img-modal",{attrs:{mode:t.modalmode},model:{value:t.modalShow,callback:function(e){t.modalShow=e},expression:"modalShow"}}),o("center-modal",{attrs:{"confirm-text":"修改"},on:{cancel:function(e){arguments[0]=e=t.$handleEvent(e),t.openInputGoodsNumModal=!t.openInputGoodsNumModal},confirm:function(e){arguments[0]=e=t.$handleEvent(e),t.submitUpdateCart.apply(void 0,arguments)}},model:{value:t.openInputGoodsNumModal,callback:function(e){t.openInputGoodsNumModal=e},expression:"openInputGoodsNumModal"}},[o("v-uni-input",{staticClass:"input",attrs:{type:"digit",placeholder:"请输入商品数量"},model:{value:t.inputValue,callback:function(e){t.inputValue=e},expression:"inputValue"}})],1)],2)},a=[]},"4e1f":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.search-box[data-v-2e2d1bec]{width:100%;height:31px;padding:%?10?% %?10?% %?10?% %?30?%;border-radius:%?100?%\n /* small 尺寸 搜索框 start */\n /* small 尺寸 搜索框 end */}.search-box__left-icon[data-v-2e2d1bec]{font-size:%?38?%;line-height:1}.search-box__input[data-v-2e2d1bec]{flex:1;padding-left:%?10?%}.search-box__input .input[data-v-2e2d1bec]{width:100%;background-color:initial;color:#838383;font-size:inherit;padding-left:%?0?%}.search-box__btn[data-v-2e2d1bec]{padding:%?10?% %?30?%;border-radius:%?100?%}.search-box.small[data-v-2e2d1bec]{padding:%?6?% %?10?% %?6?% %?20?%}.search-box.small .search-box__left-icon[data-v-2e2d1bec]{font-size:%?28?%}.search-box.small .search-box__input[data-v-2e2d1bec]{font-size:%?24?%}.search-box.small .search-box__btn[data-v-2e2d1bec]{font-size:%?24?%;padding:%?8?% %?20?%;background-color:#ffca28;color:#080808}',""]),t.exports=e},"4e70":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.coupon-discount[data-v-fb66f786]{background:url(http://qny.wdsp666.com/images/1/2022/04/FjBXUdq43dDRQd43Xi3q5bU0uXuI3R.png);background-repeat:no-repeat;background-size:100% %?160?%;border-radius:%?15?%;height:%?160?%;align-items:center}',""]),t.exports=e},"4e74":function(t,e,o){"use strict";o.r(e);var i=o("cbbc"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"4f43":function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.navPage=e.navMiniProgram=e.navBack=void 0,o("4626"),o("5ac7"),o("5ef2"),o("f7a5");e.navBack=function(t,e){var o=t||"/pages/index/index",i=getCurrentPages();if((null===i||void 0===i?void 0:i.length)>0){var n=i[0];1!==i.length||n.route&&n.route==o?uni.navigateBack({delta:e||1}):uni.reLaunch({url:o})}else uni.reLaunch({url:o})};e.navPage=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"nav";if(t)if("nav"===e)if(t.includes("miniProgram"))i(t);else if(t.includes("webview")){var o=t.split("webview:"),n=o[1];uni.navigateTo({url:"/system-page/webview/webview?url="+encodeURIComponent(n),fail:function(t){console.error("[navigateTo]跳转页面失败",t)}})}else uni.navigateTo({url:t,fail:function(t){console.error("[navigateTo]跳转页面失败",t)}});else"redirect"===e?uni.redirectTo({url:t,fail:function(t){console.error("[redirectTo]跳转页面失败",t)}}):"reLaunch"===e?uni.reLaunch({url:t,fail:function(t){console.error("[reLaunch]跳转页面失败",t)}}):"phone"===e&&uni.makePhoneCall({phoneNumber:t,fail:function(t){console.error("[phone]拨打电话失败",t)}})};var i=function(t){if(t&&-1!=t.indexOf(":")){for(var e=t.split(":"),o=e[1].split(","),i={},n=0;n<o.length;n++){var a=o[n].split("_");console.log(a);var r=a[0],s=a.slice(1).join("_");i[r]=s}console.log(i)}else{i={appId:obj.appid||obj.appId};obj.path&&(i["path"]=path)}i["fail"]=function(t){-1!=t.errMsg.indexOf("is not in navigateToMiniProgramAppIdList")&&uni.showModal({content:"跳转小程序出错了",showCancel:!1})},console.log(i),t&&t.includes("half_")?uni.openEmbeddedMiniProgram(i):uni.navigateToMiniProgram(i)};e.navMiniProgram=i},5036:function(t,e,o){"use strict";var i=o("84ad"),n=o.n(i);n.a},5041:function(t,e,o){"use strict";o.r(e);var i=o("b39d"),n=o("bd08");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("df40");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"295721aa",null,!1,i["a"],void 0);e["default"]=s.exports},"516a":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this.$createElement,e=this._self._c||t;return e("v-uni-view",{staticClass:"v-line-title"},[e("v-uni-view",{staticClass:"title"},[e("v-uni-view",{staticClass:"line theme-v-line-title",style:[{backgroundColor:this.avctColor?this.avctColor:this.themeBgColor}]}),this._t("default")],2)],1)},n=[]},"51cc":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.products-list[data-v-1ae0345a]{position:relative;width:100%;height:100%}.products-list .item[data-v-1ae0345a]{padding:0 %?20?%;padding-right:%?30?%\n /* 分类商品容器 start */\n /* 分类商品容器 end */}.products-list .item .item-title[data-v-1ae0345a]{position:-webkit-sticky;position:sticky;padding:%?15?% %?0?%;z-index:2333;background-color:#fff}.products-list .item .item-goods[data-v-1ae0345a]{position:relative;width:100%}.products-list .item .item-goods .good[data-v-1ae0345a]{display:flex;position:relative;margin-bottom:%?20?%\n /* 商品主图 start */\n /* 商品主图 end */\n /* 商品信息 start */\n /* 商品信息 end */}.products-list .item .item-goods .good .good-image[data-v-1ae0345a]{width:%?196?%;height:%?196?%;border-radius:%?15?%;border-width:%?1?%;border-style:solid;margin-right:%?20?%}.products-list .item .item-goods .good .good-info[data-v-1ae0345a]{flex-grow:1;display:flex;flex-direction:column;justify-content:space-between;justify-content:center\n /* 商品价格 start */\n /* 商品价格 end */}.products-list .item .item-goods .good .good-info .good-title[data-v-1ae0345a]{width:100%;font-size:%?34?%;font-weight:500;display:-webkit-box;overflow:hidden;white-space:normal!important;text-overflow:ellipsis;word-wrap:break-word;-webkit-line-clamp:1;-webkit-box-orient:vertical}.products-list .item .item-goods .good .good-info .good-month-sale[data-v-1ae0345a]{font-size:%?24?%;display:flex;justify-content:space-between;align-items:center;width:48%;color:#ff9d5c}.products-list .item .item-goods .good .good-info .good-content[data-v-1ae0345a]{width:-webkit-fit-content;width:fit-content;max-width:100%;font-size:%?22?%;border-radius:%?6?%;padding:%?0?% %?8?%;line-height:1.4em;margin-top:%?8?%;color:#ffa726}.products-list .item .item-goods .good .good-info .good-price .price[data-v-1ae0345a]{display:flex;align-items:flex-end;font-size:%?36?%;line-height:1;font-weight:700}.products-list .item .item-goods .good .good-info .good-price .price .unit[data-v-1ae0345a]{font-size:%?24?%;-webkit-transform:translateY(%?-4?%);transform:translateY(%?-4?%)}.products-list .item .item-goods .good .good-info .good-price .price.old[data-v-1ae0345a]{text-decoration:line-through;font-size:%?24?%;font-weight:400;margin-left:%?10?%}.products-list .item .item-goods .good .good-info .good-price .price.old .unit[data-v-1ae0345a]{-webkit-transform:translateY(%?0?%);transform:translateY(%?0?%)}[data-v-1ae0345a] .tnloads .tn-load-more__line{display:none}.scrTab-item[data-v-1ae0345a]{display:inline-block;white-space:pre-wrap;margin-right:%?10?%;border-radius:%?40?%;margin-bottom:%?10?%;background-color:#f5f5f5;color:#9c9c9c;text-align:center}.scrTab-item uni-text[data-v-1ae0345a]{display:block;padding:%?15?%;font-size:%?20?%;min-width:%?90?%;max-width:%?120?%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.scrTab-item-active[data-v-1ae0345a]{background:#fef8db;color:#dd8b3e}.scrTab-box[data-v-1ae0345a]{position:relative}.scrTab-box .icon-down-box[data-v-1ae0345a]{position:absolute;right:-.1rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.tn-text-ellipsis-1[data-v-1ae0345a]{display:-webkit-box;overflow:hidden;white-space:normal!important;text-overflow:ellipsis;word-wrap:break-word;-webkit-line-clamp:1;-webkit-box-orient:vertical}.bottom-area-content[data-v-1ae0345a]{padding-bottom:%?140?%;padding-bottom:calc(constant(safe-area-inset-bottom) + %?140?%)!important;padding-bottom:calc(env(safe-area-inset-bottom) + %?140?%)!important}.content-big[data-v-1ae0345a]{display:flex;justify-content:space-between;align-items:center;width:100%}.content-min[data-v-1ae0345a]{display:flex;justify-content:space-between;align-items:center;width:48%}',""]),t.exports=e},5775:function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.goods-list[data-v-f25f6344]{position:relative;width:100%;display:flex;background-color:#fff}.goods-list .list-left[data-v-f25f6344]{position:-webkit-sticky;position:sticky;width:%?160?%;flex-shrink:0;overflow-x:hidden}.goods-list .list-right[data-v-f25f6344]{flex-grow:1}',""]),t.exports=e},"59f9":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("aa9c");var n=i(o("7dcc")),a=o("4098"),r={options:{virtualHost:!0},props:{value:{type:String,default:""},leftIcon:{type:String,default:"search"},placholder:{type:String,default:""},buttonText:{type:String,default:"搜 索"},showbtn:{type:Boolean,default:!0},size:{type:String,default:"normal"}},mixins:[n.default],data:function(){return{inputValue:"",updateInner:!1}},computed:{searchBoxClass:function(){var t=[];return"small"===this.size&&t.push("small"),t.join(" ")}},watch:{value:{handler:function(t){this.updateInner?this.updateInner=!1:this.inputValue=t},immediate:!0}},methods:{inputChangeEvent:function(t){var e=this,o=t.detail.value;(0,a.debounce)((function(){e.$emit("input",o),e.$emit("change",o)}),50)()},btnClickEvent:function(){var t=this;(0,a.throttle)((function(){t.$emit("search-btn-click")}),250)()}}};e.default=r},"5d89":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.tn-load-more__wrap[data-v-295721aa]{background-color:initial;display:flex;flex-direction:row;justify-content:center;align-items:center;color:#838383}.tn-load-more__line[data-v-295721aa]{vertical-align:middle;border:1px solid #838383;width:%?50?%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}.tn-load-more__content[data-v-295721aa]{display:flex;flex-direction:row;justify-content:center;align-items:center;padding:0 %?12?%}.tn-load-more__content--more[data-v-295721aa]{position:relative}.tn-load-more__loading[data-v-295721aa]{margin-right:%?8?%}.tn-load-more__loading__icon[data-v-295721aa]{display:flex;flex-direction:row;justify-content:center;align-items:center}.tn-load-more__text[data-v-295721aa]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;line-height:%?30?%}.tn-load-more__text--dot[data-v-295721aa]{font-size:%?28?%}',""]),t.exports=e},"5ed6":function(t,e,o){"use strict";o.r(e);var i=o("fe56"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"5edb":function(t,e,o){"use strict";o.d(e,"b",(function(){return n})),o.d(e,"c",(function(){return a})),o.d(e,"a",(function(){return i}));var i={tnBadge:o("8d2a").default},n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"categorys theme-goods-categorys"},[t._l(t.data,(function(e,i){return o("v-uni-view",{key:i,staticClass:"item tn-flex-center tn-bg-gray--light",class:i===t.currentSelectIndex?"select theme-categorys-select":"",staticStyle:{"flex-wrap":"wrap"},style:[t.itemStyle(i)],attrs:{id:"item-"+t.id},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.categoryClickEvent(i)}}},[e.description?o("v-uni-view",{staticClass:"itemDescribe theme-itemDescribe"},[t._v(t._s(e.description))]):t._e(),t.getCategoryGoodsNum(e.id)?o("tn-badge",{attrs:{backgroundColor:"#ff0004",fontColor:"#ffffff",absolute:!0,top:"20",right:"20",radius:32}},[t._v(t._s(t.getCategoryGoodsNum(e.id)))]):t._e(),e.thumb?o("v-uni-view",{staticClass:"itemIconBox"},[o("v-uni-image",{staticClass:"itemIcon",attrs:{src:e.thumb}})],1):t._e(),o("v-uni-view",{staticClass:"itemTitle"},[t._v(t._s(e.title))]),1==e.is_mandatory?o("v-uni-view",{staticStyle:{color:"#ff9900"}},[t._v("(必选)")]):t._e(),i===t.currentSelectIndex?o("v-uni-view",{staticClass:"select-line theme-select-line",style:[{backgroundColor:t.avctColor?t.avctColor:t.themeBgColor}]}):t._e()],1)})),o("v-uni-view",{staticClass:"tn-bg-gray--light",style:[{borderTopRightRadius:t.currentSelectIndex===t.data.length-1?"15rpx":"0rpx",height:t.bottomEmptyAreaRectInfo.height+"px"}]})],2)},a=[]},"61cb":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.store-nav[data-v-44737eca]{position:relative;width:100%;background-color:#fff;display:flex;align-items:center;padding:%?10?% %?30?%;padding-bottom:%?20?%\n /* 导航 start */\n /* 导航 end */\n /* 搜索 start */\n /* 搜索 end */}.store-nav .nav-wrapper[data-v-44737eca]{display:flex;align-items:center}.store-nav .nav-wrapper .nav-item[data-v-44737eca]{position:relative;flex-shrink:0;padding-right:%?30?%;font-size:%?34?%}.store-nav .nav-wrapper .nav-item.select[data-v-44737eca]{font-size:%?38?%;font-weight:500}.store-nav .nav-wrapper .nav-item .bottom-line[data-v-44737eca]{position:absolute;left:calc(50% - %?15?%);bottom:%?-20?%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);width:50%;height:%?10?%;border-radius:%?30?%}.store-nav .search[data-v-44737eca]{flex:1}',""]),t.exports=e},"61e8":function(t,e,o){"use strict";o.r(e);var i=o("ba52"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"637e":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.tn-loading-circle[data-v-198243dd]{display:inline-flex;vertical-align:middle;width:%?28?%;height:%?28?%;background:0 0;border-radius:50%;border:2px solid;border-color:#e6e6e6 #e6e6e6 #e6e6e6 #aaa}.tn-loading-circle--animation[data-v-198243dd]{animation:tn-circle-data-v-198243dd 1s linear infinite;-webkit-animation:tn-circle-data-v-198243dd 1s linear infinite}.tn-loading-flower[data-v-198243dd]{display:inline-block;vertical-align:middle;width:%?28?%;height:%?28?%;background:transparent url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMjAiIGhlaWdodD0iMTIwIiB2aWV3Qm94PSIwIDAgMTAwIDEwMCI+PHBhdGggZmlsbD0ibm9uZSIgZD0iTTAgMGgxMDB2MTAwSDB6Ii8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjRTlFOUU5IiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAgLTMwKSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iIzk4OTY5NyIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgzMCAxMDUuOTggNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjOUI5OTlBIiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKDYwIDc1Ljk4IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0EzQTFBMiIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSg5MCA2NSA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNBQkE5QUEiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoMTIwIDU4LjY2IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0IyQjJCMiIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgxNTAgNTQuMDIgNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjQkFCOEI5IiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKDE4MCA1MCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNDMkMwQzEiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTE1MCA0NS45OCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNDQkNCQ0IiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTEyMCA0MS4zNCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNEMkQyRDIiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTkwIDM1IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0RBREFEQSIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgtNjAgMjQuMDIgNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjRTJFMkUyIiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKC0zMCAtNS45OCA2NSkiLz48L3N2Zz4=) no-repeat;background-size:100%}.tn-loading-flower--animation[data-v-198243dd]{animation:tn-flower-data-v-198243dd 1s steps(12) infinite;-webkit-animation:tn-flower-data-v-198243dd 1s steps(12) infinite}@-webkit-keyframes tn-flower-data-v-198243dd{0%{transform:rotate(0deg);-webkit-transform:rotate(0deg)}to{transform:rotate(1turn);-webkit-transform:rotate(1turn)}}@keyframes tn-flower-data-v-198243dd{0%{transform:rotate(0deg);-webkit-transform:rotate(0deg)}to{transform:rotate(1turn);-webkit-transform:rotate(1turn)}}@-webkit-keyframes tn-circle-data-v-198243dd{0%{transform:rotate(0);-webkit-transform:rotate(0)}100%{transform:rotate(1turn);-webkit-transform:rotate(1turn)}}@keyframes tn-circle-data-v-198243dd{0%{transform:rotate(0);-webkit-transform:rotate(0)}100%{transform:rotate(1turn);-webkit-transform:rotate(1turn)}}',""]),t.exports=e},"64d5":function(t,e,o){"use strict";var i=o("916b"),n=o.n(i);n.a},"668d":function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.shopping-cart[data-v-3d4bd26f]{position:relative;width:100%;height:%?100?%;border-radius:%?200?%;overflow:hidden;display:flex;z-index:99998\n /* 购物车信息 start */\n /* 购物车信息 end */\n /* 操作按钮 start */\n /* 操作按钮 end */\n /* 店铺休息中 start */\n /* 店铺休息中 end */}.shopping-cart .cart-info[data-v-3d4bd26f]{position:relative;width:72%;height:100%;background-color:#080808;color:#fff;display:flex;align-items:center;z-index:inherit;border-radius:%?200?% %?0?% %?0?% %?200?%\n /* 购物车价格 start */\n /* 购物车价格 end */}.shopping-cart .cart-info .cart-icon[data-v-3d4bd26f]{position:relative;margin-left:%?40?%;font-size:%?50?%}.shopping-cart .cart-info .cart-icon .cart-good-num[data-v-3d4bd26f]{position:absolute;top:%?-6?%;right:%?-10?%;line-height:1;padding:%?4?%;min-width:%?32?%;font-size:%?24?%;border-radius:50%;background-color:#e83a30}.shopping-cart .cart-info .cart-price[data-v-3d4bd26f]{margin-left:%?50?%\n /* 商品价格 start */\n /* 商品价格 end */\n /* 配送价格 start */\n /* 配送价格 end */}.shopping-cart .cart-info .cart-price .product-price[data-v-3d4bd26f]{display:flex;align-items:flex-end}.shopping-cart .cart-info .cart-price .product-price .price[data-v-3d4bd26f]{display:flex;align-items:flex-end;font-size:%?40?%}.shopping-cart .cart-info .cart-price .product-price .price .unit[data-v-3d4bd26f],\n.shopping-cart .cart-info .cart-price .product-price .price .value[data-v-3d4bd26f]{line-height:1;vertical-align:bottom}.shopping-cart .cart-info .cart-price .product-price .price .unit[data-v-3d4bd26f]{font-size:%?28?%}.shopping-cart .cart-info .cart-price .product-price .price.old[data-v-3d4bd26f]{font-size:%?28?%;text-decoration:line-through;margin-left:%?10?%}.shopping-cart .cart-info .cart-price .delivery-price[data-v-3d4bd26f]{font-size:%?24?%;margin-top:%?4?%}.shopping-cart .cart-info .cart-price .delivery-price .price[data-v-3d4bd26f]{margin-left:%?4?%}.shopping-cart .operation-btn[data-v-3d4bd26f]{position:relative;width:28%;height:100%;z-index:inherit;border-radius:%?0?% %?200?% %?200?% %?0?%;background-color:#ffca28}.shopping-cart .cart-is_rest[data-v-3d4bd26f]{position:relative;width:100%;height:100%;background-color:#080808;border-radius:%?200?%;font-size:%?40?%}\n/* 购物车商品列表 start */.product-list[data-v-3d4bd26f]{\n /* 顶部操作按钮信息 start */\n /* 顶部操作按钮信息 end */\n /* 购物车商品展示 start */\n /* 购物车商品展示 end */}.product-list__top-operation[data-v-3d4bd26f]{padding:%?20?% %?30?%}.product-list__content[data-v-3d4bd26f]{width:100%;height:%?660?%;padding:%?30?%}.product-list__content .product-item[data-v-3d4bd26f]{width:100%;display:flex;padding:%?30?% %?0?%;border-bottom:%?1?% solid #f3f2f7\n /* 商品内容 start */\n /* 商品内容 end */}.product-list__content .product-item[data-v-3d4bd26f]:last-child{border-bottom:none}.product-list__content .product-item .item-image[data-v-3d4bd26f]{width:%?100?%;height:%?100?%;border-radius:%?15?%}.product-list__content .product-item .item-info[data-v-3d4bd26f]{flex:1;width:100%;padding-left:%?20?%}.product-list__content .product-item .item-info .item-title[data-v-3d4bd26f]{font-size:%?32?%;font-weight:500}.product-list__content .product-item .item-info .item-spec[data-v-3d4bd26f]{font-size:%?24?%}.product-list__content .product-item .item-info .item-operation[data-v-3d4bd26f]{display:flex;align-items:center;justify-content:space-between;margin-top:%?10?%}.product-list__content .product-item .item-info .item-price[data-v-3d4bd26f]{font-size:%?34?%}.product-list__bottom-empty[data-v-3d4bd26f]{width:100%;height:%?80?%}.shopping-cart2[data-v-3d4bd26f]{position:relative;width:100%;height:%?100?%;border-radius:%?200?%;height:%?120?%;border-radius:%?20?% %?20?% %?0?% %?0?%;overflow:hidden;display:flex;z-index:99998\n /* 购物车信息 start */\n /* 购物车信息 end */\n /* 操作按钮 start */\n /* 操作按钮 end */\n /* 店铺休息中 start */\n /* 店铺休息中 end */}.shopping-cart2 .cart-info[data-v-3d4bd26f]{position:relative;height:100%;background-color:#fff!important;color:#fff;display:flex;flex:1;align-items:center;z-index:inherit;border-radius:%?200?% %?0?% %?0?% %?200?%;border-radius:%?20?% %?0?% %?0?% 0\n /* 购物车价格 start */\n /* 购物车价格 end */}.shopping-cart2 .cart-info .cart-icon[data-v-3d4bd26f]{position:relative;margin-left:%?40?%;font-size:%?50?%}.shopping-cart2 .cart-info .cart-icon .icon[data-v-3d4bd26f]{width:%?90?%;height:%?90?%;display:flex;align-items:center;justify-content:center;background-color:#00ba4d;border-radius:50%}.shopping-cart2 .cart-info .cart-icon .cart-good-num[data-v-3d4bd26f]{position:absolute;top:%?-6?%;right:%?-10?%;line-height:1;padding:%?4?%;min-width:%?32?%;font-size:%?24?%;border-radius:50%}.shopping-cart2 .cart-info .cart-price[data-v-3d4bd26f]{margin-left:%?25?%\n /* 商品价格 start */\n /* 商品价格 end */\n /* 配送价格 start */\n /* 配送价格 end */}.shopping-cart2 .cart-info .cart-price .product-price[data-v-3d4bd26f]{display:flex;align-items:flex-end}.shopping-cart2 .cart-info .cart-price .product-price .price[data-v-3d4bd26f]{display:flex;align-items:flex-end;font-size:%?36?%;color:#ff2626!important}.shopping-cart2 .cart-info .cart-price .product-price .price .unit[data-v-3d4bd26f],\n.shopping-cart2 .cart-info .cart-price .product-price .price .value[data-v-3d4bd26f]{line-height:1;vertical-align:bottom}.shopping-cart2 .cart-info .cart-price .product-price .price .unit[data-v-3d4bd26f]{font-size:%?28?%}.shopping-cart2 .cart-info .cart-price .product-price .price.old[data-v-3d4bd26f]{font-size:%?28?%;text-decoration:line-through;margin-left:%?10?%}.shopping-cart2 .cart-info .cart-price .delivery-price[data-v-3d4bd26f]{font-size:%?24?%;margin-top:%?4?%;color:#989898!important}.shopping-cart2 .cart-info .cart-price .delivery-price .price[data-v-3d4bd26f]{margin-left:%?4?%}.shopping-cart2 .operation-btn[data-v-3d4bd26f]{display:flex;flex:1.3;position:relative;justify-content:space-between;z-index:inherit;background-color:#fff!important;align-items:center;font-size:%?28?%}.shopping-cart2 .operation-btn .left[data-v-3d4bd26f]{display:flex;align-items:center;justify-content:center;width:%?200?%;height:%?85?%;background-color:#ffcb5b;color:#622c00;border-radius:%?10?%;flex-direction:column}.shopping-cart2 .operation-btn .right[data-v-3d4bd26f]{display:flex;align-items:center;justify-content:center;width:%?200?%;height:%?85?%;background-color:#d60200;color:#fff;border-radius:%?10?%;margin-right:%?10?%;flex-direction:column}.shopping-cart2 .operation-btn .disabled[data-v-3d4bd26f]{background-color:#989898!important;color:#fff!important}.shopping-cart2 .cart-is_rest[data-v-3d4bd26f]{position:relative;width:100%;height:100%;background-color:#080808;border-radius:%?200?%;font-size:%?40?%}\n/* 购物车商品列表 end */.red-box[data-v-3d4bd26f]{display:inline-block;background-color:red;color:#fff;font-size:%?28?%;padding:%?4?%}.scroll-view[data-v-3d4bd26f]{height:100%}',""]),t.exports=e},6703:function(t,e,o){var i=o("637e");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("04117470",i,!0,{sourceMap:!1,shadowMode:!1})},"6dba":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return t.openModal?o("v-uni-view",{staticClass:"ImgModal"},[o("v-uni-view",{staticClass:"ImgModal__content"},[o("v-uni-image",{staticClass:"ImgModal__content__img",staticStyle:{width:"100%",height:"600rpx"},attrs:{mode:"aspectFill",src:t.mode.image}}),o("v-uni-view",{staticClass:"tn-text-bold",staticStyle:{"margin-top":"20rpx","font-size":"36rpx"}},[t._v(t._s(t.mode.title))]),o("v-uni-view",{staticClass:"tn-text-bold desc",staticStyle:{"margin-top":"20rpx",color:"#FFA726"}},[t._v(t._s(t.mode.content))]),o("v-uni-view",{staticClass:"price tn-color-red"},[o("v-uni-view",{staticClass:"unit"},[t._v("RM")]),o("v-uni-view",{staticClass:"value"},[t._v(t._s(t.mode.price))])],1),o("v-uni-view",{staticClass:"ImgModal__content__close tn-icon-close-circle",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.closeModal()}}})],1)],1):t._e()},n=[]},"6e8a":function(t,e,o){var i=o("ad44");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("358a8a87",i,!0,{sourceMap:!1,shadowMode:!1})},"6ebd":function(t,e,o){"use strict";var i=o("bbaa"),n=o.n(i);n.a},"71eb":function(t,e,o){var i=o("61cb");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("7209ae11",i,!0,{sourceMap:!1,shadowMode:!1})},7211:function(t,e,o){"use strict";o.r(e);var i=o("06e0"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"73e1":function(t,e,o){"use strict";var i=o("29d8");t.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(i)},7401:function(t,e,o){var i=o("668d");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("94576c2e",i,!0,{sourceMap:!1,shadowMode:!1})},7445:function(t,e,o){"use strict";var i=o("71eb"),n=o.n(i);n.a},7610:function(t,e,o){"use strict";o.r(e);var i=o("009f"),n=o("7211");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("5036");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"f25f6344",null,!1,i["a"],void 0);e["default"]=s.exports},7762:function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.ImgModal[data-v-622832e3]{width:100%;height:100%;position:fixed;top:0;left:0;right:0;border:0;background-color:rgba(0,0,0,.4);transition:.25s linear;transition-property:opacity;opacity:1;z-index:999989}.ImgModal__content[data-v-622832e3]{top:22%;width:calc(100% - 60px);height:auto;position:relative;box-sizing:border-box;background-color:#fff;padding:15px 15px;border-radius:15px;margin:auto}.ImgModal__content__close[data-v-622832e3]{position:relative;bottom:%?-150?%;margin:0 auto;align-content:center;text-align:center;color:#fff;font-size:%?60?%}.price[data-v-622832e3]{display:flex;align-items:flex-end;font-size:%?36?%;line-height:1;font-weight:700;margin-top:%?60?%}.price .unit[data-v-622832e3]{font-size:%?24?%;-webkit-transform:translateY(%?-4?%);transform:translateY(%?-4?%)}.price.old[data-v-622832e3]{text-decoration:line-through;font-size:%?24?%;font-weight:400;margin-left:%?10?%}.price.old .unit[data-v-622832e3]{-webkit-transform:translateY(%?0?%);transform:translateY(%?0?%)}',""]),t.exports=e},"795c":function(t,e,o){"use strict";var i=o("8bdb"),n=o("db04").start,a=o("73e1");i({target:"String",proto:!0,forced:a},{padStart:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}})},"7ac2":function(t,e,o){"use strict";o.r(e);var i=o("516a"),n=o("1bf8");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("3cd1");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"3743389a",null,!1,i["a"],void 0);e["default"]=s.exports},"7dd5":function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this.$createElement,e=this._self._c||t;return this.show?e("v-uni-view",{staticClass:"tn-loading-class tn-loading",class:["tn-loading-"+this.mode,this.animation?"tn-loading-"+this.mode+"--animation":""],style:[this.loadStyle]}):this._e()},n=[]},"818f":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa"),o("aa77"),o("bf0f"),o("5c47"),o("0506"),o("fd3c"),o("f7a5"),o("aa9c"),o("2797");var n=i(o("7ac2")),a=i(o("1045")),r=i(o("e165")),s=o("06f9"),d=o("47da"),c=o("dfc8"),l=i(o("b6ce")),u=o("4f43"),p={options:{styleIsolation:"shared"},props:{data:{type:Array,default:function(){return[]}},stickyHeight:{type:Number,default:0},paddingtop:{type:Boolean,default:!1},currentCategoryIndex:{type:[String,Number],default:0},sid:{type:[String,Number],default:""},spellriceId:{type:[String,Number],default:""},tableId:{type:[String,Number],default:""},isRest:{type:Boolean,default:!1},showloadStatu:{type:Boolean,default:!1},showloadStatu2:{type:Boolean,default:!1},showloadStatu3:{type:Boolean,default:!1},is_renovate:{type:Boolean,default:!1},is_top:{type:Boolean,default:!1},showloadNext2:{type:Boolean,default:!1},navType:{type:String,default:""},navbarHeight:{type:Number,default:0},goods:{type:Array,default:function(){return[]}}},components:{VLineTitle:n.default,ProductSpecNumberBox:r.default,ImgModal:l.default,CenterModal:a.default},data:function(){return{productsListRectInfo:{top:0},pdtop:0,titleRectInitCount:0,categoryTitleRectInfo:{height:0},categoryTitleTopInfo:[],listObserverName:"tnProductListObserver",Goodname:"",modalShow:!1,modalmode:{},goodsDataLists:[],clientYStart:0,clientYEnd:0,openInputGoodsNumModal:!1,goodsId:"",inputValue:0,options_id:"",loadText:{loadmore:"加载更多",loading:"正在加载中...",nomore:"没有更多了"},loadText2:{loadmore:"切换下个分类",loading:"正在切换下个分类...",nomore:"没有更多了"},loadText6:{loadmore:"继续下拉切换至上个分类",loading:"继续下拉切换至上个分类",nomore:"继续下拉切换至上个分类"},loadText7:{loadmore:"正在切换上个分类...",loading:"正在切换上个分类...",nomore:"正在切换上个分类..."},loadText8:{loadmore:"继续上拉切换至下个分类",loading:"继续上拉切换至下个分类",nomore:"继续上拉切换至下个分类"},currentTab:"",showMoreScrTab:!1,delivery_type:!1,is_special:!1,itemHeight:0,productsListHeight:0}},computed:{categoryTitleStyle:function(){var t={};if(this.categoryTitleTopInfo&&this.categoryTitleTopInfo[0]&&this.productsListRectInfo.top&&this.stickyHeight){var e=this.categoryTitleTopInfo[0]-this.productsListRectInfo.top+this.stickyHeight-uni.upx2px(4);t.top="".concat(e.toFixed(0),"px")}else t.top="50px";return t}},watch:{data:{handler:function(t){console.log("接收到数据",t),t&&t.length>0&&this.setCurrentData(),console.log("navbarHeight",this.navbarHeight)},immediate:!0},currentCategoryIndex:{handler:function(t){this.setCurrentData()}}},created:function(){this.historyCart()},mounted:function(){this.getItemHeight()},destroyed:function(){this._discountObserver()},methods:{getShopkeeperStock:function(t){var e=this.goods.find((function(e){return e.number===t.number}));return console.log("matchingItem",e),e?e.total:0},calculateGrossMargin:function(t){var e=t.oldPrice-t.price;if(0===e||0===t.oldPrice)return"0.00%";var o=(e/t.oldPrice*100).toFixed(2);return"".concat(o,"%")},getItemHeight:function(){var t=this,e=uni.createSelectorQuery().in(this);e.selectAll(".item").boundingClientRect((function(e){e.length>0&&(t.itemHeight=e[0].height)})).exec(),e.selectAll(".products-list").boundingClientRect((function(e){e.length>0&&(t.productsListHeight=e[0].height)})).exec(),uni.getSystemInfo({success:function(e){var o=e.windowHeight;t.productsListHeight>t.itemHeight&&t.itemHeight<.7*o&&t.$emit("onR")}})},seleTabs:function(t,e){console.log(t,e),this.currentTab=t,this.$emit("chang-tabs",e.id,t)},handleProductInputUpdaeEvent:function(t){this.inputValue=t.value,this.goodsId=t.goodId,this.options_id=t.options_id,this.openInputGoodsNumModal=!0},submitUpdateCart:function(){var t=this;(0,c.updateGoodCartApi)({goodsId:this.goodsId,sid:this.sid,num:this.inputValue,options_id:this.options_id}).then((function(e){t.openInputGoodsNumModal=!1,t.$emit("good-num-change",{type:"",cid:"",goodId:""})})).catch((function(t){(0,d.showToast)({title:t.msg})}))},handleTouchStart:function(t){this.getItemHeight(),this.clientYStart=t.changedTouches[0].clientY,console.log("goods",this.goods)},handleTouchEnd:function(t){this.clientYEnd=t.changedTouches[0].clientY,this.clientYStart-this.clientYEnd>150&&this.$emit("category-next",this.goodsDataLists[0].goods.length),this.clientYEnd-this.clientYStart>50&&this.$emit("category-top",this.goodsDataLists[0].goods.length)},setCurrentData:function(){var t=this;if(this.getItemHeight(),this.goodsDataLists=[this.data[this.currentCategoryIndex]],console.log("this.goodsDataLists",this.goodsDataLists),console.log("this.data",this.data),this.data.length>0){var e=this.data[this.currentCategoryIndex].id;console.log("id",e),/^\d+$/.test(e)?this.is_special=!1:this.is_special=!0}this.$nextTick((function(){t.categoryTitleTopInfo.length||t._getCategoryTitleRectInfo()}))},handleProductNumChangeEvent:function(t,e,o){var i=this.data[this.currentCategoryIndex],n=i.goods[o];this.$emit("good-num-change",{type:"add"===t.type?"+":"-",cid:i.id,goodId:n.id})},_getCategoryTitleRectInfo:function(){var t=this,e=(0,s.createQuery)(this);e.selectAll(".sgpl-products-list, .sgpl-item-title").boundingClientRect((function(e){if(!e||e.length<=0)return t.titleRectInitCount>10?console.error("[showcaseGoodsList-productList]获取分类标题容器信息失败"):void setTimeout((function(){t._getCategoryTitleRectInfo(),t.titleRectInitCount++}),150);t.productsListRectInfo.top=e[0].top,t.pdtop=e[1].height,e.slice(1).map((function(e){t.categoryTitleRectInfo.height||(t.categoryTitleRectInfo.height=e.height),t.categoryTitleTopInfo.push(e.top)})),t.$emit("init-finish",t.categoryTitleTopInfo)})).exec()},_discountObserver:function(){var t=this[this.listObserverName];t&&t.disconnect()},Good:function(t,e){if(1==t.specOptions){var o=this.$refs.goods;console.log(o);for(var i=null,n=0;n<o.length;n++)if(o[n]["goodId"]==t.id){i=o[n];break}i.handleSpecClickEvent()}else this.modalmode=t,this.modalShow=!0},historyCart:function(){var t=this;uni.$on("historyCart",(function(e){t.data.forEach((function(o){o.goods.forEach((function(o){var i=e.find((function(t){return+t.goodId===+o.id}));i?t.$set(o,"num",i.num):t.$set(o,"num",0)}))})),t.goodsDataLists.forEach((function(o){o.goods.forEach((function(o){var i=e.find((function(t){return+t.goodId===+o.id}));i?t.$set(o,"num",i.num):t.$set(o,"num",0)}))}))}))},navPage:u.navPage}};e.default=p},"84ad":function(t,e,o){var i=o("5775");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("52e2cd92",i,!0,{sourceMap:!1,shadowMode:!1})},"874c":function(t,e,o){"use strict";o.r(e);var i=o("fa49a"),n=o("9722");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("c825");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"2e2d1bec",null,!1,i["a"],void 0);e["default"]=s.exports},"8d2a":function(t,e,o){"use strict";o.r(e);var i=o("1ee6"),n=o("9f89");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("027c");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"5ef10296",null,!1,i["a"],void 0);e["default"]=s.exports},"916b":function(t,e,o){var i=o("51cc");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("9b3fa9ea",i,!0,{sourceMap:!1,shadowMode:!1})},9397:function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,".custom-switch[data-v-1ae0345a]{\n\t/* display: none !important; */}",""]),t.exports=e},"95e4":function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa");var i={options:{virtualHost:!0},props:{value:{type:Boolean,default:!1},closeBtn:{type:Boolean,default:!0},zIndex:{type:[String,Number],default:""},noPadding:{type:Boolean,default:!1},mask:{type:Boolean,default:!0},closeMask:{type:Boolean,default:!0},transparentMask:{type:Boolean,default:!1}},data:function(){return{openModal:!1}},computed:{modalStyle:function(){var t={};return this.zIndex&&(t.zIndex=Number(this.zIndex-1)),t},closeBtnStyle:function(){var t={};return this.zIndex&&(t.zIndex=Number(this.zIndex)),t},wrapperStyle:function(){var t={};return this.zIndex&&(t.zIndex=Number(this.zIndex)),t}},watch:{value:{handler:function(t){this.openModal=t},immediate:!0}},methods:{closeModal:function(t){("mask"!==t||this.closeMask)&&(this.$emit("cancel"),this.$emit("input",!1),this.$emit("close"))}}};e.default=i},9722:function(t,e,o){"use strict";o.r(e);var i=o("59f9"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"9a20":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(o("7dcc")),a={mixins:[n.default],props:{avctColor:{type:String,default:""}},data:function(){return{}}};e.default=a},"9ac8":function(t,e,o){"use strict";o.d(e,"b",(function(){return n})),o.d(e,"c",(function(){return a})),o.d(e,"a",(function(){return i}));var i={tnNavBar:o("3703").default},n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{on:{touchstart:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchStart.apply(void 0,arguments)},touchend:function(e){arguments[0]=e=t.$handleEvent(e),t.handleTouchEnd.apply(void 0,arguments)}}},[o("tn-nav-bar",{attrs:{fixed:!0,id:"tn-nav-bar",beforeBack:t.beforeBack,backTitle:"",bottomShadow:!1}},[t._v("进货")]),t.storeInfo.class_type?o("v-uni-view",{staticClass:"store-nav",style:[{top:t.navBarInfo.height+"px"}],attrs:{id:"nav_"+t.componentId}},[o("store-nav",{on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.handleNavChangeEvent.apply(void 0,arguments)},search:function(e){arguments[0]=e=t.$handleEvent(e),t.handleSearchEvent.apply(void 0,arguments)}},model:{value:t.currentNavIndex,callback:function(e){t.currentNavIndex=e},expression:"currentNavIndex"}})],1):t._e(),t.renderTemplateFlag[0]?o("v-uni-view",{staticClass:"goods-info tn-border-top tn-border-gray--light theme-goods-info",style:[t.currentNavStyle(0)]},[o("goods-list",{ref:"goodsList",attrs:{pageShowType:t.pageShowType,data:t.goodsData,storeData:t.storeInfo.storeInfo.coupons,"sticky-distance":t.goodsPreviewRectInfo.stickyDistance,height:t.goodsPreviewRectInfo.height,"navbar-height":t.navBarInfo.height,sid:t.storeInfo.storeInfo.id,"spellrice-id":t.optionsData.spellriceId,"table-id":t.optionsData.tableId,"is-rest":t.isRest,navType:t.previous,storeShow:t.storeInfo.storeInfo.storeShow,"category-index":t.categoryIndex,"is-reach-bottom":t.isReachBottom,"is-next-category":t.isNextCategory,is_renovate:t.is_renovate,is_top:t.is_top,searchComdId:t.chrid,showloadNext:t.showloadNext,showloadNext1:t.showloadNext1,loadText:t.loadText,brand:t.brand,default_display_selection:t.storeInfo.storeInfo.default_display_selection,goods:t.goods,categoryGoodsNum:t.categoryGoodsNum,refreshCategoryTitleRectInfo:t.refreshCategoryTitleRectInfo},on:{changTabsId:function(e){arguments[0]=e=t.$handleEvent(e),t.changTabs.apply(void 0,arguments)},onReachBottom:function(e){arguments[0]=e=t.$handleEvent(e),t.onReachBottom1.apply(void 0,arguments)},"render-finish":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodsListRenderFinishEvent.apply(void 0,arguments)},"category-change":function(e){arguments[0]=e=t.$handleEvent(e),t.handleCategoryChangeEvent.apply(void 0,arguments)},searchPromotion:function(e){arguments[0]=e=t.$handleEvent(e),t.searchPromotion.apply(void 0,arguments)},"good-num-change":function(e){arguments[0]=e=t.$handleEvent(e),t.handleGoodsListGoodNumChangeEvent.apply(void 0,arguments)}}})],1):t._e(),o("v-uni-view",{staticClass:"shopping-cart theme-shopping-cart"},[o("shopping-cart",{ref:"shoppingCartRef",attrs:{"send-price":t.storeInfo.storeInfo.sendPrice,selfPickupMinPrice:t.storeInfo.storeInfo.selfPickupMinPrice,"delivery-price":t.storeInfo.storeInfo.deliveryPrice,sid:t.storeInfo.storeInfo.id,"goods-data":t.goodsData,"table-id":t.optionsData.tableId,"spellrice-id":t.optionsData.spellriceId,"is-rest":t.isRest,deliveryType:t.storeInfo.storeInfo.delivery_type,isZiti:t.delivery_type,brand:t.brand,storeCode:t.storeCode,encrypted_data:t.encrypted_data,multiple_cart:t.storeInfo.multiple_cart_is_open,multiple_cart_add_fee:t.storeInfo.multiple_cart_add_fee,pageShowType:t.pageShowType},on:{updateCategoryGoodsNum:function(e){arguments[0]=e=t.$handleEvent(e),t.updateCategoryGoodsNum.apply(void 0,arguments)},"get-cart-id":function(e){arguments[0]=e=t.$handleEvent(e),t.getCartId.apply(void 0,arguments)},"good-num-change":function(e){arguments[0]=e=t.$handleEvent(e),t.handleShoppingCartGoodNumChangeEvent.apply(void 0,arguments)},clear:function(e){arguments[0]=e=t.$handleEvent(e),t.handleShoppingCartClearEvent.apply(void 0,arguments)},"refresh-data":function(e){arguments[0]=e=t.$handleEvent(e),t.handleSubmitOrderRefreshEvent.apply(void 0,arguments)},"update-category":function(e){arguments[0]=e=t.$handleEvent(e),t.handleUpdateCategoryEvent.apply(void 0,arguments)}}})],1)],1)},a=[]},"9f89":function(t,e,o){"use strict";o.r(e);var i=o("faf2"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},"9fa2":function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa");var n=i(o("7dcc")),a=i(o("874c")),r={props:{value:{type:[String,Number],default:0}},components:{SearchBox:a.default},mixins:[n.default],data:function(){return{navs:["下单","评价","商家"],currentNavIndex:0,searchValue:"",oldSearchValue:""}},watch:{value:{handler:function(t){this.currentNavIndex=t},immediate:!0}},methods:{switchNavEvent:function(t){t!==this.currentNavIndex&&(this.$emit("input",t),this.$emit("change",t))},handleSearchBtnClickEvent:function(){this.oldSearchValue!==this.searchValue&&(this.oldSearchValue=this.searchValue,this.$emit("search",this.searchValue))}}};e.default=r},a465:function(t,e,o){"use strict";o.r(e);var i=o("95e4"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},a66a:function(t,e,o){"use strict";o.r(e);var i=o("5edb"),n=o("be19");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("b917");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"44364970",null,!1,i["a"],void 0);e["default"]=s.exports},a71d:function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"store-nav"},[o("v-uni-view",{staticClass:"search"},[o("search-box",{attrs:{size:"small",placholder:"请输入商品名称"},on:{"search-btn-click":function(e){arguments[0]=e=t.$handleEvent(e),t.handleSearchBtnClickEvent.apply(void 0,arguments)}},model:{value:t.searchValue,callback:function(e){t.searchValue=e},expression:"searchValue"}})],1)],1)},n=[]},a736:function(t,e,o){"use strict";o.r(e);var i=o("d28f"),n=o("a465");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("c8a1");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"7cd1a66a",null,!1,i["a"],void 0);e["default"]=s.exports},a88e:function(t,e,o){"use strict";o.r(e);var i=o("818f"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},ad44:function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.v-line-title[data-v-3743389a]{position:relative}.v-line-title .title[data-v-3743389a]{position:relative;margin-left:%?34?%;font-size:inherit\n /* 竖线 */}.v-line-title .title .line[data-v-3743389a]{position:absolute;width:%?10?%;height:90%;border-radius:%?60?%;left:%?-16?%;top:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);background-color:#ffca28}',""]),t.exports=e},af6d:function(t,e,o){var i=o("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 下方引入的为Tuniao UI的集成样式文件,为scss预处理器,其中包含了一些"tn-"开头的自定义变量\n * 使用的时候,请将下面的一行复制到您的uniapp项目根目录的uni.scss中即可\n * Tuniao UI自定义的css类名和scss变量,均以"tn-"开头,不会造成冲突,请放心使用 \n */.itemDescribe[data-v-44364970]{width:90%;height:%?40?%;background-color:#ffca28;color:#fff;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;border-top-left-radius:%?11?%;border-top-right-radius:%?11?%;-o-text-overflow:ellipsis;line-height:%?40?%;padding-left:%?8?%;padding-right:%?8?%}.itemIconBox[data-v-44364970]{width:90%;height:auto;padding:%?10?%}.itemIconBox .itemIcon[data-v-44364970]{width:%?50?%;height:%?50?%}.itemTitle[data-v-44364970]{width:90%;height:auto}.categorys[data-v-44364970]{width:100%;background-color:#fff}.categorys .item[data-v-44364970]{position:relative;padding:%?20?% %?15?%;text-align:center}.categorys .item.select[data-v-44364970]{background-color:#fff!important;color:#000!important}.categorys .item .select-line[data-v-44364970]{position:absolute;top:50%;right:%?-8?%;height:50%;width:%?10?%;border-radius:%?30?%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}',""]),t.exports=e},b1a6:function(t,e,o){var i=o("2baa");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("90b74ece",i,!0,{sourceMap:!1,shadowMode:!1})},b39d:function(t,e,o){"use strict";o.d(e,"b",(function(){return n})),o.d(e,"c",(function(){return a})),o.d(e,"a",(function(){return i}));var i={tnLoading:o("c554").default},n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"tn-load-more-class tn-load-more"},[o("v-uni-view",{staticClass:"tn-load-more__wrap",class:[t.backgroundColorClass],style:[t.loadStyle]},[o("v-uni-view",{staticClass:"tn-load-more__line"}),o("v-uni-view",{staticClass:"tn-load-more__content",class:[{"tn-load-more__content--more":"loadmore"===t.status||"nomore"===t.status}]},[o("v-uni-view",{staticClass:"tn-load-more__loading"},[o("tn-loading",{staticClass:"tn-load-more__loading__icon",attrs:{mode:t.loadingIconType,show:"loading"===t.status&&t.loadingIcon,color:t.loadingIconColor}})],1),o("v-uni-view",{staticClass:"tn-load-more__text",class:[t.fontColorClass,{"tn-load-more__text--dot":"nomore"===t.status&&t.dot}],style:[t.loadTextStyle]},[t._v(t._s(t.showText))])],1),o("v-uni-view",{staticClass:"tn-load-more__line"})],1)],1)},a=[]},b4f0:function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.checkUserIsLogin=void 0,o("bf0f");o("0c8e");var i=o("edc8");e.checkUserIsLogin=function(){return new Promise((function(t,e){var o=uni.getStorageSync(i.TOKEN_KEY);return o?t():e()}))}},b572:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("dc8a");var n=i(o("7caa")),a={name:"tn-load-more",mixins:[n.default],props:{status:{type:String,default:"loadmore"},loadingIcon:{type:Boolean,default:!0},loadingIconType:{type:String,default:"circle"},loadingIconColor:{type:String,default:""},loadText:{type:Object,default:function(){return{loadmore:"加载更多",loading:"正在加载...",nomore:"没有更多了"}}},dot:{type:Boolean,default:!1},customStyle:{type:Object,default:function(){return{}}}},computed:{loadStyle:function(){var t={};return this.backgroundColorStyle&&(t.backgroundColor=this.backgroundColorStyle),Object.keys(this.customStyle).length>0&&Object.assign(t,this.customStyle),t},loadTextStyle:function(){var t={};return this.fontColorStyle&&(t.color=this.fontColorStyle),this.fontSizeStyle&&(t.fontSize=this.fontSizeStyle,t.lineHeight=this.$t.string.getLengthUnitValue(this.fontSize+2,this.fontUnit)),t},showText:function(){var t="";return t="loadmore"===this.status?this.loadText.loadmore||"加载更多":"loading"===this.status?this.loadText.loading||"正在加载...":"nomore"===this.status&&this.dot?this.dotText:this.loadText.nomore||"没有更多了",t}},data:function(){return{dotText:"●"}},methods:{loadMore:function(){"loadmore"===this.status&&this.$emit("loadmore")}}};e.default=a},b6ce:function(t,e,o){"use strict";o.r(e);var i=o("6dba"),n=o("d1f6");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("bcd9");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"622832e3",null,!1,i["a"],void 0);e["default"]=s.exports},b8c0:function(t,e,o){var i=o("4e1f");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("9be6a0f6",i,!0,{sourceMap:!1,shadowMode:!1})},b917:function(t,e,o){"use strict";var i=o("27e2c"),n=o.n(i);n.a},ba52:function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa");var i={props:{couponNum:{type:Number,default:0},couponMoney:{type:Number,default:0}},methods:{subCoupon:function(){this.$emit("subCoupon")}}};e.default=i},bbaa:function(t,e,o){var i=o("4e70");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("22cda32c",i,!0,{sourceMap:!1,shadowMode:!1})},bcd9:function(t,e,o){"use strict";var i=o("1557"),n=o.n(i);n.a},bd08:function(t,e,o){"use strict";o.r(e);var i=o("b572"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},be19:function(t,e,o){"use strict";o.r(e);var i=o("204c"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},c28b:function(t,e,o){"use strict";var i=o("6703"),n=o.n(i);n.a},c554:function(t,e,o){"use strict";o.r(e);var i=o("7dd5"),n=o("5ed6");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("c28b");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"198243dd",null,!1,i["a"],void 0);e["default"]=s.exports},c825:function(t,e,o){"use strict";var i=o("b8c0"),n=o.n(i);n.a},c8a1:function(t,e,o){"use strict";var i=o("b1a6"),n=o.n(i);n.a},cb66:function(t,e,o){"use strict";o.r(e);var i=o("9fa2"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},cbbc:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("fd3c"),o("8f71"),o("bf0f"),o("dc8a"),o("c223"),o("01a2"),o("e39c"),o("bd06"),o("aa9c"),o("5c47"),o("2c10"),o("2797"),o("e838"),o("5ef2");var n=i(o("b7c7")),a=i(o("2634")),r=i(o("2fdc")),s=i(o("2d34")),d=i(o("7610")),c=i(o("05a0")),l=i(o("e450")),u=i(o("033a")),p=o("eda6"),f=o("06f9"),h=o("47da"),g=o("4f43"),v=(o("8729"),o("b4f0"),i(o("d82f")),o("0c8e")),m=o("edc8"),_={components:{GoodsList:d.default,ShoppingCart:c.default,StoreNav:l.default},mixins:[s.default],data:function(){return{optionsData:{sid:"",spellriceId:"",tableId:"",orderId:""},showWriteVouchers:!1,vouchersList:[],searchValue:"",storeInfo:{bgImage:"http://qny.wdsp666.com/%E7%A6%8F%E8%A2%8B%E8%83%8C%E6%99%AF%E5%9B%BE/store-title.jpg",storeInfo:{id:"",title:"",logo:"",score:0,sendPrice:0,selfPickupMinPrice:0,deliveryPrice:0,deliveryTime:0,content:"",notice:"",mobile:"",address:"",isRest:0,isInBusiness:0,activityLabels:[],images:[],qualification:[],business_hours_cn:"",coupons:!1,is_favorite:!1,delivery_fee_mode:1,address_type:0,delivery_free_price:0,default_display_selection:null,storeShow:{},top_option_takeout:"外卖送",top_option_selfPickUp:"到店取",vip_is_open:0,vip_config:[]}},goodsData:[],isLogin:!0,isRefreshData:!1,currentNavIndex:0,renderTemplateFlag:[!0,!1,!1],currentPageScrollPosition:0,componentId:"",navRectInitCount:0,navRectInfo:{top:0,height:0,opacity:0},goodsPreviewRectInfo:{stickyDistance:0,height:0},showUpdateModal:!1,updateInfo:{storeTitle:"每日优鲜11",storeContent:'平台已升级,请到支付宝搜索"我的上铺"'},showOrderingInformationModal:!1,orderingInformation:{banner:[],data1:{title:"",content:""},data2:{title:"",content:""}},loadingShow:!1,pageShowType:2,delivery_type:!1,expansion_show:!1,old_discount:0,new_discount:0,expansion_data:null,new_description:"无门槛",categoryId:"",goodPage:1,categoryIndex:0,is_showGoods:!1,is_firstShowGoods:!0,isReachBottom:!1,isNextCategory:!1,showloadNext:!1,showloadNext1:!1,is_goods_render:!1,chrid:"",loadText:{},is_api_shop:!1,storeCode:"",brand:"",cartId:0,codeInfo:null,table_name:"",renshu:2,showOrderingRenshuModal:!1,isScan:!1,bakurl:"",showNavbarBack:!1,is_show_switch:!0,previous:"",encrypted_data:"",write_off_type:"alipay",is_promotion:-1,categoryGoodsNum:[],clientYStart:0,clientYEnd:0,lastScrollTop:0,topScrollCount:0,is_renovate:!1,is_top:!1,refreshCategoryTitleRectInfo:!1,categoryGoods:[],goods:[]}},computed:{topNavbarStyle:function(){var t={};return t.height="".concat(this.navBarInfo.height,"px"),t.opacity=this.navRectInfo.opacity,t},currentNavStyle:function(){var t=this;return function(e){var o={};return o.display=t.currentNavIndex===e?"block":"none",o}},isRest:function(){return 1==this.storeInfo.storeInfo.isRest||0==this.storeInfo.storeInfo.isInBusiness}},onLoad:function(t){var e=t._sid||"";e?uni.setStorageSync("supplier_sid",e):uni.getStorageSync("__sid")&&(e=uni.getStorageSync("__sid"),uni.setStorageSync("supplier_sid",e)),this.goodsList(e),this.loadingShow=!0,this.handleStoreOptions(t),this.chrid=null!==t&&void 0!==t&&t.goods_id?t.goods_id:"",this.componentId=this.$t.uuid(),console.log("this.componentId",this.componentId),this.initCustomNavBarInfo(),this.openSubscribeModal()},onShow:function(){this.is_goods_render&&this.getStoreShoppingCartData()},onReady:function(){var t=this;setTimeout((function(){t._getStoreNavRectInfo()}),150)},onHide:function(){var t=this;this.$nextTick((function(){setTimeout((function(){t.loadingShow=!1}),1e3)}))},onUnload:function(){var t=this;this.$nextTick((function(){setTimeout((function(){t.loadingShow=!1}),1e3)}))},onPageScroll:function(t){var e=t.scrollTop;this.currentPageScrollPosition=e,this.lastScrollTop=e,this._calcTopNavOpacity(e)},onReachBottom:function(){var t,e,o=this;if(console.log("触底了"),0===this.currentNavIndex&&2==this.pageShowType){if(this.isReachBottom=!0,this.is_firstShowGoods)return;if(this.is_showGoods)return void(this.isNextCategory=!this.isNextCategory);this.showloadNext=!0,setTimeout((function(){o.showloadNext=!1}),500),this.goodPage++,this.getStoreGoodsList(!1)}1===this.currentNavIndex&&((null===(t=this.$refs)||void 0===t||null===(e=t.appraiseRef)||void 0===e?void 0:e.loadMoreCommentData)&&this.$refs.appraiseRef.loadMoreCommentData())},methods:{goodsList:function(t){var e=this;return(0,r.default)((0,a.default)().mark((function o(){var i,n,r;return(0,a.default)().wrap((function(o){while(1)switch(o.prev=o.next){case 0:return i=e,o.prev=1,o.next=4,u.default.goodsListNoLoginApi({sid:t,cid:0});case 4:n=o.sent,r=n.data,console.log("成功"),r&&(i.goods=r.goods),o.next=13;break;case 10:o.prev=10,o.t0=o["catch"](1),console.error("Error in goodsList:",o.t0);case 13:case"end":return o.stop()}}),o,null,[[1,10]])})))()},onReachBottom1:function(){var t,e,o=this;if(console.log("触底了"),0===this.currentNavIndex&&2==this.pageShowType){if(this.isReachBottom=!0,this.is_firstShowGoods)return;if(this.is_showGoods)return void(this.isNextCategory=!this.isNextCategory);this.showloadNext=!0,setTimeout((function(){o.showloadNext=!1}),500),this.goodPage++,this.getStoreGoodsList(!1)}1===this.currentNavIndex&&((null===(t=this.$refs)||void 0===t||null===(e=t.appraiseRef)||void 0===e?void 0:e.loadMoreCommentData)&&this.$refs.appraiseRef.loadMoreCommentData())},handleTouchStart:function(t){this.clientYStart=t.touches[0].clientY},handleTouchEnd:function(t){this.clientYEnd=t.changedTouches[0].clientY,this.clientYEnd-this.clientYStart<0&&(this.topScrollCount=0,this.is_top=!1,this.is_renovate=!1),this.clientYStart<this.clientYEnd&&0===this.lastScrollTop&&(this.topScrollCount++,1===this.topScrollCount?this.is_top=!0:this.topScrollCount>1&&(this.is_renovate=!0)),this.clientYStart=0},getBrand:function(){var t=this;return(0,r.default)((0,a.default)().mark((function e(){return(0,a.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",(0,p.getBrandApi)(t.optionsData.sid).then((function(e){console.log("res",e),console.log("res.type",e.type),e.type&&(t.brand=e.type,t.storeCode=e.code)})).catch((function(t){console.log("err",t)})));case 1:case"end":return e.stop()}}),e)})))()},getOrderDinnerStoreId:function(){var t=this;return(0,r.default)((0,a.default)().mark((function e(){var o;return(0,a.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return o=t,e.abrupt("return",(0,p.getOrderDinnerStoreIdApi)({type:o.brand,storeCode:o.storeCode}).then((function(e){console.log("res",e),e.sid==t.optionsData.sid&&(console.log("here"),t.is_api_shop=!0)})));case 2:case"end":return e.stop()}}),e)})))()},handleSearchEvent:function(t){var e=this;this.searchValue=t,this.goodPage=1,this.categoryId="",this.is_showGoods=!1,this.goodsData=[],uni.pageScrollTo({scrollTop:0,duration:0}),this.$nextTick((function(){setTimeout((function(){e.getStoreGoodsList()}),150)}))},searchPromotion:function(t){var e=this;console.log("searchPromotion",t),this.is_promotion=t,this.goodPage=1,this.categoryId="",this.is_showGoods=!1,this.goodsData=[],uni.pageScrollTo({scrollTop:0,duration:0}),this.$nextTick((function(){setTimeout((function(){e.getStoreGoodsList()}),150)}))},handleSubmitOrderRefreshEvent:function(){this.isRefreshData=!0},handleCategoryChangeEvent:function(t,e,o){if(console.log("切换分类"),3===o)this.categoryIndex!=e&&(this.isReachBottom=!1,this.topScrollCount=0,this.is_renovate=!1,this.is_top=!1,this.is_showGoods=!1,this.is_firstShowGoods=!0,this.categoryId=t,this.categoryIndex=e,this.goodPage=1,this.getStoreGoodsList(!1));else if(2==this.pageShowType){this.isReachBottom=!1,this.topScrollCount=0,this.is_renovate=!1,this.is_top=!1,this.is_showGoods=!1,this.is_firstShowGoods=!0,this.categoryId=t,this.categoryIndex=e,this.goodPage=1;for(var i=!1,n=0;n<this.categoryGoods.length;n++)if(this.categoryGoods[n].id===t){if(this.categoryGoods[n].goods&&this.categoryGoods[n].goods.length>0&&this.categoryGoods[n].goods.length<15){i=!0;break}if(this.categoryGoods[n].goods&&15==this.categoryGoods[n].goods.length)this.goodsData=this.categoryGoods,this.goodPage=2;else if(this.categoryGoods[n].goods&&this.categoryGoods[n].goods.length>15){i=!0;break}}i?(console.log("获取缓存"),this.goodsData=this.categoryGoods):this.getStoreGoodsList(!1);var a=e-1,r=e+1;a>=0&&this.loadCategoryData(this.categoryGoods[a].id),r<this.categoryGoods.length&&this.loadCategoryData(this.categoryGoods[r].id)}else this.isReachBottom=!1,this.topScrollCount=0,this.is_renovate=!1,this.is_top=!1,this.is_showGoods=!1,this.is_firstShowGoods=!0,this.categoryId=t,this.categoryIndex=e,this.goodPage=1,this.getStoreGoodsList(!1)},loadCategoryData:function(t){var e=this;console.log("预加载");for(var o=!1,i=0;i<this.categoryGoods.length;i++)if(this.categoryGoods[i].id===t&&this.categoryGoods[i].goods&&this.categoryGoods[i].goods.length>0){o=!0;break}o?this.goodsData=this.categoryGoods:(0,p.getStoreGoodsListApi)({sid:this.optionsData.sid,search:this.searchValue,orderId:this.optionsData.orderId,cid:t,page:1,is_api_shop:this.is_api_shop,storeCode:this.storeCode,api_brand:this.brand,order_type:this.optionsData.tableId?"tangshi":"takeout",encrypted_data:this.encrypted_data,write_off_type:this.write_off_type,is_promotion:this.is_promotion,chrid:this.chrid}).then((function(t){var o=t.result.goods.map((function(t){return console.log("goodItem2",t),{id:t.id,title:t.title,image:t.thumb,label:(null===t||void 0===t?void 0:t.label)||"",content:(null===t||void 0===t?void 0:t.content)||"",sailed:(null===t||void 0===t?void 0:t.sailed)||0,price:(null===t||void 0===t?void 0:t.price)||0,oldPrice:(null===t||void 0===t?void 0:t.old_price)||(null===t||void 0===t?void 0:t.price)||0,specOptions:1===(null===t||void 0===t?void 0:t.is_attrs)||1===(null===t||void 0===t?void 0:t.is_materials)||1===(null===t||void 0===t?void 0:t.is_options)?1:0,num:(null===t||void 0===t?void 0:t.totalnum)||0,min:0,max:(null===t||void 0===t?void 0:t.total)||0,is_tuangouquan:(null===t||void 0===t?void 0:t.is_tuangouquan)||!1,is_api:(null===t||void 0===t?void 0:t.is_api)||0,good_code:(null===t||void 0===t?void 0:t.code)||"",brand:(null===t||void 0===t?void 0:t.brand)||"",storeCode:(null===t||void 0===t?void 0:t.storeCode)||"",bargain_price:(null===t||void 0===t?void 0:t.bargain_price)||"",caigou_price:null===t||void 0===t?void 0:t.caigou_price,total:null===t||void 0===t?void 0:t.total,number:null===t||void 0===t?void 0:t.number}}));e.categoryGoods[t.result.cindex]&&e.categoryGoods[t.result.cindex].goods?e.categoryGoods[t.result.cindex].goods=o:e.categoryGoods=e.goodsData,console.log("预加载的数据",e.categoryGoods)})).catch((function(t){console.log(t)}))},getStoreInfo:function(){var t=this;this.showOrderingInformationModal||this.getStoreGoodsList(!1,null,!0),(0,p.getStoreInfoApi)({sid:this.optionsData.sid,table_id:this.optionsData.tableId,storeCode:this.StoreCode,brand:this.brand}).then((function(e){var o,i,n,a;t.isLogin=!0;var r,s,d=e.store;(t.isScan?3==d.return_page?t.showNavbarBack=!1:(t.showNavbarBack=!0,1==d.return_page&&(t.bakurl="")):t.showNavbarBack=!0,t.showOrderingInformationModal=1==(null===d||void 0===d?void 0:d.is_notice),t.orderingInformation.banner=(null===d||void 0===d?void 0:d.noticeThumb)||[],t.orderingInformation.data1.title=(null===d||void 0===d?void 0:d.notice1_title)||"",t.orderingInformation.data1.content=(null===d||void 0===d?void 0:d.notice1_description)||"",t.orderingInformation.data2.title=(null===d||void 0===d?void 0:d.notice2_title)||"",t.orderingInformation.data2.content=(null===d||void 0===d?void 0:d.notice2_description)||"",t.optionsData.tableId)&&(t.showOrderingRenshuModal=1==(null===d||void 0===d||null===(r=d.tangshi)||void 0===r?void 0:r.person_num_status),t.showOrderingRenshuModal&&t.codeInfo.tableInfo&&1!=t.codeInfo.tableInfo.status&&(t.showOrderingRenshuModal=!1),t.storeInfo.storeInfo.person_num_image=(null===d||void 0===d||null===(s=d.tangshi)||void 0===s?void 0:s.image_url)||"",t.table_name=d&&d.table?d.table.title:"",t.storeInfo.storeInfo.table=d&&d.table?d.table:"");t.storeInfo.storeInfo.id=(null===d||void 0===d?void 0:d.id)||"",t.storeInfo.storeInfo.title=(null===d||void 0===d?void 0:d.title)||"",t.storeInfo.storeInfo.logo=(null===d||void 0===d?void 0:d.logo)||"",t.storeInfo.storeInfo.score=(null===d||void 0===d?void 0:d.score)||5,t.storeInfo.storeInfo.sendPrice=(null===d||void 0===d?void 0:d.send_price)||0,t.storeInfo.storeInfo.selfPickupMinPrice=(null===d||void 0===d?void 0:d.self_pickup_min_price)||0,t.storeInfo.storeInfo.deliveryPrice=(null===d||void 0===d?void 0:d.delivery_price)||0,t.storeInfo.storeInfo.deliveryTime=(null===d||void 0===d?void 0:d.delivery_time)||0,t.storeInfo.storeInfo.notice=(null===d||void 0===d?void 0:d.notice)||"",t.storeInfo.storeInfo.content=(null===d||void 0===d?void 0:d.content)||"",t.storeInfo.storeInfo.mobile=(null===d||void 0===d?void 0:d.telephone)||"",t.storeInfo.storeInfo.address=(null===d||void 0===d?void 0:d.address)||"",t.storeInfo.storeInfo.isRest=(null===d||void 0===d?void 0:d.is_rest)||0,t.storeInfo.storeInfo.isInBusiness=(null===d||void 0===d?void 0:d.is_in_business)||0,t.storeInfo.storeInfo.coupons=(null===d||void 0===d?void 0:d.coupon)||[],t.storeInfo.storeInfo.delivery_type=null===d||void 0===d?void 0:d.delivery_type,t.storeInfo.storeInfo.is_favorite=(null===d||void 0===d?void 0:d.is_favorite)||!1,t.storeInfo.storeInfo.delivery_title=(null===d||void 0===d?void 0:d.delivery_title)||"",t.storeInfo.storeInfo.delivery_fee_mode=(null===d||void 0===d?void 0:d.delivery_fee_mode)||1,t.storeInfo.storeInfo.address_type=(null===d||void 0===d?void 0:d.address_type)||0,t.storeInfo.storeInfo.deliveryFreePrice=(null===d||void 0===d?void 0:d.delivery_free_price)||0,t.storeInfo.storeInfo.distance=(null===d||void 0===d?void 0:d.distance)||0,t.storeInfo.class_type=(null===d||void 0===d?void 0:d.class_type)||2,t.storeInfo.table=(null===d||void 0===d?void 0:d.table)||[],t.storeInfo.activity=(null===d||void 0===d?void 0:d.activity)||{},t.storeInfo.storeInfo.default_display_selection=+(null===d||void 0===d||null===(o=d.data)||void 0===o?void 0:o.default_display_selection)||1,t.storeInfo.storeInfo.storeShow=(null===d||void 0===d?void 0:d.storeShow)||{},t.is_api_shop&&(t.storeInfo.storeInfo.address=uni.getStorageSync(t.brand+"_address")),t.storeInfo.storeInfo.business_hours_cn=d.business_hours_cn||"",t.storeInfo.storeInfo.notice1_title=d.notice1_title||"",t.storeInfo.storeInfo.notice1_description=d.notice1_description||"",t.storeInfo.storeInfo.notice2_title=d.notice2_title||"",t.storeInfo.storeInfo.notice2_description=d.notice2_description||"",t.storeInfo.storeInfo.top_option_takeout=(null===d||void 0===d?void 0:d.top_option_takeout)||"外卖送",t.storeInfo.storeInfo.top_option_selfPickUp=(null===d||void 0===d?void 0:d.top_option_selfPickUp)||"到店取",console.log(null===(i=t.storeInfo.storeInfo)||void 0===i?void 0:i.business_hours_cn,"ssss");var c=(null===d||void 0===d?void 0:d.thumbs)||[];t.storeInfo.storeInfo.images=c.map((function(t){return t.image}));var l=d.qualification;t.storeInfo.storeInfo.qualification=Object.keys(l).map((function(t){var e=l[t];return e.thumb})).filter((function(t){return""!=t}));var u=[];null!==d&&void 0!==d&&null!==(n=d.activity)&&void 0!==n&&null!==(a=n.labels)&&void 0!==a&&a.length&&d.activity.labels.length>0&&(u=u.concat(d.activity.labels.map((function(t){return t.title})))),t.storeInfo.storeInfo.activityLabels=u,t.storeInfo.multiple_cart_is_open=(null===d||void 0===d?void 0:d.multiple_cart_is_open)||0,t.storeInfo.multiple_cart_add_fee=+(null===d||void 0===d?void 0:d.multiple_cart_add_fee)||0,t.storeInfo.storeInfo.vip_is_open=(null===d||void 0===d?void 0:d.vip_is_open)||0,t.storeInfo.storeInfo.vip_config=(null===d||void 0===d?void 0:d.vip_config)||[],t.pageShowType=d.pageShowType})).catch((function(e){console.error("[store-template-1]获取店铺信息失败",e),"请重新登录"==e.msg?t.isLogin=!1:(0,h.showModal)({title:"提示",content:e.msg||"获取店铺信息失败",callback:function(){(0,g.navBack)()}})}))},changTabs:function(t,e){var o=this;0==t&&(this.is_showGoods=!1,this.goodPage=1),console.log("id,idx,this.goodsData",t,e,this.goodsData),(0,p.getStoreGoodsListApi)({sid:this.optionsData.sid,search:this.searchValue,orderId:this.optionsData.orderId,cid:this.categoryId?this.categoryId:this.goodsData[0].id,child_id:t,page:1,storeCode:this.storeCode,order_type:this.optionsData.tableId?"tangshi":"takeout",encrypted_data:this.encrypted_data,write_off_type:this.write_off_type}).then((function(t){if(console.log("res加载商品中、分类",t),1==o.pageShowType&&(o.goodsData=t.cate_has_goods.map((function(t){var e=t.goods.map((function(t){return{id:t.id,title:t.title,image:t.thumb,label:(null===t||void 0===t?void 0:t.label)||"",content:(null===t||void 0===t?void 0:t.content)||"",sailed:(null===t||void 0===t?void 0:t.sailed)||0,price:(null===t||void 0===t?void 0:t.price)||0,oldPrice:(null===t||void 0===t?void 0:t.old_price)||(null===t||void 0===t?void 0:t.price)||0,specOptions:1===(null===t||void 0===t?void 0:t.is_attrs)||1===(null===t||void 0===t?void 0:t.is_materials)||1===(null===t||void 0===t?void 0:t.is_options)?1:0,num:(null===t||void 0===t?void 0:t.totalnum)||0,min:0,max:(null===t||void 0===t?void 0:t.total)||0,is_tuangouquan:(null===t||void 0===t?void 0:t.is_tuangouquan)||!1,is_api:(null===t||void 0===t?void 0:t.is_api)||0,good_code:(null===t||void 0===t?void 0:t.code)||"",brand:(null===t||void 0===t?void 0:t.brand)||"",storeCode:(null===t||void 0===t?void 0:t.storeCode)||"",bargain_price:(null===t||void 0===t?void 0:t.bargain_price)||"",caigou_price:null===t||void 0===t?void 0:t.caigou_price,total:null===t||void 0===t?void 0:t.total,number:null===t||void 0===t?void 0:t.number}}));return{id:t.id,title:t.title,thumb:t.thumb,description:t.description,category_min_fee:t.category_min_fee,is_mandatory:t.is_mandatory,goods:e,child:t.child,is_showtime:t.is_showtime,week:t.week,start_time:t.start_time,end_time:t.end_time}}))),2==o.pageShowType||3==o.pageShowType){var e,i=t.result.goods.map((function(t){return console.log("goodItem1",t),{id:t.id,title:t.title,image:t.thumb,label:(null===t||void 0===t?void 0:t.label)||"",content:(null===t||void 0===t?void 0:t.content)||"",sailed:(null===t||void 0===t?void 0:t.sailed)||0,price:(null===t||void 0===t?void 0:t.price)||0,oldPrice:(null===t||void 0===t?void 0:t.old_price)||(null===t||void 0===t?void 0:t.price)||0,specOptions:1===(null===t||void 0===t?void 0:t.is_attrs)||1===(null===t||void 0===t?void 0:t.is_materials)||1===(null===t||void 0===t?void 0:t.is_options)?1:0,num:(null===t||void 0===t?void 0:t.totalnum)||0,min:0,max:(null===t||void 0===t?void 0:t.total)||0,is_tuangouquan:(null===t||void 0===t?void 0:t.is_tuangouquan)||!1,is_api:(null===t||void 0===t?void 0:t.is_api)||0,good_code:(null===t||void 0===t?void 0:t.code)||"",brand:(null===t||void 0===t?void 0:t.brand)||"",storeCode:(null===t||void 0===t?void 0:t.storeCode)||"",bargain_price:(null===t||void 0===t?void 0:t.bargain_price)||"",caigou_price:null===t||void 0===t?void 0:t.caigou_price,total:null===t||void 0===t?void 0:t.total,number:null===t||void 0===t?void 0:t.number}}));if(i.length<t.result.psize&&(o.is_showGoods=!0),1==o.goodPage)if(o.searchValue&&o.categoryId){var a=o.goodsData.findIndex((function(e){return e.id==t.result.cid}));o.goodsData[a].goods=i}else o.goodsData=t.result.category.map((function(t){return{id:t.id,title:t.title,thumb:t.thumb,description:t.description,category_min_fee:t.category_min_fee,is_mandatory:t.is_mandatory,goods:[],child:null!==t&&void 0!==t&&t.child?t.child:[],is_showtime:t.is_showtime,week:t.week,start_time:t.start_time,end_time:t.end_time}})),o.categoryIndex=t.result.cindex,o.goodsData[t.result.cindex].goods=i;else(e=o.goodsData[t.result.cindex].goods).push.apply(e,(0,n.default)(i))}o.getStoreShoppingCartData()})).catch((function(t){console.log(t)}))},getStoreGoodsList:function(){var t=this,e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.isReachBottom=!1,this.topScrollCount=0,this.is_renovate=!1,this.is_top=!1,this.isNextCategory=!1,e&&(this.loadingShow=!0),(0,p.getStoreGoodsListApi)({sid:this.optionsData.sid,search:this.searchValue,orderId:this.optionsData.orderId,cid:this.categoryId,page:this.goodPage,is_api_shop:this.is_api_shop,storeCode:this.storeCode,api_brand:this.brand,order_type:this.optionsData.tableId?"tangshi":"takeout",encrypted_data:this.encrypted_data,write_off_type:this.write_off_type,is_promotion:this.is_promotion,chrid:this.chrid}).then((function(e){if(console.log("res加载商品中",e),!e.cate_has_goods&&!e.result)return t.loadingShow=!1,void(t.goodsData=[]);if(e.template_page>=0?t.pageShowType=e.template_page+1:t.pageShowType=e.result.template_page+1,console.log("this.pageShowType",t.pageShowType),1==t.pageShowType&&(t.goodsData=e.cate_has_goods.map((function(t){var e=t.goods.map((function(t){return{id:t.id,title:t.title,image:t.thumb,label:(null===t||void 0===t?void 0:t.label)||"",content:(null===t||void 0===t?void 0:t.content)||"",sailed:(null===t||void 0===t?void 0:t.sailed)||0,price:(null===t||void 0===t?void 0:t.price)||0,oldPrice:(null===t||void 0===t?void 0:t.old_price)||(null===t||void 0===t?void 0:t.price)||0,specOptions:1===(null===t||void 0===t?void 0:t.is_attrs)||1===(null===t||void 0===t?void 0:t.is_materials)||1===(null===t||void 0===t?void 0:t.is_options)?1:0,num:(null===t||void 0===t?void 0:t.totalnum)||0,min:0,max:(null===t||void 0===t?void 0:t.total)||0,is_tuangouquan:(null===t||void 0===t?void 0:t.is_tuangouquan)||!1,is_api:(null===t||void 0===t?void 0:t.is_api)||0,good_code:(null===t||void 0===t?void 0:t.code)||"",brand:(null===t||void 0===t?void 0:t.brand)||"",storeCode:(null===t||void 0===t?void 0:t.storeCode)||"",bargain_price:(null===t||void 0===t?void 0:t.bargain_price)||"",caigou_price:null===t||void 0===t?void 0:t.caigou_price,total:null===t||void 0===t?void 0:t.total,number:null===t||void 0===t?void 0:t.number}}));return{id:t.id,title:t.title,thumb:t.thumb,description:t.description,category_min_fee:t.category_min_fee,is_mandatory:t.is_mandatory,goods:e,child:t.child,is_showtime:t.is_showtime,week:t.week,start_time:t.start_time,end_time:t.end_time}}))),2==t.pageShowType||3==t.pageShowType){console.log("res",e);var i,a=e.result.goods.map((function(t){return console.log("goodItem2",t),{id:t.id,title:t.title,image:t.thumb,label:(null===t||void 0===t?void 0:t.label)||"",content:(null===t||void 0===t?void 0:t.content)||"",sailed:(null===t||void 0===t?void 0:t.sailed)||0,price:(null===t||void 0===t?void 0:t.price)||0,oldPrice:(null===t||void 0===t?void 0:t.old_price)||(null===t||void 0===t?void 0:t.price)||0,specOptions:1===(null===t||void 0===t?void 0:t.is_attrs)||1===(null===t||void 0===t?void 0:t.is_materials)||1===(null===t||void 0===t?void 0:t.is_options)?1:0,num:(null===t||void 0===t?void 0:t.totalnum)||0,min:0,max:(null===t||void 0===t?void 0:t.total)||0,is_tuangouquan:(null===t||void 0===t?void 0:t.is_tuangouquan)||!1,is_api:(null===t||void 0===t?void 0:t.is_api)||0,good_code:(null===t||void 0===t?void 0:t.code)||"",brand:(null===t||void 0===t?void 0:t.brand)||"",storeCode:(null===t||void 0===t?void 0:t.storeCode)||"",bargain_price:(null===t||void 0===t?void 0:t.bargain_price)||"",caigou_price:null===t||void 0===t?void 0:t.caigou_price,total:null===t||void 0===t?void 0:t.total,number:null===t||void 0===t?void 0:t.number}}));if(a.length<15?t.showloadNext1=!0:t.showloadNext1=!1,a.length<e.result.psize&&(t.is_showGoods=!0),1==t.goodPage)if(t.searchValue&&t.categoryId){var r=t.goodsData.findIndex((function(t){return t.id==e.result.cid}));t.goodsData[r].goods=a}else t.goodsData=e.result.category.map((function(t){return{id:t.id,title:t.title,thumb:t.thumb,description:t.description,category_min_fee:t.category_min_fee,is_mandatory:t.is_mandatory,goods:[],child:null!==t&&void 0!==t&&t.child?t.child:[],is_showtime:t.is_showtime,week:t.week,start_time:t.start_time,end_time:t.end_time}})),t.categoryIndex=e.result.cindex,t.goodsData[e.result.cindex].goods=a;else(i=t.goodsData[e.result.cindex].goods).push.apply(i,(0,n.default)(a));2==t.pageShowType&&a.length<15&&(t.categoryGoods[e.result.cindex]&&t.categoryGoods[e.result.cindex].goods?t.categoryGoods[e.result.cindex].goods=t.goodsData[e.result.cindex].goods:t.categoryGoods=t.goodsData,0==e.result.cindex&&t.loadCategoryData(e.result.category[e.result.cindex+1].id))}t.is_firstShowGoods=!1,console.log("是是是是是是是是是是",t.goodsData),console.log("this.categoryGoods",t.categoryGoods),t.loadingShow=!1,t.is_goods_render=!0,t.getStoreShoppingCartData(),t.$nextTick((function(){(0,h.closeLoading)()})),o&&t.$nextTick((function(){t.refreshCategoryTitleRectInfo=!0}))})).catch((function(e){console.error("[store-template-1]获取店铺商品列表失败",e),t.goodsData=[],t.loadingShow=!1,t.$nextTick((function(){(0,h.closeLoading)()}))}))},getCodeInfoByCode:function(t){var e=this;return(0,r.default)((0,a.default)().mark((function o(){var i;return(0,a.default)().wrap((function(o){while(1)switch(o.prev=o.next){case 0:return o.next=2,(0,p.getCodeInfoByCodeApi)(t);case 2:i=o.sent,e.sid=i.sid,e.table_id=i.table_id,e.optionsData.sid=i.sid,e.optionsData.tableId=i.table_id,e.locationSuccessFlag=!0,e.codeInfo=i,e.optionsData.tableId&&e.websocket_connect();case 10:case"end":return o.stop()}}),o)})))()},handleStoreOptions:function(t){var e=this;return(0,r.default)((0,a.default)().mark((function o(){var i,n,r,s,d,c,l;return(0,a.default)().wrap((function(o){while(1)switch(o.prev=o.next){case 0:if(t.brand&&(e.brand=t.brand,e.storeCode=t.storeCode),i=0,!t.q){o.next=19;break}if(n=decodeURIComponent(t.q),console.log("页面参数++++",n),r=n.match(/sid=(\d+)/),r&&(i=r[1]||""),s=n.match(/code=([^&]+)/),!s){o.next=13;break}return d=s[1]||"",o.next=12,e.getCodeInfoByCode(d);case 12:i=e.sid;case 13:c=n.match(/from=([^&]+)/),l=n.match(/table_id=([^&]+)/),l=l?l[1]:"",(c&&"scan"==c[1]||s||l)&&(e.isScan=!0,e.bakurl="/store-page/store-index/store-index?sid=".concat(i||"")),o.next=20;break;case 19:i=t.sid||"";case 20:if(1==e.vuex_appType&&(i=e.vuex_sid),i){o.next=24;break}return(0,h.showModal)({title:"提示",content:"缺少必要参数",callback:function(){(0,g.navBack)()}}),o.abrupt("return");case 24:if(t.table_id&&(e.is_show_switch=!1,e.optionsData.tableId=t.table_id),t.is_scan&&(e.isScan=!0),e.optionsData.sid=i,e.optionsData.orderId=t.order_id||"",e.brand){o.next=31;break}return o.next=31,e.getBrand();case 31:return console.log("options",t),t.encrypted_data&&(e.encrypted_data=t.encrypted_data),t.write_off_type&&(e.write_off_type=t.write_off_type),o.next=36,e.getOrderDinnerStoreId();case 36:e.getPageData(),t.navType&&(e.previous=t.navType),e.checkExchange(i),Object.prototype.hasOwnProperty.call(t,"delivery_type")&&(e.delivery_type=t.delivery_type,console.log("options.delivery_type",e.delivery_type)),1!=t.delivery_type&&2!=t.delivery_type||(1==t.delivery_type?e.delivery_type=!1:e.delivery_type=!0);case 41:case"end":return o.stop()}}),o)})))()},getPageData:function(){this.getStoreInfo()},getWriteVouchers:function(){var t=this;(0,p.searchRecordApi)({sid:this.optionsData.sid}).then((function(e){e.data.length>0&&(t.vouchersList=e.data,t.showWriteVouchers=!0)}))},reloadPageData:function(){var t=this;uni.pageScrollTo({scrollTop:0,duration:0}),this.$nextTick((function(){setTimeout((function(){t.goodsData=[],t.getPageData(),(0,v.getTokenFromCache)()&&t.getStoreShoppingCartData()}),150)}))},handleNavChangeEvent:function(t){this.renderTemplateFlag[t]||(this.renderTemplateFlag[t]=!0),this.currentPageScrollPosition>this.navRectInfo.top?uni.pageScrollTo({scrollTop:this.navRectInfo.top-this.navBarInfo.height,duration:0}):uni.pageScrollTo({scrollTop:this.currentPageScrollPosition,duration:0})},handleGoodsListRenderFinishEvent:function(){var t=this;console.log("nav","商品加载完毕"),this.loadingShow=!1,setTimeout((function(){t.loadingShow=!1}),1e3)},handleGoodsListGoodNumChangeEvent:function(t){var e=t.type,o=t.cid,i=t.goodId;this._updateGoodsNumData(e,o,i),this.getStoreShoppingCartData()},handleShoppingCartGoodNumChangeEvent:function(t){var e=t.type,o=t.cid,i=t.goodId;this._updateGoodsNumData(e,o,i)},handleUpdateCategoryEvent:function(t){var e;(null===(e=this.$refs.goodsList)||void 0===e?void 0:e.handRequireCategoryEvent)&&this.$refs.goodsList.handRequireCategoryEvent(t)},handleShoppingCartClearEvent:function(){this.goodsData.map((function(t){t.goods.map((function(t){t.num>0&&(t.num=0)}))}))},getStoreShoppingCartData:function(){var t;(null===(t=this.$refs.shoppingCartRef)||void 0===t?void 0:t.updateShoppingCartData)&&this.$refs.shoppingCartRef.updateShoppingCartData()},updateModalNavBackEvent:function(){(0,g.navBack)()},handleOrderingInformationClickEvent:function(){this.showOrderingInformationModal=!1,this.getStoreGoodsList()},openSubscribeModal:function(){},_updateGoodsNumData:function(t,e,o){},_getStoreNavRectInfo:function(){var t=this,e=(0,f.createQuery)(this);e.select("#nav_".concat(this.componentId)).boundingClientRect((function(e){if(console.log("resresresresres",e),!e||0===e.height)return t.navRectInitCount>10?console.error("[product-showcase]获取导航容器节点信息失败"):void setTimeout((function(){t._getStoreNavRectInfo(),t.navRectInitCount++}),150);t.navRectInitCount=0,t.navRectInfo.top=e.top,t.navRectInfo.height=e.height,t.navRectInfo.opacity=0,t.goodsPreviewRectInfo.stickyDistance=t.navBarInfo.height+e.height;var o=uni.getSystemInfoSync();t.goodsPreviewRectInfo.height=o.windowHeight-(t.navBarInfo.height+e.height),console.log("systemInfo.windowHeight",o.windowHeight),console.log("this.navBarInfo.height",t.navBarInfo.height),console.log("res.height",e.height),console.log("this.goodsPreviewRectInfo",t.goodsPreviewRectInfo)})).exec()},_calcTopNavOpacity:function(t){var e=t/(this.navRectInfo.top-this.navBarInfo.height);e<0&&(e=0),e>1&&(e=1),1===this.navRectInfo.opacity&&1===e||(this.navRectInfo.opacity=e)},_zfbdataExposeGoods:function(t){var e=this;console.log("增长分析埋点中商品曝光的店铺: ",this.storeInfo),t.cate_has_goods.forEach((function(t){t.goods.forEach((function(o){my.reportCustomEvent("1045130",{bizType:"cloudappevent",spu_id:o.id,spu_name:o.title,price_original:100*parseFloat(o.price),price_current:100*parseFloat(o.price),spu_catg_first_id:e.storeInfo.storeInfo.id,spu_catg_first_name:e.storeInfo.storeInfo.title,spu_catg_second_id:t.id,spu_catg_second_name:t.title})}))}))},deliveryTypeChange:function(t){this.delivery_type=t,console.log("delivery_type",this.delivery_type)},checkExchange:function(t){var e=this;(0,p.checkExchangeApi)(t).then((function(t){if(0!=t.data){e.expansion_show=!0,e.old_discount=parseFloat(t.redpacket.discount),e.new_discount=parseFloat(t.exchange.discount);var o=parseFloat(t.exchange.condition);e.new_description=o<=0?"无门槛":"满"+o+"可用",e.expansion_data=t}else e.expansion_show=!1}))},exchange:function(){var t=this;uni.showModal({title:"提示",content:"是否确认兑换",showCancel:!0,cancelText:"取消",success:function(e){e.confirm&&(0,p.exchangeApi)({sid:t.expansion_data.exchange.sid,redpacket_id:t.expansion_data.redpacket.id,mealRedpacket_id:t.expansion_data.exchange.redpacketid}).then((function(e){console.log("res++++++++change",e),uni.showToast({title:"兑换成功",icon:"success",success:function(){t.expansion_show=!1}})}))}})},expansion_close:function(){this.expansion_show=!1},handleOrderingRenshuClickEvent:function(t){console.log("就餐人数",t),this.renshu=t,this.showOrderingRenshuModal=!1,this.getStoreGoodsList()},getCartId:function(t){this.cartId=t},websocket_connect:function(){console.log("socket");var t=this;uni.connectSocket({url:m.WSS_URL}),uni.onSocketOpen((function(t){console.log("WebSocket连接已打开!")})),uni.onSocketError((function(t){console.log("WebSocket连接打开失败,请检查!")})),uni.onSocketMessage((function(e){if(console.log("收到服务器内容:"+e.data),-1!=e.data.indexOf("update_cart")){var o=JSON.parse(e.data),i=o.current_cart_id,n=o.table_id;o.extend;console.log(n),console.log(t.optionsData.tableId),console.log(i),console.log(t.cartId),n==t.optionsData.tableId&&i!=t.cartId&&(t.getStoreShoppingCartData(),t.getStoreGoodsList(!0))}}))},updateCategoryGoodsNum:function(t){this.categoryGoodsNum=t,console.log("啊啊啊啊啊啊啊啊",t,this.categoryGoodsNum)},beforeBack:function(){uni.navigateBack({delta:1})}}};e.default=_},cbea:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.searchRecordApi=e.postStoreCouponApi=e.postStoreCollectApi=e.myStoreApi=e.joinStoreVipApi=e.getStoreVipInfoApi=e.getStoreTangshiGoodsListApi=e.getStoreShoppingCartDataApi=e.getStoreInfoApi=e.getStoreGoodsListApi=e.getStoreCommentListApi=e.getOrderDinnerStoreListApi=e.getOrderDinnerStoreIdApi=e.getMyCommentListApi=e.getIsBrandStoreApi=e.getFaviateBrandStoreListApi=e.getCodeInfoByCodeApi=e.getClassChild=e.getCategorys=e.getBrandStoreListApi=e.getBrandMasterApi=e.getBrandGoodsApi=e.getBrandApi=e.delCommentApi=void 0,o("5c47"),o("af8f");var n=i(o("b4f6"));e.getStoreInfoApi=function(t){var e=t.sid,o=t.table_id,i=t.storeCode,a=t.brand;return n.default.get("api/user.store.store/index",{sid:e,table_id:o,storeCode:i,brand:a})};e.getStoreVipInfoApi=function(t){return n.default.get("api/user.store.store/storeVip",t)};e.joinStoreVipApi=function(t){return n.default.post("api/user.store.store/joinStoreVip",t)};e.getStoreGoodsListApi=function(t){var e=t.sid,o=t.search,i=t.orderId,a=t.cid,r=t.child_id,s=t.page,d=t.is_api_shop,c=t.storeCode,l=t.api_brand,u=t.order_type,p=t.encrypted_data,f=t.write_off_type,h=t.is_promotion,g=t.goodsC,v=t.chrid;return n.default.get("api/user.store.goods/goods",{sid:e,child_id:r||"",search:o||"",order_id:i||"",cid:a||"",page:s||1,is_api_shop:d||"",storeCode:c||"",api_brand:l||"",order_type:u||"",encrypted_data:p||"",write_off_type:f||"",is_promotion:h||-1,goodsC:g,chrid:v||""})};e.getStoreShoppingCartDataApi=function(t){var e=t.sid,o=t.tableId,i=t.encrypted_data;return n.default.get("api/user.store.goods/cartIndex",{sid:e,table_id:o||"",encrypted_data:i||""})};e.getStoreCommentListApi=function(t){var e=t.sid,o=t.type,i=t.note,a=t.page,r=t.pSize;return n.default.get("api/user.store.store/comment",{sid:e,type:o||"",note:i||0,page:a,psize:r})};e.getMyCommentListApi=function(t){var e=t.page,o=t.pSize;return n.default.get("api/user.store.store/myComment",{page:e,psize:o})};e.delCommentApi=function(t){return n.default.post("api/user.store.store/delComment",t)};e.getStoreTangshiGoodsListApi=function(t){var e=t.sid,o=t.search,i=t.tableId,a=t.clear;return n.default.get("api/user.store.table/goods",{sid:e,search:o||"",table_id:i,clear:a||!1})};e.postStoreCouponApi=function(t){var e=t.sid;return n.default.post("api/user.channel.coupon/receive",{sid:e})};e.postStoreCollectApi=function(t){var e=t.sid,o=t.type,i=t.storeCode;return n.default.get("api/user.member.favorite/operate",{sid:e,type:o,storeCode:i})};e.getCategorys=function(t){var e=t.template_id;return n.default.get("api/user.store.goods/plugin_categorys",{template_id:e})};e.getClassChild=function(t){var e=t.cid;return n.default.get("api/user.store.goods/plugin_goods",{cid:e})};e.getOrderDinnerStoreListApi=function(t){return n.default.get("api/user.store.store/getOrderDinnerStoreList",t)};e.getOrderDinnerStoreIdApi=function(t){return n.default.get("api/user.store.store/getOrderDinnerStoreId",t)};e.getBrandApi=function(t){return n.default.get("api/user.store.store/getBrand?sid="+t)};e.getCodeInfoByCodeApi=function(t){return n.default.get("api/user.store.store/getCodeInfo?code="+t,{})};e.searchRecordApi=function(t){return n.default.post("api/user.tuangouquan.write_off/searchRecords",t)};e.getIsBrandStoreApi=function(t){return n.default.get("api/user.store.store/getIsBrandStore?sid="+t)};e.getBrandStoreListApi=function(t){return n.default.post("api/user.store.store/getBrandStoreList",t)};e.getFaviateBrandStoreListApi=function(t){return n.default.get("api/user.store.store/getFaviateBrandStoreList",t)};e.getBrandMasterApi=function(t){return n.default.get("api/user.appointment.index/index?sid="+t)};e.getBrandGoodsApi=function(t){return n.default.get("api/user.appointment.index/goods?sid="+t)};e.myStoreApi=function(){return n.default.get("api/user.store.store/myStore")}},cfdc:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(o("9b1b"));o("64aa"),o("473f"),o("bf0f"),o("2797"),o("aa77"),o("aa9c"),o("c223"),o("fd3c"),o("8f71"),o("c9b5"),o("ab80"),o("dd2b");var a=i(o("7dcc")),r=i(o("a736")),s=i(o("e165")),d=o("edc8"),c=o("47da"),l=o("4f43"),u=o("cbea"),p=o("dfc8"),f=o("46ea"),h={props:{sendPrice:{type:[String,Number],default:0},selfPickupMinPrice:{type:[String,Number],default:0},deliveryPrice:{type:[String,Number],default:0},sid:{type:[String,Number],default:""},spellriceId:{type:[String,Number],default:""},tableId:{type:[String,Number],default:""},isRest:{type:Boolean,default:!1},goodsData:{type:Array,default:[]},deliveryType:{type:Number,default:1},isZiti:{type:Boolean,default:!1},personNum:{type:[String,Number],default:""},brand:{type:String,default:""},storeCode:{type:String,default:""},encrypted_data:{type:String,default:""},multiple_cart:{type:[Boolean,String,Number],default:!1},multiple_cart_add_fee:{type:Number,default:0},pageShowType:{type:Number,default:0}},components:{BottomModal:r.default,ProductSpecNumberBox:s.default},mixins:[a.default],data:function(){return{shoppingCartData:{boxPrice:0,data:[],discount_by_num_id:0,discount_by_num_price:0,encrypted_data:"",is_single_no_delivery:0},require:!0,require_text:"未选必选品",requireIndex:-1,showProductList:!1,cidMinPrice:!1,cidMinPriceText:"最低消费0",multipleShoppingCartData:[],other_shop_num:0,multiple_cart_delivery_price:0,tuangouquan_price:0,is_loaded:!1,shop_image:d.BASE_URL+"uploads/images/shopping/shangpin.png",categoryGoodsNum:[],goodsNum:[]}},computed:{totalPrice:function(){var t=this;if(0==this.multiple_cart){var e=0;return this.shoppingCartData.data.length>0&&(e=this.shoppingCartData.data.reduce((function(e,o){return o.is_tuangouquan?(t.tuangouquan_price=o.tuangouquan_price,e+o.total_discount_price-o.tuangouquan_price):e+o.total_discount_price}),0)),this.shoppingCartData.discount_by_num_id>0&&e!=this.shoppingCartData.price&&(e=this.shoppingCartData.price),this.shoppingCartData.encrypted_data&&(e=this.shoppingCartData.price),e.toFixed(2)}var o=0;return this.multipleShoppingCartData.length>0&&this.multipleShoppingCartData.forEach((function(t){t.checked&&t.data.forEach((function(t){Array.isArray(t)||(t=[t]),o+=t.reduce((function(t,e){return t+e.total_discount_price}),0)}))})),o.toFixed(2)},oldTotalPrice:function(){if(0==this.multiple_cart){var t=0;return this.shoppingCartData.data.length>0&&(t=this.shoppingCartData.data.reduce((function(t,e){if(88888!=e.goods_id)return t+e.oldPrice*e.num}),0)),t.toFixed(2)}var e=0;return this.multipleShoppingCartData.length>0&&this.multipleShoppingCartData.forEach((function(t){t.checked&&t.data.forEach((function(t){Array.isArray(t)||(t=[t]),e+=t.reduce((function(t,e){return t+e.oldPrice*e.num}),0)}))})),e.toFixed(2)},totalNum:function(){var t=0;return 0==this.multiple_cart?this.shoppingCartData.data.length>0&&(t=this.shoppingCartData.data.reduce((function(t,e){return t+e.num}),0)):this.multipleShoppingCartData.length>0&&this.multipleShoppingCartData.forEach((function(e){e.checked&&e.data.forEach((function(e){Array.isArray(e)||(e=[e]),t+=e.reduce((function(t,e){return t+e.num}),0)}))})),t},submitBtnTipText:function(){var t=this;if(this.isRest)return"休息中...";var e=Number(this.totalPrice),o=Number(this.sendPrice),i=Number(this.selfPickupMinPrice),a=!0;if(console.log("this.shoppingCartData",this.shoppingCartData),this.goodsData.length>0)for(var r=!1,s=!1,d=function(e){for(var o=0;o<t.goodsData.length;o++)if(1!=t.shoppingCartData.data[e].is_single_no_delivery&&(a=!1),t.goodsData[o].is_mandatory){r=!0;var i=t.goodsData[o].goods.find((function(o,i){return o.id==t.shoppingCartData.data[e].goodId}));if(i&&1==t.goodsData[o].is_mandatory&&(s=!0),r&&s){t.require=!0;break}r&&!s&&(t.requireIndex=o,t.require=!1)}else t.have_mandatory=!1},c=0;c<this.shoppingCartData.data.length;c++)d(c);var l=[];return this.shoppingCartData.data.forEach((function(t,e,o){l.push({cid:t.cid,price:t.price})})),l=l.reduce((function(t,e){var o=t.find((function(t){return t.cid===e.cid})),i=(0,n.default)((0,n.default)({},e),{},{frequency:1});return o?(o.price+=e.price,o.frequency++):t.push(i),t}),[]),l.forEach((function(e){t.goodsData.forEach((function(o){e.cid==o.id&&Number(o.category_min_fee)>0&&(t.cidMinPrice=!1,e.price<Number(o.category_min_fee)&&(t.cidMinPrice=!0,t.cidMinPriceText="".concat(o.title,"还需消费").concat((o.category_min_fee-e.price).toFixed(2))))}))})),this.shoppingCartData.data.length>0&&a?"单点不送":o>0?this.isZiti?e+this.tuangouquan_price>=i?"去结算":"差".concat((i-e).toFixed(2),"起送"):e+this.tuangouquan_price>=o?"去结算":"差".concat((o-e).toFixed(2),"起送"):this.isZiti&&e+this.tuangouquan_price<i?"差".concat((i-(e+this.tuangouquan_price)).toFixed(2),"起送"):e+this.tuangouquan_price>=o?"去结算":"请选择商品"},isToSubmit:function(){if(this.isRest)return!1;if(this.cidMinPrice)return!1;var t=Number(this.totalPrice),e=Number(this.sendPrice),o=Number(this.selfPickupMinPrice);return this.isZiti?o>0&&t+this.tuangouquan_price>=o||0===o&&t+this.tuangouquan_price>o:e>=0&&t+this.tuangouquan_price>=e||0===e&&t+this.tuangouquan_price>=e}},watch:{sid:{handler:function(t){t&&this.updateShoppingCartData()},immediate:!0}},methods:{handleStoreCheckedChangeEvent:function(t){this.multipleShoppingCartData[t].checked=!this.multipleShoppingCartData[t].checked,console.log("this.multipleShoppingCartData",this.multipleShoppingCartData)},getShoppingCartData:function(){var t=this;(0,u.getStoreShoppingCartDataApi)({sid:this.sid,tableId:this.tableId,encrypted_data:this.encrypted_data}).then((function(e){t.tuangouquan_price=0,console.log(t.goodsData,"阿里"),t.$emit("updateCartNumber",t.goodsData);var o=e.cart;if(0==t.multiple_cart)t.shoppingCartData.boxPrice=o.box_price,t.shoppingCartData.price=o.price,t.shoppingCartData.discount_by_num_id=o.discount_by_num_id,t.shoppingCartData.encrypted_data=o.encrypted_data||"",t.shoppingCartData.discount_by_num_id=Number(o.discount_by_num_id),t.shoppingCartData.discount_by_num_price=Number(o.discount_by_num_price),o.data&&(t.shoppingCartData.data=o.data.reduce((function(t,e){return t.concat(e.filter((function(t){return"88888"!=t.goods_id})).map((function(t){var e=Number(t.price),i=Number(t.caigou_discount_price),n=Number(t.total_discount_price),a=Number(t.num),r=0;return e==t.caigou_discount_price?r=0:(r=Math.floor((n-i*a)/(e-i)),r=a-r,r&&(r+=1)),console.log("discount_num",r),{cid:t.cid,goodId:t.goods_id,optionId:(0===t.option_id?0:t.option_id).toString(),title:t.title,image:t.thumb,spec:t.option_title,min:0,max:-1,num:t.num,price:Number(t.price),oldPrice:Number((null===t||void 0===t?void 0:t.old_price)||t.price),cart_price:Number(o.cart_price),total_discount_price:Number(t.total_discount_price),is_tuangouquan:t.is_tuangouquan,tuangouquan_price:t.tuangouquan_price,bargain_type:t.bargain_type||"",caigou_discount_price:Number(t.caigou_discount_price)||Number(t.price),discount_num:r,is_single_no_delivery:t.is_single_no_delivery||0}})))}),[]));else{t.multipleShoppingCartData=[],console.log("cart",o),o.forEach((function(e){var o=e.data.reduce((function(t,o){return t.concat(o.filter((function(t){return"88888"!=t.goods_id})).map((function(t){return{cid:t.cid,goodId:t.goods_id,optionId:(0===t.option_id?0:t.option_id).toString(),title:t.title,image:t.thumb,spec:t.option_title,min:0,max:-1,num:t.num,price:Number(t.price),oldPrice:Number((null===t||void 0===t?void 0:t.old_price)||t.price),cart_price:Number(e.cart_price),total_discount_price:Number(t.total_discount_price),store_title:e.store_title,is_single_no_delivery:t.is_single_no_delivery}})))}),[]),i={boxPrice:e.box_price,data:o,discount_by_num_id:e.discount_by_num_id,discount_by_num_price:e.discount_by_num_price,encrypted_data:e.encrypted_data||"",store_title:e.store_title,sid:e.sid,checked:!0};t.multipleShoppingCartData.push(i),t.multiple_cart_delivery_price=e.delivery_price,e.sid==t.sid&&(t.shoppingCartData.boxPrice=e.box_price,t.shoppingCartData.price=e.price,t.shoppingCartData.discount_by_num_id=e.discount_by_num_id,t.shoppingCartData.encrypted_data=e.encrypted_data||"",t.shoppingCartData.discount_by_num_id=Number(e.discount_by_num_id),t.shoppingCartData.discount_by_num_price=Number(e.discount_by_num_price),t.shoppingCartData.data=o)})),console.log("shoppingCartData",t.shoppingCartData),console.log("cart",o),console.log("xxxxxx",t.multipleShoppingCartData);var i=t.multipleShoppingCartData.find((function(e){return e.sid==t.sid}));console.log("currentShopCart",i),i||(t.shoppingCartData.data=[])}console.log("shoppingCartData",t.shoppingCartData),console.log(t.shoppingCartData.data,"this.shoppingCartData.data"),uni.$emit("historyCart",t.shoppingCartData.data),t.categoryGoodsNum=[],t.goodsNum=[],console.log(t.shoppingCartData.data,"this.shoppingCartData.data"),t.shoppingCartData.data.forEach((function(e){if(e.cid){var o=t.categoryGoodsNum.find((function(t){return t.cid===e.cid}));o?o.num+=e.num:t.categoryGoodsNum.push({cid:e.cid,num:e.num})}if(e.goodId){var i=t.goodsNum.find((function(t){return t.goodId===e.goodId}));i?i.num+=e.num:t.goodsNum.push({goodId:e.goodId,num:e.num}),console.log("this.goodsNum",t.goodsNum)}})),console.log("this.categoryGoodsNum",t.categoryGoodsNum),t.$emit("updateCategoryGoodsNum",t.categoryGoodsNum),t.$emit("updateGoodsNum",t.goodsNum),t.$emit("get-cart-id",o.id),t.is_loaded=!0})).catch((function(e){console.error("[shoppingCart]获取店铺购物车数据失败",e),t.shoppingCartData.data=[]}))},updateShoppingCartData:function(){this.getShoppingCartData()},clearStoreShoppingCart:function(){var t=this;(0,c.showModal)({title:"操作提示",content:"确定需要清空购物车吗?",showCancel:!0,callback:function(e){e&&(0,p.clearStoreShoppingCartApi)({sid:t.sid}).then((function(e){(0,c.showToast)({title:"清空购物车成功"}),t._resetShoppingCartData(),t.getShoppingCartData(),t.showProductList=!1,t.$emit("clear")})).catch((function(t){console.error("[shoppingCart]清空购物车数据失败",t),(0,c.showToast)({title:t.msg})}))}})},getCheckedStore:function(){var t=[];return this.multipleShoppingCartData.forEach((function(e){e.checked&&t.push(e.sid)})),t},handleSubmitEvent:function(){var t=this;if(0!=this.totalNum){if(console.log(this.isToSubmit,this.require,this.requireIndex,"this.isToSubmit"),this.isToSubmit)if(!this.require&&this.requireIndex>=0)this.$emit("update-category",this.requireIndex);else{uni.$once(f.REFRESH_STORE_EVENT,(function(){t.$emit("refresh-data")}));var e=3===+this.deliveryType&&this.isZiti?1:0;if(console.log(this.deliveryType,this.isZiti),0==this.multiple_cart)this.tableId&&""!=this.tableId?(0,l.navPage)("/other-page/submit-order/submit-tangshi-order?sid=".concat(this.sid,"&table_id=").concat(this.tableId,"&personNum=")+this.personNum):(0,l.navPage)("/other-page/submit-order/submit-order?sid=".concat(this.sid,"&orderType=").concat(e,"&brand=").concat(this.brand,"&storeCode=").concat(this.storeCode));else{var o=this.getCheckedStore();if(o.length>0)if(1==o.length)(0,l.navPage)("/order-page/submit-order/index?sid=".concat(o.join(","),"&orderType=").concat(e,"&brand=").concat(this.brand,"&storeCode=").concat(this.storeCode));else{var i=o.join(",");(0,l.navPage)("/order-page/one-touch-submit-order/index?sids=".concat(i),"redirect")}else(0,c.showToast)({title:"请选择店铺"})}}}else(0,c.showToast)({title:"请选择商品"})},handleGoodNumChangeEvent:function(t,e,o){var i=this,n=this.shoppingCartData.data[o];this.updateShoppingCartData(),this.$emit("good-num-change",{cid:n.cid,goodId:n.goodId,type:e,sid:sid}),0===t&&this.$nextTick((function(){setTimeout((function(){i.shoppingCartData.data.splice(o,1)}),250)}))},_resetShoppingCartData:function(){this.shoppingCartData.boxPrice=0,this.shoppingCartData.data=[]},handleClickInfoEvent:function(){this.showProductList=!this.showProductList}}};e.default=h},d0c5:function(t,e,o){var i=o("13d2");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("565e6516",i,!0,{sourceMap:!1,shadowMode:!1})},d1f6:function(t,e,o){"use strict";o.r(e);var i=o("de2f"),n=o.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return i[t]}))}(a);e["default"]=n.a},d28f:function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return t.openModal?o("v-uni-view",{staticClass:"bottom-modal",style:[t.modalStyle]},[t.mask?o("v-uni-view",{staticClass:"bottom-modal__mask",class:[{transparent:t.transparentMask}],on:{touchmove:function(e){e.stopPropagation(),e.preventDefault(),arguments[0]=e=t.$handleEvent(e)},click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.closeModal("mask")}}}):t._e(),o("v-uni-view",{staticClass:"bottom-modal__wrapper",class:[{"no-padding":t.noPadding,"tn-shadow":t.transparentMask}],style:[t.wrapperStyle]},[t.closeBtn?o("v-uni-view",{staticClass:"bottom-modal__close-btn",style:[t.closeBtnStyle],on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.closeModal("btn")}}},[o("v-uni-text",{staticClass:"tn-icon-close"})],1):t._e(),t._t("default")],2)],1):t._e()},n=[]},d5c5:function(t,e,o){var i=o("9397");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=o("967d").default;n("d95ee3f2",i,!0,{sourceMap:!1,shadowMode:!1})},d82f:function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return new Promise((function(e,o){t&&t.length||e()}))},o("bf0f");o("47da")},db04:function(t,e,o){"use strict";var i=o("bb80"),n=o("c435"),a=o("9e70"),r=o("f298"),s=o("862c"),d=i(r),c=i("".slice),l=Math.ceil,u=function(t){return function(e,o,i){var r,u,p=a(s(e)),f=n(o),h=p.length,g=void 0===i?" ":a(i);return f<=h||""===g?p:(r=f-h,u=d(g,l(r/g.length)),u.length>r&&(u=c(u,0,r)),t?p+u:u+p)}};t.exports={start:u(!1),end:u(!0)}},de2f:function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i={props:{value:{type:Boolean,default:!1},mode:{type:Object,default:{}},show:{type:Boolean,default:!1}},data:function(){return{openModal:!1}},methods:{closeModal:function(){this.$emit("input",!1),this.$emit("close")}},watch:{value:{handler:function(t){this.openModal=t},immediate:!0}}};e.default=i},df40:function(t,e,o){"use strict";var i=o("285f"),n=o.n(i);n.a},e450:function(t,e,o){"use strict";o.r(e);var i=o("a71d"),n=o("cb66");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("7445");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"44737eca",null,!1,i["a"],void 0);e["default"]=s.exports},e4cc:function(t,e,o){"use strict";o.r(e);var i=o("4ad5"),n=o("a88e");for(var a in n)["default"].indexOf(a)<0&&function(t){o.d(e,t,(function(){return n[t]}))}(a);o("2d64"),o("64d5");var r=o("828b"),s=Object(r["a"])(n["default"],i["b"],i["c"],!1,null,"1ae0345a",null,!1,i["a"],void 0);e["default"]=s.exports},e511:function(t,e,o){"use strict";var i=o("220b"),n=o.n(i);n.a},eda6:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.postStoreCouponApi=e.getStoreInfoApi=e.getStoreGoodsListApi=e.getOrderDinnerStoreIdApi=e.getCodeInfoByCodeApi=e.getBrandApi=e.getAlipayTemplateIdDataApi=e.exchangeApi=e.default=e.checkExchangeApi=e.applyRefundApi=void 0,e.refundListBySupplierApi=m,e.updateGoodCartApi=e.searchRecordApi=void 0,o("5c47"),o("af8f");var n=i(o("b4f6")),a=function(t){return n.default.get("api/user.store.store/getOrderDinnerStoreId",t)};e.getOrderDinnerStoreIdApi=a;var r=function(t){return n.default.get("api/user.store.store/getBrand?sid="+t)};e.getBrandApi=r;var s=function(t){return n.default.get("api/user.store.store/getCodeInfo?code="+t,{})};e.getCodeInfoByCodeApi=s;var d=function(t){return n.default.get("api/user.mealRedpacket.meal_redpacket/checkExchange?sid="+t)};e.checkExchangeApi=d;var c=function(t){return n.default.post("api/user.mealRedpacket.meal_redpacket/exchange",t)};e.exchangeApi=c;var l=function(){return n.default.get("api/system.template.AliTemplate/templateList")};e.getAlipayTemplateIdDataApi=l;var u=function(t){return n.default.post("api/user.tuangouquan.write_off/searchRecords",t)};e.searchRecordApi=u;var p=function(t){var e=t.sid,o=t.search,i=t.orderId,a=t.cid,r=t.child_id,s=t.page,d=t.is_api_shop,c=t.storeCode,l=t.api_brand,u=t.order_type,p=t.encrypted_data,f=t.write_off_type,h=t.is_promotion,g=t.goodsC,v=t.chrid;return n.default.get("api/user.store.goods/goods",{sid:e,child_id:r||"",search:o||"",order_id:i||"",cid:a||"",page:s||1,is_api_shop:d||"",storeCode:c||"",api_brand:l||"",order_type:u||"",encrypted_data:p||"",write_off_type:f||"",is_promotion:h||-1,goodsC:g,chrid:v||""})};e.getStoreGoodsListApi=p;var f=function(t){var e=t.sid,o=t.table_id,i=t.storeCode,a=t.brand;return n.default.get("api/user.store.store/index",{sid:e,table_id:o,storeCode:i,brand:a})};e.getStoreInfoApi=f;var h=function(t){var e=t.sid;return n.default.post("api/user.channel.coupon/receive",{sid:e})};e.postStoreCouponApi=h;var g=function(t){var e=t.goodsId,o=t.sid,i=t.num,a=t.options_id;return n.default.post("api/user.store.goods/updateCart",{sid:o,goods_id:e,num:i,options_id:a})};e.updateGoodCartApi=g;var v=function(t){return n.default.post("api/user.order.order/applyRefund",t)};function m(t){return n.default.get("api/user.order.order/refundListBySupplier",t)}e.applyRefundApi=v;var _={getOrderDinnerStoreIdApi:a,getBrandApi:r,getCodeInfoByCodeApi:s,checkExchangeApi:d,exchangeApi:c,getAlipayTemplateIdDataApi:l,searchRecordApi:u,getStoreGoodsListApi:p,getStoreInfoApi:f,postStoreCouponApi:h,updateGoodCartApi:g,applyRefundApi:v,refundListBySupplierApi:m};e.default=_},f298:function(t,e,o){"use strict";var i=o("497b"),n=o("9e70"),a=o("862c"),r=RangeError;t.exports=function(t){var e=n(a(this)),o="",s=i(t);if(s<0||s===1/0)throw new r("Wrong number of repetitions");for(;s>0;(s>>>=1)&&(e+=e))1&s&&(o+=e);return o}},fa49a:function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"search-box tn-flex-row-center tn-bg-gray--light theme-search-input",class:[t.searchBoxClass]},[t.leftIcon?o("v-uni-view",{staticClass:"search-box__left-icon"},[o("v-uni-text",{class:["tn-icon-"+t.leftIcon]})],1):t._e(),o("v-uni-view",{staticClass:"search-box__input"},[o("v-uni-input",{staticClass:"input",attrs:{type:"text",placeholder:t.placholder},on:{input:function(e){arguments[0]=e=t.$handleEvent(e),t.inputChangeEvent.apply(void 0,arguments)}},model:{value:t.inputValue,callback:function(e){t.inputValue=e},expression:"inputValue"}})],1),t.buttonText&&t.showbtn?o("v-uni-view",{staticClass:"search-box__btn theme-search-btn",style:[t.themeBtnStyle],attrs:{"hover-class":"tn-btn-hover-class","hover-stay-time":150},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.btnClickEvent.apply(void 0,arguments)}}},[t._v(t._s(t.buttonText))]):t._e()],1)},n=[]},faf2:function(t,e,o){"use strict";o("6a54");var i=o("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa");var n=i(o("7caa")),a={mixins:[n.default],name:"tn-badge",props:{index:{type:[Number,String],default:"0"},radius:{type:Number,default:0},padding:{type:String,default:""},margin:{type:String,default:""},dot:{type:Boolean,default:!1},absolute:{type:Boolean,default:!1},top:{type:[String,Number],default:""},right:{type:[String,Number],default:""},translateCenter:{type:Boolean,default:!0}},computed:{badgeClass:function(){var t="";return this.dot&&(t+=" tn-badge--dot"),this.absolute&&(t+=" tn-badge--absolute",this.translateCenter&&(t+=" tn-badge--center-position")),t},badgeStyle:function(){var t={};return 0!==this.radius&&(t.width=this.radius+"rpx",t.height=this.radius+"rpx",t.lineHeight=this.radius+"rpx"),this.padding&&(t.padding=this.padding),this.margin&&(t.margin=this.margin),this.fontColorStyle&&(t.color=this.fontColorStyle),this.fontSize&&(t.fontSize=this.fontSize+this.fontUnit),this.backgroundColorStyle&&(t.backgroundColor=this.backgroundColorStyle),this.top&&(t.top=this.$t.string.getLengthUnitValue(this.top)),this.right&&(t.right=this.$t.string.getLengthUnitValue(this.right)),t}},data:function(){return{}},methods:{handleClick:function(){this.$emit("click",{index:Number(this.index)}),this.$emit("tap",{index:Number(this.index)})}}};e.default=a},fcaf:function(t,e,o){"use strict";var i=o("7401"),n=o.n(i);n.a},fe56:function(t,e,o){"use strict";o("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,o("64aa");var i={name:"tn-loading",props:{mode:{type:String,default:"circle"},show:{type:Boolean,default:!0},animation:{type:Boolean,default:!0},color:{type:String,default:""},size:{type:Number,default:34}},computed:{loadStyle:function(){var t={};return t.width=this.size+"rpx",t.height=t.width,"circle"===this.mode&&(t.borderColor="#E6E6E6 #E6E6E6 #E6E6E6 ".concat(this.color?this.color:"#AAAAAA")),t}}};e.default=i}}]);
|