From 6e2fdc6bd7dabc037d565f895dec85c9832b7b4a Mon Sep 17 00:00:00 2001 From: lf <1534621107@qq.com> Date: Mon, 17 Jun 2024 16:28:39 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BF=94=E5=9B=9E=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/index/index.vue | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 3cfb6e9..ea30f69 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -53,7 +53,10 @@ interface SrcListType { title?: string } -const srcList = reactive({}) +const srcList = reactive({ + url: '', + title: '', +}) const dataObj = reactive({}) function handleMessage(event: any) { @@ -87,6 +90,7 @@ const getUrlPathName = () => { window.parent.addEventListener('message', function (event) { let srcData = {} + const timestamp = new Date().getTime() if (event.data.data.type === 'login') { srcData = { url: contentData.content_templates.source + `?activity_code=${query.value}`, @@ -115,7 +119,8 @@ window.parent.addEventListener('message', function (event) { title: contentData.login_content_templates.moduledesc, } } - Object.assign(srcList, {}) + srcList.url = + srcList.url + (srcList.url.includes('?') ? '×tamp=' : '?timestamp=') + timestamp nextTick(() => { Object.assign(srcList, srcData) uni.setNavigationBarTitle({