瀏覽代碼

修改注意事项跳转页面

shmily1213 1 月之前
父節點
當前提交
ca579eaada

+ 1 - 0
index.html

@@ -2,6 +2,7 @@
 <html lang="zh" translate="no">
   <head>
     <meta charset="UTF-8" />
+    <meta name="referrer" content="never">
     <meta name="google" content="notranslate" />
     <script>
       var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') ||

+ 1 - 1
src/common/mxConst.js

@@ -26,7 +26,7 @@ const consts = {
         basicInfo: '/pages/personal-center/basic-info/basic-info',
         newsIndex: '/pages/news/index/index',
         newsDetail: '/pagesOther/pages/news/detail/detail',
-        newsGroup: '/pages/news/group/group',
+        newsGroup: '/pagesOther/pages/news/group/group',
         videoPlay: '/pages/video-center/play/play'
     },
     globalEvents: {

+ 2 - 2
src/pagesMain/pages/index/components/index-guide.vue

@@ -58,11 +58,11 @@ const handleChange = (e: any) => {
 }
 
 const emit = defineEmits<{
-  detail: [id: number | string]
+  detail: [id: number | string, title: string]
 }>();
 
 const handleClick = async (data: Guide) => {
-  emit('detail', data.refIds);
+  emit('detail', data.refIds, data.subType);
 }
 
 const loadData = () => {

+ 6 - 3
src/pagesMain/pages/index/index.vue

@@ -36,12 +36,15 @@ const { transferTo } = useTransferPage();
 const { baseStickyTop } = useNavbar();
 const userStore = useUserStore();
 
-const handleDetail = async (id: number | string) => {
+const handleDetail = async (id: number | string, title?: string) => {
   const isLogin = await userStore.checkLogin();
   if (isLogin) {
-    transferTo(mxConst.routes.newsDetail, {
+    const pagePath = ('' + id).includes(',') ? mxConst.routes.newsGroup : mxConst.routes.newsDetail;
+    console.log(pagePath)
+    transferTo(pagePath, {
       data: {
-        id: id
+        id: id,
+        title: title
       }
     });
   }

+ 1 - 0
src/pagesOther/pages/news/detail/detail.vue

@@ -44,6 +44,7 @@ onMounted(async () => {
     ::v-deep table {
         width: 100%;
         max-width: 100%;
+        height: auto;
     }
 
     ::v-deep p {