Merge remote-tracking branch 'origin/main'

This commit is contained in:
2023-08-09 11:17:33 +08:00
5 changed files with 23 additions and 11 deletions

View File

@@ -28,7 +28,8 @@
<div class="title">历史搜索</div>
<div class="info-box">
<div :class="flexacenter" v-for="(item, i) in historyArr" :key="i"
class="btn" @click="handleKeyword(item)">{{ item }}
class="btn flexacenter" @click="handleKeyword(item)">
<div class="flexflex">{{ item }}</div>
<img class="btn-icon" src="../../assets/homeImage/closeIcon.svg"
@click.stop="deleteSeachVal(i)" alt="">
<img>
@@ -66,7 +67,7 @@
<template #reference>
<div class="tool-btn consult-btn flexcenter">
<img class="consult-icon" src="@/assets/img/publicImage/consult-icon.png">
咨询小助手
咨询方同学
</div>
</template>
<div class="consult-pop flexacenter">
@@ -318,6 +319,12 @@ const selectOption = (type, value) => {
emit('handleTransfer', pitchValue)
})
}
//删除历史记录
let deleteSeachVal = (i) => {
historyArr.value.splice(i, 1)
localStorage.setItem('historyArr', JSON.stringify(historyArr.value));
}
</script>
<style scoped lang="less">
* {
@@ -737,9 +744,20 @@ const selectOption = (type, value) => {
margin: 20px 30px 0 0;
cursor: pointer;
word-break: break-word;
position: relative;
&:hover .btn-icon {
display: block;
}
.btn-icon {
margin-left: 5px;
position: absolute;
top: 50%;
right: -16px;
transform: translateY(-50%);
width: 8px;
height: 8px;
margin-left: 6px;
display: none;
}
}
}

View File

@@ -24,7 +24,7 @@
<div class="tab-item mg-l-8 flexacenter" v-if="data.gender">
{{ listData.gender[data.gender] }}
</div>
<div class="tab-item mg-l-8 flexacenter" v-if="data.rentalduration != ''">
<div class="tab-item mg-l-8 flexacenter" v-if="data.rentalduration != '' && data.rentalduration != null">
{{ data.rentalduration == 0 ? '租期不限' : listData['rentalduration'][data.rentalduration] }}
</div>

View File

@@ -16,8 +16,7 @@
<listBtmPrompt></listBtmPrompt>
<footerTool></footerTool>
</div>
<!-- 右下角咨询 -->
<circle-btn></circle-btn>
<back-to-top></back-to-top>

View File

@@ -17,8 +17,6 @@
<footerTool></footerTool>
</div>
<!-- 右下角咨询 -->
<circle-btn></circle-btn>
<back-to-top></back-to-top>
</template>

View File

@@ -17,9 +17,6 @@
<footerTool></footerTool>
</div>
<!-- 右下角咨询 -->
<circle-btn></circle-btn>
<back-to-top></back-to-top>
</template>