增加加载提示语 添加搜索同步url 修改搜索页搜索类型显示
This commit is contained in:
@@ -215,11 +215,14 @@ let selectPage = (type) => {
|
||||
seachAllType['searchid'] = setPageKey()
|
||||
if (type === 'person') {
|
||||
seachAllType['intermediary'] = 0
|
||||
route.currentRoute.value.query.houseingPageType='0'
|
||||
houseingPageType='0'
|
||||
sessionStorage.setItem('houseingPageType',0)
|
||||
selectTabBoxInfo.value.routerQuerySet()
|
||||
} else if (type === 'intermediary') {
|
||||
seachAllType['intermediary'] = 1
|
||||
route.currentRoute.value.query.houseingPageType='1'
|
||||
houseingPageType='1'
|
||||
sessionStorage.setItem('houseingPageType',1)
|
||||
// route.currentRoute.value.query.houseingPageType='1'
|
||||
selectTabBoxInfo.value.routerQuerySet()
|
||||
} else {
|
||||
seachAllType['intermediary'] = ''
|
||||
@@ -238,8 +241,8 @@ seachVal.value = route.currentRoute.value.query.keyword&&route.currentRoute.valu
|
||||
isNeedHousing.value = route.currentRoute.value.query.isNeedHousing === 'true'
|
||||
|
||||
//判断当前是什么页面
|
||||
let houseingPageType = route.currentRoute.value.query.houseingPageType
|
||||
console.log('houseingPageType',route.currentRoute.value.query)
|
||||
let houseingPageType = sessionStorage.getItem('houseingPageType')
|
||||
console.log('houseingPageType',houseingPageType)
|
||||
let type = houseingPageType === '0' ? 'person' : houseingPageType === '1' ? 'intermediary' : houseingPageType === '6' ? 'need' : 'apartment'
|
||||
tabType.value = type
|
||||
|
||||
@@ -336,6 +339,7 @@ let searchInit = (data) => {
|
||||
}
|
||||
//搜索数据
|
||||
let seachList = (item) => {
|
||||
let routeInfo = route.currentRoute.value
|
||||
if (!seachVal.value.replace(/\s/g, "")) return
|
||||
if (!seachVal.value) {
|
||||
return
|
||||
@@ -346,6 +350,13 @@ let seachList = (item) => {
|
||||
} else {
|
||||
searchInit(seachVal.value)
|
||||
}
|
||||
route.push({
|
||||
path:routeInfo.path,
|
||||
query:{
|
||||
keyword:seachVal.value,
|
||||
isNeedHousing:routeInfo.query.isNeedHousing
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
//筛选词条
|
||||
|
||||
Reference in New Issue
Block a user