forked from php-danfu.shenzhenbenwo.com

lefengyang
2025-09-10 3c9dcaf742cfa3e3c2b0843c8752cf7713aaf1fc
1
2
3
4
5
6
7
8
9
10
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/index/components/goodList"],{"0699":function(t,n,e){"use strict";e.r(n);var o=e("a7a3"),i=e("7fe6");for(var l in i)["default"].indexOf(l)<0&&function(t){e.d(n,t,(function(){return i[t]}))}(l);e("09d8");var r=e("828b"),a=Object(r["a"])(i["default"],o["b"],o["c"],!1,null,null,null,!1,o["a"],void 0);n["default"]=a.exports},"09d8":function(t,n,e){"use strict";var o=e("6eb7"),i=e.n(o);i.a},"2df0":function(t,n,e){"use strict";(function(t){var o=e("47a9");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=o(e("7ca3")),l=e("c302"),r=o(e("c3d2")),a=(e("d7f8"),e("8f59")),s=e("1a5b"),c=e("7cf0");function g(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function h(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?g(Object(e),!0).forEach((function(n){(0,i.default)(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):g(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}var u={name:"goodList",props:{dataConfig:{type:Object,default:function(){}},isSortType:{type:String|Number,default:0}},components:{productWindow:function(){e.e("components/productWindow/index").then(function(){return resolve(e("1b6b"))}.bind(null,e)).catch(e.oe)}},mixins:[r.default],data:function(){return{tempArr:[],type:0,attr:{cartAttr:!1,productAttr:[],productSelect:{}},id:0,productValue:[],attrValue:"",storeName:"",storeInfo:{},allList:[],leftList:[],rightList:[],mark:0,boxHeight:[]}},watch:{tempArr:{handler:function(t,n){var e=this;(!this.tempArr.length||this.tempArr.length===this.updateNum&&this.tempArr.length<=this.allList.length)&&(this.allList=[],this.leftList=[],this.rightList=[],this.boxHeight=[],this.mark=0),this.tempArr.length&&(this.allList=this.tempArr,this.leftList=[],this.rightList=[],this.boxHeight=[],this.allList.forEach((function(t,n){(e.allList.length<3||e.allList.length<=7&&e.allList.length-n>1||e.allList.length>7&&e.allList.length-n>2)&&(n%2?e.rightList.push(t):e.leftList.push(t))})),this.allList.length<3?this.mark=this.allList.length+1:this.allList.length<=7?this.mark=this.allList.length-1:this.mark=this.allList.length-2,this.mark<this.allList.length&&this.waterFall())},immediate:!0,deep:!0},mark:function(){var t=this.allList.length;this.mark<t&&0!==this.mark&&this.boxHeight.length&&this.waterFall()},dataConfig:function(){this.productslist()}},computed:h(h(h({},(0,a.mapState)({cartNum:function(t){return t.indexData.cartNum}})),(0,a.mapGetters)(["isLogin","uid","cartNum"])),{},{boxStyle:function(){return{padding:"".concat(2*this.dataConfig.topConfig.val,"rpx ").concat(2*this.dataConfig.prConfig.val,"rpx ").concat(2*this.dataConfig.bottomConfig.val,"rpx"),marginTop:"".concat(2*this.dataConfig.mbConfig.val,"rpx"),background:this.dataConfig.bottomBgColor.color[0].item}},bgRadius:function(){var t="".concat(2*this.dataConfig.fillet.val,"rpx");return this.dataConfig.fillet.type&&(t="".concat(2*this.dataConfig.fillet.valList[0].val,"rpx ").concat(2*this.dataConfig.fillet.valList[1].val,"rpx ").concat(2*this.dataConfig.fillet.valList[3].val,"rpx ").concat(2*this.dataConfig.fillet.valList[2].val,"rpx")),{borderRadius:t}},bgRadius2:function(){var t="0 0 ".concat(2*this.dataConfig.fillet.val,"rpx ").concat(2*this.dataConfig.fillet.val,"rpx");return this.dataConfig.fillet.type&&(t="0 0 ".concat(2*this.dataConfig.fillet.valList[3].val,"rpx ").concat(2*this.dataConfig.fillet.valList[2].val,"rpx")),{borderRadius:t}},styleConfig:function(){return this.dataConfig.styleConfig.tabVal},imgStyle:function(){var t="".concat(2*this.dataConfig.filletImg.val,"rpx");1==this.dataConfig.styleConfig.tabVal&&(t="".concat(2*this.dataConfig.filletImg.val,"rpx ").concat(2*this.dataConfig.filletImg.val,"rpx 0 0")),this.dataConfig.filletImg.type&&(t="".concat(2*this.dataConfig.filletImg.valList[0].val,"rpx ").concat(2*this.dataConfig.filletImg.valList[1].val,"rpx ").concat(2*this.dataConfig.filletImg.valList[3].val,"rpx ").concat(2*this.dataConfig.filletImg.valList[2].val,"rpx"),1==this.dataConfig.styleConfig.tabVal&&(t="".concat(2*this.dataConfig.filletImg.valList[0].val,"rpx ").concat(2*this.dataConfig.filletImg.valList[1].val,"rpx 0 0")));var n="".concat(2*this.dataConfig.fillet.val,"rpx ").concat(2*this.dataConfig.fillet.val,"rpx 0 0");return this.dataConfig.fillet.type&&(n="".concat(2*this.dataConfig.fillet.valList[0].val,"rpx ").concat(2*this.dataConfig.fillet.valList[1].val,"rpx 0 0")),"promotionList"==this.dataConfig.name?n:t},productStyle:function(){return{color:this.dataConfig.goodsNameColor.color[0].item,fontWeight:this.dataConfig.goodsName.tabVal?"normal":"bold"}},checkboxInfo:function(){return this.dataConfig.checkboxInfo.type},priceColor:function(){return this.dataConfig.toneConfig.tabVal?this.dataConfig.goodsPriceColor.color[0].item:"var(--view-theme)"},otPriceColor:function(){return this.dataConfig.goodsPriceColor.color[0].item},btnStyle:function(){return this.dataConfig.bntStyleConfig.tabVal},showBtn:function(){return this.dataConfig.cartConfig.tabVal},btnBgColor:function(){return{background:this.dataConfig.toneConfig.tabVal?"linear-gradient(90deg,".concat(this.dataConfig.bntBgColor.color[0].item," 0%,").concat(this.dataConfig.bntBgColor.color[1].item," 100%)"):"linear-gradient(90deg, var(--view-theme) 0%, var(--view-gradient) 100%)"}},btnTextColor:function(){return{color:"#FFFFFF",background:this.dataConfig.toneCartConfig.tabVal?"linear-gradient(90deg, ".concat(this.dataConfig.bntBgColor.color[0].item," 0%, ").concat(this.dataConfig.bntBgColor.color[1].item," 100%)"):"linear-gradient(90deg, var(--view-theme) 0%, var(--view-gradient) 100%)"}},numberConfig:function(){return this.dataConfig.numberConfig.val},goodStyleConfig:function(){return this.dataConfig.styleConfig.tabVal},goodsSort:function(){return this.dataConfig.goodsSort.tabVal},typeConfig:function(){return this.dataConfig.typeConfig.activeValue},bntConfig:function(){return this.dataConfig.bntConfig.tabVal},onlyShowPrice:function(){return"0,2"==this.checkboxInfo.toString()||"2,0"==this.checkboxInfo.toString()||"2"==this.checkboxInfo.toString()}}),created:function(){},mounted:function(){this.productslist()},methods:{observeVideo:function(){var n=this,e=t.createIntersectionObserver(this,{observeAll:!0});e.relativeToViewport().observe(".video",(function(e){e.intersectionRatio?t.createVideoContext(e.id,n).play():t.createVideoContext(e.id,n).pause()}))},productslist:function(){var t=this,n=(this.$config.LIMIT,{});n=1==this.typeConfig?{ids:this.dataConfig.goodsList.ids.join(",")}:{priceOrder:2==this.goodsSort?"desc":"",salesOrder:1==this.goodsSort?"desc":"",brand_id:2==this.typeConfig?this.dataConfig.brandList.brandVal.join(","):"",store_label_id:4==this.typeConfig?this.dataConfig.goodsLabel.activeValue.join(","):"",cate_id:3==this.typeConfig?this.dataConfig.classList.classVal.join(","):"",limit:this.numberConfig},(0,l.getProductslist)(n).then((function(n){t.tempArr=n.data}))},goDetail:function(n){(0,c.goShopDetail)(n,this.$store.state.app.uid).then((function(e){t.navigateTo({url:"/pages/goods_details/index?id=".concat(n.id)})}))},getAttrs:function(t){var n=this;(0,l.getAttr)(t,0).then((function(t){n.$set(n.attr,"productAttr",t.data.productAttr),n.$set(n,"productValue",t.data.productValue),n.$set(n,"storeInfo",t.data.storeInfo),n.DefaultSelect()}))},addCartChange:function(t,n){1==this.bntConfig?t.spec_type?this.goCartDuo(t):this.goCartDan(t,n):this.goDetail(t)},getCartNum:function(){var t=this;(0,s.getCartCounts)().then((function(n){t.$store.commit("indexData/setCartNum",n.data.count)}))},waterFall:function(){var t=this.mark;if(0==t)this.leftList.push(this.allList[t]),this.getViewHeight(0);else if(1==t)this.rightList.push(this.allList[t]),this.getViewHeight(1);else{if(this.boxHeight.length){var n=this.boxHeight[0]>this.boxHeight[1]?1:0;n?this.rightList.push(this.allList[t]):this.leftList.push(this.allList[t])}else this.rightList.length<this.leftList.length?this.rightList.push(this.allList[t]):this.leftList.push(this.allList[t]);this.getViewHeight()}},getViewHeight:function(){var n=this;this.$nextTick((function(){setTimeout((function(){t.createSelectorQuery().in(n).select("#right").boundingClientRect((function(e){e&&(n.boxHeight[1]=e.height),t.createSelectorQuery().in(n).select("#left").boundingClientRect((function(t){t&&(n.boxHeight[0]=t.height),n.mark=n.mark+1})).exec()})).exec()}),100)}))}}};n.default=u}).call(this,e("df3c")["default"])},"6eb7":function(t,n,e){},"7fe6":function(t,n,e){"use strict";e.r(n);var o=e("2df0"),i=e.n(o);for(var l in o)["default"].indexOf(l)<0&&function(t){e.d(n,t,(function(){return o[t]}))}(l);n["default"]=i.a},a7a3:function(t,n,e){"use strict";e.d(n,"b",(function(){return i})),e.d(n,"c",(function(){return l})),e.d(n,"a",(function(){return o}));var o={easyLoadimage:function(){return e.e("components/easy-loadimage/easy-loadimage").then(e.bind(null,"1bea"))}},i=function(){var t=this,n=t.$createElement,e=(t._self._c,t.__get_style([t.boxStyle])),o=0==t.goodStyleConfig?t.__map(t.tempArr,(function(n,e){var o=t.__get_orig(n),i=t.__get_style([t.bgRadius]),l=t.checkboxInfo.includes(0),r=l?t.__get_style([t.productStyle]):null,a=t.checkboxInfo.includes(1),s=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.__get_style([t.btnBgColor]):null,c=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.$t("购买"):null,g=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle&&1==t.btnStyle?t.__get_style([t.btnTextColor]):null,h=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle&&1!=t.btnStyle?t.__get_style([t.btnTextColor]):null,u=t.onlyShowPrice?null:t.checkboxInfo.includes(2),f=t.onlyShowPrice?null:Number(n.vip_price)>0&&t.checkboxInfo.includes(5),d=!t.onlyShowPrice&&f?t.$t("¥"):null,b=t.onlyShowPrice?null:t.checkboxInfo.includes(3),y=!t.onlyShowPrice&&b?t.$t("已售"):null,_=t.onlyShowPrice?null:t.checkboxInfo.includes(4),p=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnBgColor]),C=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.$t("购买"),S=t.onlyShowPrice||t.showBtn||0==t.btnStyle||1!=t.btnStyle?null:t.__get_style([t.btnTextColor]),m=t.onlyShowPrice||t.showBtn||0==t.btnStyle||1==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,s1:i,g0:l,s2:r,g1:a,s3:s,m0:c,s4:g,s5:h,g2:u,m1:f,m2:d,g3:b,m3:y,g4:_,s6:p,m4:C,s7:S,s8:m}})):null,i=1==t.goodStyleConfig?t.leftList.length:null,l=1==t.goodStyleConfig&&i?t.__map(t.leftList,(function(n,e){var o=t.__get_orig(n),i=t.__get_style([t.bgRadius2]),l=t.checkboxInfo.includes(0),r=l?t.__get_style([t.productStyle]):null,a=t.checkboxInfo.includes(1),s=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.__get_style([t.btnTextColor]):null,c=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle?t.__get_style([t.btnTextColor]):null,g=t.onlyShowPrice?null:t.checkboxInfo.includes(2),h=t.onlyShowPrice?null:Number(n.vip_price)>0&&t.checkboxInfo.includes(5),u=!t.onlyShowPrice&&h?t.$t("¥"):null,f=t.onlyShowPrice?null:t.checkboxInfo.includes(3),d=!t.onlyShowPrice&&f?t.$t("已售"):null,b=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnTextColor]),y=t.onlyShowPrice||t.showBtn||0==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,s9:i,g6:l,s10:r,g7:a,s11:s,s12:c,g8:g,m5:h,m6:u,g9:f,m7:d,s13:b,s14:y}})):null,r=1==t.goodStyleConfig?t.rightList.length:null,a=1==t.goodStyleConfig&&r?t.__map(t.rightList,(function(n,e){var o=t.__get_orig(n),i=t.__get_style([t.bgRadius2]),l=t.checkboxInfo.includes(0),r=l?t.__get_style([t.productStyle]):null,a=t.checkboxInfo.includes(1),s=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.__get_style([t.btnTextColor]):null,c=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle?t.__get_style([t.btnTextColor]):null,g=t.onlyShowPrice?null:t.checkboxInfo.includes(2),h=t.onlyShowPrice?null:Number(n.vip_price)>0&&t.checkboxInfo.includes(5),u=!t.onlyShowPrice&&h?t.$t("¥"):null,f=t.onlyShowPrice?null:t.checkboxInfo.includes(3),d=!t.onlyShowPrice&&f?t.$t("已售"):null,b=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnTextColor]),y=t.onlyShowPrice||t.showBtn||0==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,s15:i,g11:l,s16:r,g12:a,s17:s,s18:c,g13:g,m8:h,m9:u,g14:f,m10:d,s19:b,s20:y}})):null,s=3==t.goodStyleConfig?t.__get_style([t.bgRadius]):null,c=3==t.goodStyleConfig?t.__map(t.tempArr,(function(n,e){var o=t.__get_orig(n),i=t.checkboxInfo.includes(0),l=i?t.__get_style([t.productStyle]):null,r=t.checkboxInfo.includes(2);return{$orig:o,g15:i,s22:l,g16:r}})):null,g=2==t.goodStyleConfig?t.__get_style([t.bgRadius]):null,h=2==t.goodStyleConfig?t.__map(t.tempArr,(function(n,e){var o=t.__get_orig(n),i=t.checkboxInfo.includes(0),l=i?t.__get_style([t.productStyle]):null,r=t.checkboxInfo.includes(2),a=t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnTextColor]),s=t.showBtn||0==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,g17:i,s24:l,g18:r,s25:a,s26:s}})):null,u=4==t.goodStyleConfig?t.__map(t.tempArr,(function(n,e){var o=t.__get_orig(n),i=t.__get_style([t.bgRadius]),l=t.checkboxInfo.includes(0),r=l?t.__get_style([t.productStyle]):null,a=t.checkboxInfo.includes(1),s=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.__get_style([t.btnBgColor]):null,c=t.onlyShowPrice&&!t.showBtn&&0==t.btnStyle?t.$t("购买"):null,g=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle&&1==t.btnStyle?t.__get_style([t.btnTextColor]):null,h=t.onlyShowPrice&&!t.showBtn&&0!=t.btnStyle&&1!=t.btnStyle?t.__get_style([t.btnTextColor]):null,u=t.onlyShowPrice?null:t.checkboxInfo.includes(2),f=t.onlyShowPrice?null:Number(n.vip_price)>0&&t.checkboxInfo.includes(5),d=!t.onlyShowPrice&&f?t.$t("¥"):null,b=t.onlyShowPrice?null:t.checkboxInfo.includes(3),y=!t.onlyShowPrice&&b?t.$t("已售"):null,_=t.onlyShowPrice?null:t.checkboxInfo.includes(4),p=!t.onlyShowPrice&&_?t.$t("评分"):null,C=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnBgColor]),S=t.onlyShowPrice||t.showBtn||0!=t.btnStyle?null:t.$t("购买"),m=t.onlyShowPrice||t.showBtn||0==t.btnStyle||1!=t.btnStyle?null:t.__get_style([t.btnTextColor]),x=t.onlyShowPrice||t.showBtn||0==t.btnStyle||1==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,s27:i,g19:l,s28:r,g20:a,s29:s,m11:c,s30:g,s31:h,g21:u,m12:f,m13:d,g22:b,m14:y,g23:_,m15:p,s32:C,m16:S,s33:m,s34:x}})):null,f=5==t.goodStyleConfig?t.__get_style([t.bgRadius]):null,d=5==t.goodStyleConfig?t.__map(t.tempArr,(function(n,e){var o=t.__get_orig(n),i=t.checkboxInfo.includes(0),l=i?t.__get_style([t.productStyle]):null,r=t.checkboxInfo.includes(2),a=t.showBtn||0!=t.btnStyle?null:t.__get_style([t.btnTextColor]),s=t.showBtn||0==t.btnStyle?null:t.__get_style([t.btnTextColor]);return{$orig:o,g24:i,s36:l,g25:r,s37:a,s38:s}})):null;t.$mp.data=Object.assign({},{$root:{s0:e,l0:o,g5:i,l1:l,g10:r,l2:a,s21:s,l3:c,s23:g,l4:h,l5:u,s35:f,l6:d}})},l=[]}}]);
;(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
    'pages/index/components/goodList-create-component',
    {
        'pages/index/components/goodList-create-component':(function(module, exports, __webpack_require__){
            __webpack_require__('df3c')['createComponent'](__webpack_require__("0699"))
        })
    },
    [['pages/index/components/goodList-create-component']]
]);