增加了下拉刷新

parent 48e969bf
......@@ -5,7 +5,7 @@
"^wd-(.*)": "wot-design-uni/components/wd-$1/wd-$1.vue"
}
},
"pages": [
"pages": [
{
"path": "pages/index/index",
"style": {
......@@ -22,7 +22,8 @@
{
"path": "pages/index/foodClassification",
"style": {
"navigationBarTitleText": ""
"navigationBarTitleText": "",
"enablePullDownRefresh": true
}
},
{
......@@ -84,37 +85,32 @@
"style": {
"navigationBarTitleText": "美食评论"
}
}
,
},
{
"path": "pages/order/refund",
"style": {
"navigationBarTitleText": "申请退款"
}
}
,
},
{
"path": "pages/index/coupon",
"style": {
"navigationBarTitleText": "优惠券详情",
"enablePullDownRefresh": true
}
}
,
},
{
"path": "pages/storeEntry/index",
"style": {
"navigationBarTitleText": "我的店铺"
}
}
,
},
{
"path": "pages/storeEntry/detail",
"style": {
"navigationBarTitleText": "商家入驻"
}
}
,
},
{
"path": "pages/order/afterSales",
"style": {
......
......@@ -129,8 +129,8 @@ const params = ref({
size: 15,
// lon,
// lat,
lon: 106.68650025025502,
lat: 26.567192352601154,
lon: '',
lat: '',
isEnd: false,
});
const pics = ref(null);
......@@ -221,6 +221,11 @@ function refresh() {
resolve();
});
}
onPullDownRefresh(() => {
refresh().then(() => {
getMerchantList();
});
});
// 根据父级分类id查询子分类列表
const query = (parentId) => {
getByParentId(parentId).then((res) => {
......@@ -298,6 +303,7 @@ const getMerchantList = () => {
return new Promise((resolve) => {
cardData.value = cardData.value.concat(res.data.content);
xma.hideLoading();
xma.stopPullDownRefresh();
setTimeout(() => {
resolve();
}, 500);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment