(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/mall"],{"2c6e":function(e,t,n){},"3d7a":function(e,t,n){"use strict";var a=n("2c6e"),r=n.n(a);r.a},"7fb5":function(e,t,n){"use strict";(function(e,t){var a=n("4ea4");n("d716");a(n("66fd"));var r=a(n("82f1"));e.__webpack_require_UNI_MP_PLUGIN__=n,t(r.default)}).call(this,n("bc2e")["default"],n("543d")["createPage"])},8024:function(e,t,n){"use strict";n.r(t);var a=n("ea5f"),r=n.n(a);for(var i in a)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(i);t["default"]=r.a},"82f1":function(e,t,n){"use strict";n.r(t);var a=n("9ef5"),r=n("8024");for(var i in r)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return r[e]}))}(i);n("3d7a");var u=n("f0c5"),c=Object(u["a"])(r["default"],a["b"],a["c"],!1,null,"6844eab8",null,!1,a["a"],void 0);t["default"]=c.exports},"9ef5":function(e,t,n){"use strict";n.d(t,"b",(function(){return r})),n.d(t,"c",(function(){return i})),n.d(t,"a",(function(){return a}));var a={uSearch:function(){return Promise.all([n.e("common/vendor"),n.e("uni_modules/uview-ui/components/u-search/u-search")]).then(n.bind(null,"6f82"))},uSticky:function(){return Promise.all([n.e("common/vendor"),n.e("uni_modules/uview-ui/components/u-sticky/u-sticky")]).then(n.bind(null,"99c7"))},uTabs:function(){return Promise.all([n.e("common/vendor"),n.e("uni_modules/uview-ui/components/u-tabs/u-tabs")]).then(n.bind(null,"3cf8"))}},r=function(){var e=this.$createElement;this._self._c},i=[]},ea5f:function(e,t,n){"use strict";(function(e){var a=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=a(n("2eee")),i=a(n("c973")),u=(a(n("a0cf")),n("9ca2")),c={data:function(){return{searchKey:"",picUrl:this.$picUrl,picBase:this.$picBase,currBrandIndex:0,list1:[],list2:[],activeStyle:{color:"#F7790C"},inactiveStyle:{color:"#080F18"},selTab:{type:1,brand:7},resList:[],allTypes:[],allTypesValues:[],tOList:[]}},created:function(){},onLoad:function(){var t=this;return(0,i.default)(r.default.mark((function n(){var a,i;return r.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.next=2,(0,u.getMallCatReq)();case 2:a=n.sent,0==a.code?(console.log("获取商城顶部分类数据返回值: ",a),t.handle1({id:a.data[0].id}),t.tOList=a.data,i=[],a.data.forEach((function(e,t){i.push({id:e.id,name:e.title})})),t.list1=i):e.showToast({title:a.message,icon:"none"});case 4:case"end":return n.stop()}}),n)})))()},onShow:function(){return(0,i.default)(r.default.mark((function e(){return r.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})))()},onReady:function(){},methods:{handle1:function(e){var t=this;return(0,i.default)(r.default.mark((function n(){var a;return r.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return console.log("e",e.id),n.next=3,(0,u.getMallCatReq)({pid:e.id});case 3:a=n.sent,0==a.code&&(t.list2=a.data,console.log("zhongxiang",a),t.getMall(a.data[0].id));case 5:case"end":return n.stop()}}),n)})))()},getMall:function(t){var n=this;return(0,i.default)(r.default.mark((function a(){var i;return r.default.wrap((function(a){while(1)switch(a.prev=a.next){case 0:return a.next=2,(0,u.getMallReq)({pid:t});case 2:i=a.sent,0==i.code?(console.log("获取商城数据返回值: ",i),n.allTypes=Object.keys(i.data.typeName),n.allTypesValues=Object.values(i.data.typeName),n.resList=i.data):e.showToast({title:i.message,icon:"none"});case 4:case"end":return a.stop()}}),a)})))()},getMall2:function(t){var n=this;return(0,i.default)(r.default.mark((function a(){var i;return r.default.wrap((function(a){while(1)switch(a.prev=a.next){case 0:return a.next=2,(0,u.getMallReq)({search:t});case 2:i=a.sent,0==i.code?(console.log("获取商城数据返回值2: ",i.data),n.resList=i.data,console.log("获取商城数据返回值列表2: ",n.resList)):e.showToast({title:i.message,icon:"none"});case 4:case"end":return a.stop()}}),a)})))()},change2:function(e,t){this.currBrandIndex=t,this.getMall(e)},toList:function(t,n){e.navigateTo({url:"/pages/mall/goodsList/index?typeNameId="+t+"&name="+n+"&brand="+this.selTab.brand+"&type="+this.selTab.type})},goDetail:function(t){getApp().mallItem=t,e.navigateTo({url:"/pages/mall/detail/index"})}},watch:{searchKey:function(e,t){var n=this;if(!e)return this.selTab={type:1,brand:7},void(this.currBrandIndex=0);setTimeout((function(){n.getMall2(e)}),1e3)}},components:{}};t.default=c}).call(this,n("543d")["default"])}},[["7fb5","common/runtime","common/vendor"]]]);