diff --git a/components/diy_goodsGroup/diy_goodsGroup.js b/components/diy_goodsGroup/diy_goodsGroup.js
index 4680b26..98a58b1 100644
--- a/components/diy_goodsGroup/diy_goodsGroup.js
+++ b/components/diy_goodsGroup/diy_goodsGroup.js
@@ -14,7 +14,14 @@ Component({
type: Object,
value: null,
},
-
+ sticky: {
+ type: Number,
+ value: 0,
+ },
+ container: {
+ type: Function,
+ value: null,
+ },
},
data: {
// 这里是一些组件内部数据
@@ -47,14 +54,17 @@ Component({
swiper_hei: 0,
title_class: "",
is_no_plus: 1,
+ container: null,
},
- ready: function () { },
-
lifetimes: {
+ ready: function () {
+ this.setData({
+ container: () => wx.createSelectorQuery().select('#container')
+ })
+ },
+
attached: function () {
-
-
//要兼容性的写法,因为有些商家都还未更新商品分组的最新的效果~~3.0公众号的html页面所以不用兼容写法
var nav_item = this.data.object;
var nav_list = this.data.object.nav_list;
diff --git a/components/diy_goodsGroup/diy_goodsGroup.json b/components/diy_goodsGroup/diy_goodsGroup.json
index c886449..184585e 100644
--- a/components/diy_goodsGroup/diy_goodsGroup.json
+++ b/components/diy_goodsGroup/diy_goodsGroup.json
@@ -1,6 +1,7 @@
{
"component": true,
"usingComponents": {
- "mp-loading": "weui-miniprogram/loading/loading"
+ "mp-loading": "weui-miniprogram/loading/loading",
+ "mp-sticky": "../mp-sticky/mp-sticky"
}
}
\ No newline at end of file
diff --git a/components/diy_goodsGroup/diy_goodsGroup.wxml b/components/diy_goodsGroup/diy_goodsGroup.wxml
index ddd463f..0f19b5d 100644
--- a/components/diy_goodsGroup/diy_goodsGroup.wxml
+++ b/components/diy_goodsGroup/diy_goodsGroup.wxml
@@ -4,13 +4,27 @@
+
+
+
+
+
{{item.title}}
+
+
+
+
+ {{item.title}}
+
+
+
+
@@ -885,4 +899,6 @@
+
+
\ No newline at end of file
diff --git a/components/diy_serviceCard/diy_serviceCard.js b/components/diy_serviceCard/diy_serviceCard.js
index 375573b..6eca56d 100644
--- a/components/diy_serviceCard/diy_serviceCard.js
+++ b/components/diy_serviceCard/diy_serviceCard.js
@@ -19,9 +19,10 @@ Component({
},
sticky: {
type: Number,
+ value: 0,
},
container: {
- type: Object,
+ type: Function,
value: null,
},
},
@@ -185,10 +186,6 @@ Component({
show: function() {
//--初始化卡类--
// this.card_init();
- // this.setData({
- // container: () => wx.createSelectorQuery().select('#container')
- // });
- console.log('onshow');
},
},
diff --git a/components/diy_serviceCard/diy_serviceCard.wxml b/components/diy_serviceCard/diy_serviceCard.wxml
index f4afde4..4d6a906 100644
--- a/components/diy_serviceCard/diy_serviceCard.wxml
+++ b/components/diy_serviceCard/diy_serviceCard.wxml
@@ -12,7 +12,7 @@
-->
-
+
wx.createSelectorQuery().select('#container')
- })
- console.log('container', this.data.container);
- },
onLoad: async function (tt) {
wx.showShareMenu({
diff --git a/pages/index/index/index.wxml b/pages/index/index/index.wxml
index 9f6e410..d57483c 100644
--- a/pages/index/index/index.wxml
+++ b/pages/index/index/index.wxml
@@ -469,7 +469,7 @@
-
+
@@ -536,7 +536,7 @@
-
+