no message
This commit is contained in:
parent
bc4c023629
commit
1457029a1e
@ -10,7 +10,7 @@
|
|||||||
<div class="navigation-text" @click="topTabSelect(i, item)" :class="{ 'navigation-text-click': item.key === topTabNum }" v-for="(item, i) in topTab.data" :key="i">
|
<div class="navigation-text" @click="topTabSelect(i, item)" :class="{ 'navigation-text-click': item.key === topTabNum }" v-for="(item, i) in topTab.data" :key="i">
|
||||||
{{ item.name }}
|
{{ item.name }}
|
||||||
</div>
|
</div>
|
||||||
<div class="user-box" v-if="user.data['uid'] > 0">
|
<div class="user-box" v-if="user.data['uid'] > 0 || user.data['uin'] > 0">
|
||||||
<a target="_blank" :href="`https://bbs.gter.net/home.php?mod=space&uid=${user.data['uin']}`">
|
<a target="_blank" :href="`https://bbs.gter.net/home.php?mod=space&uid=${user.data['uin']}`">
|
||||||
<img :src="user.data.avatar" class="user-img" alt="" />
|
<img :src="user.data.avatar" class="user-img" alt="" />
|
||||||
</a>
|
</a>
|
||||||
@ -125,7 +125,7 @@ let tabBtnType = ref("/")
|
|||||||
let pageTopBarShow = router.currentRoute.value.meta.topBarShow
|
let pageTopBarShow = router.currentRoute.value.meta.topBarShow
|
||||||
let changeTabBtnType = item => {
|
let changeTabBtnType = item => {
|
||||||
// 判断点击进入 user 时是否已经登录
|
// 判断点击进入 user 时是否已经登录
|
||||||
if (item["path"] == "/user" && user.data["uid"] == 0) {
|
if (item["path"] == "/user" && (user.data["uid"] == 0 || user.data["uin"] == 0)) {
|
||||||
loginBtn("login")
|
loginBtn("login")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="seach-info-box body-maxWidth">
|
<div class="seach-info-box body-maxWidth">
|
||||||
<div class="top-box dis-f al-item">
|
<div class="top-box dis-f al-item">
|
||||||
<div class="top-btn dis-f jus-x al-item first" v-if="!isNeedHousing" @click="selectPage('person')" :class="{'select-top-btn-bg': tabType === 'person'}">
|
<div class="top-btn dis-f jus-x al-item first" v-if="!isNeedHousing" @click="selectPage('person')" :class="{ 'select-top-btn-bg': tabType === 'person' }">
|
||||||
<div class="top-btn" :class="[tabType === 'person' ? 'select-top-btn' : 'first-no-select']" v-show="tabType === 'person'">
|
<div class="top-btn" :class="[tabType === 'person' ? 'select-top-btn' : 'first-no-select']" v-show="tabType === 'person'">
|
||||||
个人房源 {{ seachKey.key && seachKey.key.personal && seachKey.key.personal.count }}
|
个人房源 {{ seachKey.key && seachKey.key.personal && seachKey.key.personal.count }}
|
||||||
<div class="dis-f jus-x btm-line-mg">
|
<div class="dis-f jus-x btm-line-mg">
|
||||||
@ -38,7 +38,7 @@
|
|||||||
<div class="box"></div>
|
<div class="box"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="top-btn dis-f jus-x al-item first" v-if="isNeedHousing" :class="{'select-top-btn-bg': tabType === 'need'}">
|
<div class="top-btn dis-f jus-x al-item first" v-if="isNeedHousing" :class="{ 'select-top-btn-bg': tabType === 'need' }">
|
||||||
<div class="top-btn" :class="[tabType === 'need' ? 'select-top-btn' : 'first-no-select']" v-show="tabType === 'need'">
|
<div class="top-btn" :class="[tabType === 'need' ? 'select-top-btn' : 'first-no-select']" v-show="tabType === 'need'">
|
||||||
求房源
|
求房源
|
||||||
<div class="dis-f jus-x btm-line-mg">
|
<div class="dis-f jus-x btm-line-mg">
|
||||||
@ -47,12 +47,12 @@
|
|||||||
</div>
|
</div>
|
||||||
求房源{{ tabType }}
|
求房源{{ tabType }}
|
||||||
</div>
|
</div>
|
||||||
<div class="top-btn dis-f jus-x al-item second" v-if="isNeedHousing" @click="selectPage('intermediary')" :class="{'select-top-btn-bg': tabType === 'intermediary'}">
|
<div class="top-btn dis-f jus-x al-item second" v-if="isNeedHousing" @click="selectPage('intermediary')" :class="{ 'select-top-btn-bg': tabType === 'intermediary' }">
|
||||||
<div class="first-select">
|
<div class="first-select">
|
||||||
<div class="box"></div>
|
<div class="box"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="top-btn dis-f jus-x al-item second" v-if="!isNeedHousing && houseingPageType != 6" @click="selectPage('intermediary')" :class="{'select-top-btn-bg': tabType === 'intermediary'}">
|
<div class="top-btn dis-f jus-x al-item second" v-if="!isNeedHousing && houseingPageType != 6" @click="selectPage('intermediary')" :class="{ 'select-top-btn-bg': tabType === 'intermediary' }">
|
||||||
<div class="first-select" v-show="tabType === 'person'">
|
<div class="first-select" v-show="tabType === 'person'">
|
||||||
<div class="box"></div>
|
<div class="box"></div>
|
||||||
</div>
|
</div>
|
||||||
@ -67,7 +67,7 @@
|
|||||||
</div>
|
</div>
|
||||||
中介房源 {{ seachKey.key && seachKey.key.intermediary && seachKey.key.intermediary.count }}
|
中介房源 {{ seachKey.key && seachKey.key.intermediary && seachKey.key.intermediary.count }}
|
||||||
</div>
|
</div>
|
||||||
<div class="top-btn dis-f jus-x al-item third" @click="selectPage('apartment')" :class="{'select-top-btn-bg': tabType === 'apartment'}" v-if="!isNeedHousing && houseingPageType != 6">
|
<div class="top-btn dis-f jus-x al-item third" @click="selectPage('apartment')" :class="{ 'select-top-btn-bg': tabType === 'apartment' }" v-if="!isNeedHousing && houseingPageType != 6">
|
||||||
<div class="second-select-third-box" v-show="tabType === 'intermediary'">
|
<div class="second-select-third-box" v-show="tabType === 'intermediary'">
|
||||||
<div class="box"></div>
|
<div class="box"></div>
|
||||||
</div>
|
</div>
|
||||||
@ -85,16 +85,16 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-show="tabType === 'apartment'" :class="{'show-box-pd': !showSelectModule}">
|
<div v-show="tabType === 'apartment'" :class="{ 'show-box-pd': !showSelectModule }">
|
||||||
<apartmentSelect @handleTransfer="setSeachConditions" :seachPage="false" ref="apartmentSelectInfo"> </apartmentSelect>
|
<apartmentSelect @handleTransfer="setSeachConditions" :seachPage="false" ref="apartmentSelectInfo"> </apartmentSelect>
|
||||||
</div>
|
</div>
|
||||||
<div class="seach-select-info" v-show="tabType !== 'apartment'">
|
<div class="seach-select-info" v-show="tabType !== 'apartment'">
|
||||||
<div class="select-box" :class="{'seach-select-h': showSelectModule}" :style="{overflow: showSelectModule ? 'visible' : 'hidden'}">
|
<div class="select-box" :class="{ 'seach-select-h': showSelectModule }" :style="{ overflow: showSelectModule ? 'visible' : 'hidden' }">
|
||||||
<selectTabBox :setSeachCondition="setSeachConditions" :setLocation="setLocation" ref="selectTabBoxInfo"></selectTabBox>
|
<selectTabBox :setSeachCondition="setSeachConditions" :setLocation="setLocation" ref="selectTabBoxInfo"></selectTabBox>
|
||||||
</div>
|
</div>
|
||||||
<div :class="{'show-box-pd': !showSelectModule}">
|
<div :class="{ 'show-box-pd': !showSelectModule }">
|
||||||
<div class="box" :class="{'show-box': showSelectModule}">
|
<div class="box" :class="{ 'show-box': showSelectModule }">
|
||||||
<div class="dis-f jus-x al-item" :style="{height: !showSelectModule ? '60px' : '40px'}" @click="showSelectModule = !showSelectModule">
|
<div class="dis-f jus-x al-item" :style="{ height: !showSelectModule ? '60px' : '40px' }" @click="showSelectModule = !showSelectModule">
|
||||||
<div class="dis-f al-item">
|
<div class="dis-f al-item">
|
||||||
<span v-show="showSelectModule">收起筛选条件</span>
|
<span v-show="showSelectModule">收起筛选条件</span>
|
||||||
<span class="text-tps" v-show="!showSelectModule">筛选</span> <span v-show="!showSelectModule"> : </span>
|
<span class="text-tps" v-show="!showSelectModule">筛选</span> <span v-show="!showSelectModule"> : </span>
|
||||||
@ -104,14 +104,14 @@
|
|||||||
<span v-show="i !== typeText.length - 1" class="text-icon"> |  </span>
|
<span v-show="i !== typeText.length - 1" class="text-icon"> |  </span>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<img src="../../assets/homeImage/listMore.svg" class="icon-img" :class="{'down-icon': showSelectModule}" alt="" />
|
<img src="../../assets/homeImage/listMore.svg" class="icon-img" :class="{ 'down-icon': showSelectModule }" alt="" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="btm-list" :class="{'apartment-btm': tabType === 'apartment'}">
|
<div class="btm-list" :class="{ 'apartment-btm': tabType === 'apartment' }">
|
||||||
<div class="dis-f al-item">
|
<div class="dis-f al-item">
|
||||||
共<span class="count">{{ count || 0 }}</span
|
共<span class="count">{{ count || 0 }}</span
|
||||||
>条 {{ tabType === "person" ? "个人房源" : tabType === "intermediary" ? "中介房源" : tabType === "apartment" ? "品牌公寓" : "" }} <span v-show="selectTabCheck.title && selectTabCheck.id">   |  </span>
|
>条 {{ tabType === "person" ? "个人房源" : tabType === "intermediary" ? "中介房源" : tabType === "apartment" ? "品牌公寓" : "" }} <span v-show="selectTabCheck.title && selectTabCheck.id">   |  </span>
|
||||||
@ -129,7 +129,7 @@
|
|||||||
<template #dropdown>
|
<template #dropdown>
|
||||||
<el-dropdown-menu class="pd-10 el-dropdown-menu">
|
<el-dropdown-menu class="pd-10 el-dropdown-menu">
|
||||||
<el-dropdown-item v-for="(items, j) in listSort.type" :key="j" :command="j">
|
<el-dropdown-item v-for="(items, j) in listSort.type" :key="j" :command="j">
|
||||||
<div class="dropdown-text" :class="{'dropdown-check-text': listSort.checkType === items.type}">
|
<div class="dropdown-text" :class="{ 'dropdown-check-text': listSort.checkType === items.type }">
|
||||||
{{ items.title }}
|
{{ items.title }}
|
||||||
<div class="type-icon" v-show="listSort.checkType === items.type"></div>
|
<div class="type-icon" v-show="listSort.checkType === items.type"></div>
|
||||||
</div>
|
</div>
|
||||||
@ -145,13 +145,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import {reactive, ref, inject, shallowReactive, defineProps, watchEffect, defineExpose} from "vue"
|
import { reactive, ref, inject, shallowReactive, defineProps, watchEffect, defineExpose } from "vue"
|
||||||
import selectTabBox from "../selectTabBox/selectTabBox.vue"
|
import selectTabBox from "../selectTabBox/selectTabBox.vue"
|
||||||
import apartmentSelect from "../apartment/seachModule.vue"
|
import apartmentSelect from "../apartment/seachModule.vue"
|
||||||
import store from "../../store/index"
|
import store from "../../store/index"
|
||||||
import api from "@/utils/api"
|
import api from "@/utils/api"
|
||||||
import {useRoute, useRouter} from "vue-router"
|
import { useRoute, useRouter } from "vue-router"
|
||||||
import {ElMessage} from "element-plus"
|
import { ElMessage } from "element-plus"
|
||||||
|
|
||||||
//路由
|
//路由
|
||||||
const route = useRouter()
|
const route = useRouter()
|
||||||
@ -357,7 +357,7 @@ let isDownGetData = inject("isDownGetData")
|
|||||||
|
|
||||||
//搜索初始化
|
//搜索初始化
|
||||||
let searchInit = data => {
|
let searchInit = data => {
|
||||||
api.search({keyword: data})
|
api.search({ keyword: data })
|
||||||
.then(res => {
|
.then(res => {
|
||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
seachKey.key = res.data
|
seachKey.key = res.data
|
||||||
@ -431,7 +431,7 @@ let typeText = ["地理位置", "出租方式", "租金", "租期", "性别要
|
|||||||
let showSelectModule = ref(false)
|
let showSelectModule = ref(false)
|
||||||
|
|
||||||
//选中地区
|
//选中地区
|
||||||
let selectData = reactive({data: []})
|
let selectData = reactive({ data: [] })
|
||||||
let selectTabCheck = reactive({
|
let selectTabCheck = reactive({
|
||||||
id: "",
|
id: "",
|
||||||
title: "",
|
title: "",
|
||||||
@ -441,10 +441,10 @@ let selectTabCheck = reactive({
|
|||||||
//最新发布选项
|
//最新发布选项
|
||||||
let listSort = shallowReactive({
|
let listSort = shallowReactive({
|
||||||
type: [
|
type: [
|
||||||
{title: "最新发布", type: "timestamp"},
|
{ title: "最新发布", type: "timestamp" },
|
||||||
{title: "热门", type: "hotnum"},
|
{ title: "热门", type: "hotnum" },
|
||||||
{title: "价格从低到高", type: "rentasc"},
|
{ title: "价格从低到高", type: "rentasc" },
|
||||||
{title: "价格从高到低", type: "rentdesc"},
|
{ title: "价格从高到低", type: "rentdesc" },
|
||||||
],
|
],
|
||||||
checkType: "timestamp",
|
checkType: "timestamp",
|
||||||
check: "最新发布",
|
check: "最新发布",
|
||||||
@ -494,11 +494,11 @@ defineExpose({
|
|||||||
|
|
||||||
// 跳转我的页面
|
// 跳转我的页面
|
||||||
const gouser = tab => {
|
const gouser = tab => {
|
||||||
if (!store.state["user"]["uid"]) {
|
if (store.state["user"]["uid"] > 0 || store.state["user"]["uin"] > 0) {
|
||||||
store.state.showloginmodal = true
|
route.push(`/user?tab=${tab}`)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
route.push(`/user?tab=${tab}`)
|
store.state.showloginmodal = true
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style scoped lang="less">
|
<style scoped lang="less">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user