You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

0 lines
10 KiB

6 months ago
  1. (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/index/index"],{1668:function(t,n,e){"use strict";e.r(n);var i=e("7977"),o=e.n(i);for(var a in i)"default"!==a&&function(t){e.d(n,t,(function(){return i[t]}))}(a);n["default"]=o.a},"32ce":function(t,n,e){"use strict";e.r(n);var i=e("96a1"),o=e("1668");for(var a in o)"default"!==a&&function(t){e.d(n,t,(function(){return o[t]}))}(a);e("f89d");var r,c=e("f0c5"),s=Object(c["a"])(o["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);n["default"]=s.exports},"53f9":function(t,n,e){"use strict";(function(t){e("8d0c");i(e("66fd"));var n=i(e("32ce"));function i(t){return t&&t.__esModule?t:{default:t}}wx.__webpack_require_UNI_MP_PLUGIN__=e,t(n.default)}).call(this,e("543d")["createPage"])},7977:function(t,n,e){"use strict";(function(t){Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=o(e("a34a"));function o(t){return t&&t.__esModule?t:{default:t}}function a(t,n,e,i,o,a,r){try{var c=t[a](r),s=c.value}catch(u){return void e(u)}c.done?n(s):Promise.resolve(s).then(i,o)}function r(t){return function(){var n=this,e=arguments;return new Promise((function(i,o){var r=t.apply(n,e);function c(t){a(r,i,o,c,s,"next",t)}function s(t){a(r,i,o,c,s,"throw",t)}c(void 0)}))}}var c=function(){e.e("components/struggler-uniapp-add-tip/struggler-uniapp-add-tip").then(function(){return resolve(e("a7cb"))}.bind(null,e)).catch(e.oe)},s=function(){e.e("components/drag-button/drag-button").then(function(){return resolve(e("75f4"))}.bind(null,e)).catch(e.oe)},u=function(){e.e("components/uni-notice-bar/uni-notice-bar").then(function(){return resolve(e("94af"))}.bind(null,e)).catch(e.oe)},d={components:{addtip:c,dragButton:s,uniNoticeBar:u},data:function(){return{bttext:"客服",tip:"点击「添加小程序」,下次访问更便捷",duration:5,banner:[],cardCur:0,typeList:[{id:3,name:"粮油类",sort:2,icon:"http://m2.chinause.cn:8888/8img/mini/liangyou.png"}],pcdesc:[],productList:[],tjproductList:[],loadingText:"正在加载...",miaosstyle:"miaos",goodsList:[],text:"欢迎进入中龙小程序商城",backcolor:"#E8E8E8",color:"#F23E05",gg_zezhao:"none",gg_model:"none"}},methods:{baseinfo:function(t){var n=this;return r(i.default.mark((function e(){var o;return i.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,n.$api.baseinfo({action:"baseinfo",key:t});case 2:o=e.sent,"gscolor"==t?n.color=o.data.info:"gsbgcolor"==t&&(n.backcolor=o.data.info);case 4:case"end":return e.stop()}}),e)})))()},btnClick:function(){console.log("btnClick")},btnTouchstart:function(){console.log("btnTouchstart")},btnTouchend:function(){console.log("btnTouchend")},cardSwiper:function(t){this.cardCur=t.detail.current},toSearch:function(){t.showLoading({title:"加载中..."}),t.navigateTo({url:"/pages/search/search"}),t.hideLoading()},topcate:function(n){if("#"!=n&&void 0!=n){console.log(n);var e=n.split("?");console.log(e[1],"tourl[1]");var i=e[1].split("&"),o=i[0],a=i[1];console.log("xflid="+a+"===dflid="+o),getApp().globalData.dflid=o,getApp().globalData.xflid=a,getApp().globalData.tid=1,console.log(getApp().globalData.xflid,"保存好的id"),t.switchTab({url:e[0]})}},addcollection:function(n,e,o){var a=this;return r(i.default.mark((function r(){var c,s,u;return i.default.wrap((function(i){while(1)switch(i.prev=i.next){case 0:if(c=t.getStorageSync("userinfo"),s=0==o?!a.tjproductList[e].iscollect:!a.productList[e].iscollect,!c){i.next=10;break}return i.next=5,a.$api.addcollection({action:"addcollection",type:s,uid:c.uid,id:n});case 5:u=i.sent,t.showToast({title:u.msg,icon:"none"}),1==u.code&&(0==o?a.tjproductList[e].iscollect=!a.tjproductList[e].iscollect:a.productList[e].iscollect=!a.productList[e].iscollect),i.next=11;break;case 10:t.navigateTo({url:"/pages/user/login"});case 11:case"end":return i.stop()}}),r)})))()},toFavorite:function(t,n,e){this.addcollection(t,n,e)},getgoodlist:function(){var n=this;return r(i.default.mark((function e(){var o,a;return i.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return o=t.getStorageSync("userinfo"),e.next