优化页面

This commit is contained in:
pengxiaolong
2025-05-23 21:50:04 +08:00
parent c55be10783
commit 0d7301f3b1
27 changed files with 483 additions and 131 deletions

View File

@@ -19,6 +19,11 @@ const _sfc_main = {
this.pkList();
},
methods: {
onRefresherRefresh() {
this.page = 0;
this.list = [];
this.pkList();
},
goDetail(item) {
common_vendor.index.navigateTo({
url: "/pages/pkDetail/pkDetail",
@@ -41,10 +46,10 @@ const _sfc_main = {
},
userInfo: false
});
common_vendor.index.__f__("log", "at components/contentList/contentList.vue:66", res);
common_vendor.index.__f__("log", "at components/contentList/contentList.vue:71", res);
if (res.code === 200) {
this.list.push(...res.data);
common_vendor.index.__f__("log", "at components/contentList/contentList.vue:69", this.list);
common_vendor.index.__f__("log", "at components/contentList/contentList.vue:74", this.list);
}
},
onScrollToLower() {
@@ -78,7 +83,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
l: "4813d59a-0-" + i0
});
}),
b: common_vendor.o$1((...args) => $options.onScrollToLower && $options.onScrollToLower(...args))
b: common_vendor.o$1((...args) => $options.onRefresherRefresh && $options.onRefresherRefresh(...args)),
c: common_vendor.o$1((...args) => $options.onScrollToLower && $options.onScrollToLower(...args))
};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-4813d59a"]]);

View File

@@ -1 +1 @@
<scroll-view scroll-y="true" class="scroll data-v-4813d59a" lower-threshold="100" bindscrolltolower="{{b}}"><uni-card wx:for="{{a}}" wx:for-item="item" class="data-v-4813d59a" u-s="{{['d']}}" u-i="{{item.l}}" bind:__l="__l"><view class="content-list data-v-4813d59a" bindtap="{{item.k}}"><image class="headShot data-v-4813d59a" src="{{item.a}}" mode="scaleToFill"/><view class="content-list-title data-v-4813d59a"><view class="cardname data-v-4813d59a">{{item.b}}</view><view class="content-list-info data-v-4813d59a"><view class="{{['data-v-4813d59a', item.g && 'Gendermale', item.h && 'Genderfemale']}}"><image wx:if="{{item.c}}" class="Genderimg data-v-4813d59a" src="{{item.d}}" mode="scaleToFill"/><image wx:else class="Genderimg data-v-4813d59a" src="{{item.e}}" mode="scaleToFill"/><view class="age data-v-4813d59a">{{item.f}}</view></view><view class="RoomID data-v-4813d59a">PK时间: {{item.i}}</view><view class="Charm data-v-4813d59a">金币:</view><view class="charmValue data-v-4813d59a">{{item.j}}</view></view></view></view></uni-card></scroll-view>
<scroll-view scroll-y="true" class="scroll data-v-4813d59a" refresher-enabled="true" refresher-threshold="40" bindrefresherrefresh="{{b}}" lower-threshold="100" bindscrolltolower="{{c}}"><uni-card wx:for="{{a}}" wx:for-item="item" class="data-v-4813d59a" u-s="{{['d']}}" u-i="{{item.l}}" bind:__l="__l"><view class="content-list data-v-4813d59a" bindtap="{{item.k}}"><image class="headShot data-v-4813d59a" src="{{item.a}}" mode="scaleToFill"/><view class="content-list-title data-v-4813d59a"><view class="cardname data-v-4813d59a">{{item.b}}</view><view class="content-list-info data-v-4813d59a"><view class="{{['data-v-4813d59a', item.g && 'Gendermale', item.h && 'Genderfemale']}}"><image wx:if="{{item.c}}" class="Genderimg data-v-4813d59a" src="{{item.d}}" mode="scaleToFill"/><image wx:else class="Genderimg data-v-4813d59a" src="{{item.e}}" mode="scaleToFill"/><view class="age data-v-4813d59a">{{item.f}}</view></view><view class="RoomID data-v-4813d59a">PK时间: {{item.i}}</view><view class="Charm data-v-4813d59a">金币:</view><view class="charmValue data-v-4813d59a">{{item.j}}</view></view></view></view></uni-card></scroll-view>