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({