优化代码
This commit is contained in:
@@ -28,7 +28,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<!-- list -->
|
||||
<div class="list" style="overflow: auto" v-infinite-scroll="load">
|
||||
<div class="list" style="overflow: auto" v-infinite-scroll="load" v-if="list.length !== 0">
|
||||
<div v-for="(item, index) in list" :key="index" class="list-item">
|
||||
<div
|
||||
class="list-content"
|
||||
@@ -93,6 +93,9 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="chatNotDeta"v-if="list.length === 0">
|
||||
<div class="chatNotDeta-text">您还没有PK记录</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-splitter-panel>
|
||||
|
||||
@@ -208,7 +211,7 @@ function detail(item) {
|
||||
id: item.id,
|
||||
}).then((res) => {
|
||||
fetchDetailPkDataWithId.value = res;
|
||||
});
|
||||
}).catch((err) => {});
|
||||
}
|
||||
//切换选项卡
|
||||
function optionsclick(value) {
|
||||
@@ -243,7 +246,7 @@ function PkRecord(type) {
|
||||
list.value = InvitationData.value;
|
||||
}
|
||||
}
|
||||
});
|
||||
}).catch((err) => {});
|
||||
}
|
||||
|
||||
// 加载更多
|
||||
@@ -404,6 +407,19 @@ onUnmounted(() => {
|
||||
width: 100%;
|
||||
height: calc(100% -150px);
|
||||
}
|
||||
.chatNotDeta{
|
||||
width: 100%;
|
||||
height: calc(100% -150px);
|
||||
background-color: #ffffff;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.chatNotDeta-text{
|
||||
font-size: 20px;
|
||||
color: #03aba8;
|
||||
font-weight: bold;
|
||||
}
|
||||
.list-item {
|
||||
width: 100%;
|
||||
height: 150px;
|
||||
|
||||
Reference in New Issue
Block a user