判断搜索数据数量
This commit is contained in:
parent
202958798b
commit
e938cb645a
@ -395,7 +395,7 @@ let searchInit = (data) => {
|
||||
if (res.code === 200) {
|
||||
seachKey.key = res.data
|
||||
seachInfoData.data=JSON.parse(JSON.stringify(res.data))
|
||||
let seachObj=setSeachId()
|
||||
let seachObj=checkSearckInit(setSeachId())
|
||||
seachAllType.searchid = seachObj.searchid
|
||||
getDataList(seachAllType,seachObj.count==0?false:true)
|
||||
} else {
|
||||
@ -406,6 +406,24 @@ let searchInit = (data) => {
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
//判断搜索数据数量
|
||||
let checkSearckInit=(data)=>{
|
||||
if(data.count) return data
|
||||
let obj={}
|
||||
if(seachInfoData.data.personal.count>0){
|
||||
obj=seachInfoData.data.personal
|
||||
tabType.value = 'person'
|
||||
}else if(seachInfoData.data.intermediary.count>0){
|
||||
obj=seachInfoData.data.intermediary
|
||||
tabType.value = 'intermediary'
|
||||
}else if(seachInfoData.data.studentapartment.count>0){
|
||||
obj=seachInfoData.data.studentapartment
|
||||
tabType.value = 'apartment'
|
||||
}else setSeachId()
|
||||
return obj
|
||||
}
|
||||
|
||||
//搜索数据
|
||||
let seachList = (item) => {
|
||||
let routeInfo = route.currentRoute.value
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="box-min-1200-src">
|
||||
<pageTopBar></pageTopBar>
|
||||
<inputModule :getDataList="setSeachSelectData" :count="dataCount" ref="inputModuleInfo"></inputModule>
|
||||
<div class="dis-f jus-x al-item">
|
||||
|
Loading…
x
Reference in New Issue
Block a user