跳转改为打开新页面
This commit is contained in:
@@ -184,12 +184,15 @@ let watchInfo = () => {
|
||||
store.state.seachSelect['seachPage'][key] = seachData[key]
|
||||
}
|
||||
}
|
||||
router.push({
|
||||
path: '/detail',
|
||||
query: {
|
||||
id: data.data.uniqid,
|
||||
}
|
||||
})
|
||||
// console.log(document.location.origin)
|
||||
// return
|
||||
window.open(`${document.location.origin}/detail?id=${data.data.uniqid}`)
|
||||
// router.push({
|
||||
// path: '/detail',
|
||||
// query: {
|
||||
// id: data.data.uniqid,
|
||||
// }
|
||||
// })
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
|
||||
@@ -116,13 +116,15 @@ location.data = store.state.indexData.config.location
|
||||
|
||||
let router = useRouter()
|
||||
let watchInfo = () => {
|
||||
router.push({
|
||||
path: itemData.type === 'apartment' ? '/apartmentDetail' : '/detail',
|
||||
query: {
|
||||
// id: itemData.type=='apartment'?itemData.id:itemData.uniqid,
|
||||
[itemData.type == 'apartment' ? "uniqid" : "id"]: itemData.type == 'apartment' ? itemData.id : itemData.uniqid
|
||||
}
|
||||
})
|
||||
// console.log(router,window.location.href)
|
||||
window.open(`${router,window.location.href}${itemData.type === 'apartment' ? 'apartmentDetail' : 'detail'}?${itemData.type == 'apartment' ? "uniqid" : "id"}=${itemData.type == 'apartment' ? itemData.id : itemData.uniqid}`)
|
||||
// router.push({
|
||||
// path: itemData.type === 'apartment' ? '/apartmentDetail' : '/detail',
|
||||
// query: {
|
||||
// // id: itemData.type=='apartment'?itemData.id:itemData.uniqid,
|
||||
// [itemData.type == 'apartment' ? "uniqid" : "id"]: itemData.type == 'apartment' ? itemData.id : itemData.uniqid
|
||||
// }
|
||||
// })
|
||||
}
|
||||
|
||||
let watchAdv = () => {
|
||||
|
||||
@@ -450,7 +450,7 @@ let getLocationData = (data) => {
|
||||
|
||||
//更新当前数据数量
|
||||
let setListCount = (item, num) => {
|
||||
console.log(item, num)
|
||||
// console.log(item, num)
|
||||
// console.log(seachKey.key)
|
||||
if (item.tabType === "intermediary") {
|
||||
seachKey.key['intermediary']['count'] = num
|
||||
|
||||
@@ -120,11 +120,6 @@ const router = createRouter({
|
||||
|
||||
|
||||
router.beforeEach((to, from, next) => {
|
||||
//导航数据
|
||||
if (/['needHousing','intermediaryHousing','personHousing']/.test(from.path)) {
|
||||
store.state.routeList.secondaryIndex.title = from.meta.title
|
||||
store.state.routeList.secondaryIndex.path = from.meta.path
|
||||
}
|
||||
next()
|
||||
let meta = to['meta'] || {}
|
||||
let title = meta['title']
|
||||
|
||||
@@ -355,7 +355,10 @@ onBeforeUnmount(() => {
|
||||
})
|
||||
|
||||
// 公共跳转
|
||||
const publicJump = path => router.push(path)
|
||||
const publicJump = path => {
|
||||
//router.push(path)
|
||||
window.open(`${document.location.origin}${path}`)
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
@@ -514,7 +514,8 @@
|
||||
<!-- <img src="../assets/img/detail/line.svg" class="line-img" alt=""> -->
|
||||
<div class="dis-f al-item s-w-100" style="position:absolute;">
|
||||
<div class="line-school-box dis-f al-item" style="justify-content:space-around;">
|
||||
<div v-for="(item, i) in distanceList" class="box-text" :key="item && item.id">
|
||||
<div v-for="(item, i) in distanceList" class="box-text" :key="item && item.id"
|
||||
v-show="i < 9&&item.id">
|
||||
<div :class="{ 'far-s': item && item.recently_distance > 4 }"
|
||||
v-if="item && !item.address" class="text-c">
|
||||
{{ item && item.recently_distance }}km
|
||||
@@ -556,10 +557,10 @@
|
||||
<div class="houseing-info-box dis-f al-item jus-bet">
|
||||
<div class="dis-f al-item">
|
||||
房源ID :  <span class="houseing-id" @click="clone(housingInfo['data'] &&
|
||||
housingInfo['data'].info.uid)">{{ housingInfo['data']
|
||||
&& housingInfo['data'].info.uid }}</span>
|
||||
housingInfo['data'].info.id)">{{ housingInfo['data'] && housingInfo['data'].info.id
|
||||
}}</span>
|
||||
<span class="browse-box">
|
||||
浏览 : <span class="text">{{ housingInfo['data'] && housingInfo['data'].info.count_view
|
||||
浏览 :<span class="text">{{ housingInfo['data'] && housingInfo['data'].info.count_view
|
||||
}}</span>
|
||||
</span>
|
||||
</div>
|
||||
@@ -1174,8 +1175,10 @@ let clone = (text) => {
|
||||
document.body.removeChild(textareaEle);
|
||||
ElMessage({
|
||||
message: '复制成功',
|
||||
type: 'success',
|
||||
center: true,
|
||||
offset: 320,
|
||||
duration:1000,
|
||||
customClass: 'message-info'
|
||||
})
|
||||
}
|
||||
|
||||
@@ -2725,7 +2728,7 @@ img {
|
||||
|
||||
.show-distance-info-box {
|
||||
border-width: 1px;
|
||||
border-style: solid;
|
||||
/* border-style: solid; */
|
||||
border-color: rgba(235, 235, 235, 1);
|
||||
-moz-box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.0784313725490196);
|
||||
-webkit-box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.0784313725490196);
|
||||
@@ -2967,4 +2970,19 @@ img {
|
||||
z-index: 999;
|
||||
}
|
||||
</style>
|
||||
<style>
|
||||
.message-info {
|
||||
background: #000000;
|
||||
border-color: #000000;
|
||||
color: #fff;
|
||||
|
||||
.el-message__content {
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.el-icon {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user