From 63b09af19055715d9eab952d213dfede24851a06 Mon Sep 17 00:00:00 2001 From: A1300399510 Date: Fri, 4 Aug 2023 12:28:10 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=8F=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/public/apartment-item.vue | 2 +- src/components/public/public-list-item.vue | 5 ++-- src/components/public/transmitBtn.vue | 28 ++++++++++++++++++++-- src/router/index.js | 3 --- src/views/edit.vue | 3 ++- 5 files changed, 32 insertions(+), 9 deletions(-) diff --git a/src/components/public/apartment-item.vue b/src/components/public/apartment-item.vue index 0fc1cd5..a491501 100644 --- a/src/components/public/apartment-item.vue +++ b/src/components/public/apartment-item.vue @@ -40,7 +40,7 @@ const props = defineProps({ item: Object, }); -const goapArtmentDetails = () => redirectToExternalWebsite(`${location.origin}/apartmentDetail?uniqid=${props['item'].uniqid}`) +const goapArtmentDetails = () => redirectToExternalWebsite(`/apartmentDetail?uniqid=${props['item'].uniqid}`) // router.push(`/apartmentDetail?uniqid=${props['item'].uniqid}`) diff --git a/src/components/public/public-list-item.vue b/src/components/public/public-list-item.vue index ee3f4fc..ebcc40d 100644 --- a/src/components/public/public-list-item.vue +++ b/src/components/public/public-list-item.vue @@ -120,7 +120,7 @@ import { ref, watch, defineProps, reactive, defineEmits, onMounted, getCurrentInstance } from "vue"; import { useRoute, useRouter } from 'vue-router'; import { ElMessage, ElMessageBox } from 'element-plus' - +import { redirectToExternalWebsite } from '@/utils/util.js' import store from '../../store/index'; const { proxy } = getCurrentInstance() @@ -191,7 +191,8 @@ const cancelCollection = token => emit('cancelCollection', { token, index: props // 点击跳转详情页 const goDetail = status => { - if (status == 1) router.push(`/detail?id=${data.uniqid}`) + console.log("location.origin",location.origin); + if (status == 1) redirectToExternalWebsite(`/detail?id=${data.uniqid}`) else ElMessage("该房源信息已出租或已失效") } diff --git a/src/components/public/transmitBtn.vue b/src/components/public/transmitBtn.vue index c6f5840..a7df09e 100644 --- a/src/components/public/transmitBtn.vue +++ b/src/components/public/transmitBtn.vue @@ -44,13 +44,16 @@ const popperOptions = ref({ { name: 'offset', options: { - offset: [38, 0] // 设置左偏移为20px,右偏移为0px + // offset: [38, 0] // 设置左偏移为20px,右偏移为0px + offset: [142, 10] // 设置左偏移为20px,右偏移为0px } } ] }); if (props['type'] == 'housingTop') popperOptions.value['modifiers'][0]['options']['offset'][0] = 14 +if (props['type'] == 'housing') popperOptions.value['modifiers'][0]['options']['offset'][0] = 38 +// console.log("newValue", props['type']); watch(() => props.concatType, (newValue, oldValue) => { @@ -67,7 +70,13 @@ let url = location.href const copy = () => { copyToClipboard(`${props['title']} - ${url}`).then(() => { - ElMessage.success("复制成功!!!") + ElMessage({ + message: '复制成功', + center: true, + offset: 320, + duration: 1000, + customClass: 'message-info' + }) }) } @@ -189,4 +198,19 @@ const copy = () => { cursor: pointer; color: #000; } + + \ No newline at end of file diff --git a/src/router/index.js b/src/router/index.js index 1d6fbbc..0d70a4c 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -131,7 +131,6 @@ const router = createRouter({ router.beforeEach((to, from, next) => { - console.log("开始"); //进度条开始 NProgress.start(); //随机增加进度 @@ -145,7 +144,5 @@ router.beforeEach((to, from, next) => { router.afterEach(() => { NProgress.done(true); - console.log("NProgress",NProgress); - console.log("结束"); }) export default router diff --git a/src/views/edit.vue b/src/views/edit.vue index 31f7c3f..91cf43e 100644 --- a/src/views/edit.vue +++ b/src/views/edit.vue @@ -1958,7 +1958,7 @@ export default { .media-item { width: 100px; position: relative; - cursor: pointer; + // cursor: pointer; flex-direction: column; &:not(:nth-last-child(-n+5)) { @@ -2032,6 +2032,7 @@ export default { border: 1px solid rgba(215, 215, 215, 1); color: #aaa; font-weight: 400; + cursor: pointer; } .media-play-icon {