From ada8dd26266656af6ef65ad333c541db12787ceb Mon Sep 17 00:00:00 2001 From: clay <20932067@zju.edu.cn> Date: Tue, 22 Nov 2022 17:04:57 +0800 Subject: [PATCH] =?UTF-8?q?clay=20commit=20:=20=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/views/index/components/slideshow_card.vue | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/views/index/components/slideshow_card.vue b/src/views/index/components/slideshow_card.vue index cea8325..f5dd732 100644 --- a/src/views/index/components/slideshow_card.vue +++ b/src/views/index/components/slideshow_card.vue @@ -66,13 +66,13 @@ export default { }, methods: { clickTo(link) { - //console.log(link) - if (/android/i.test(navigator.userAgent)) { - window.open(link, "_blank") - } - if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) { - window.location.href = window.location.origin + link;//当前标签页 - } + // let userAgent = navigator.userAgent; //取得浏览器的userAgent字符串 + window.location.href = link + // if (userAgent.indexOf("Safari") > -1) { + // window.location.href = link + // } else { + // window.open(link, "_blank") + // } }, constructor() { this.bannerWrap = document.getElementsByClassName("banner-card")[0];