Переглянути джерело

首页按钮修改为新页面打开

肖栋 1 тиждень тому
батько
коміт
437a51a493
3 змінених файлів з 33 додано та 67 видалено
  1. BIN
      src/assets/images/doubao_img.png
  2. 3 3
      src/pages/guide/index.vue
  3. 30 64
      src/pages/home/index.vue

BIN
src/assets/images/doubao_img.png


+ 3 - 3
src/pages/guide/index.vue

@@ -129,7 +129,7 @@
                       <div class="home-guide-tool-step-copy">
                         <div class="home-guide-tool-step-title">验证接入是否成功</div>
                         <div class="home-guide-tool-step-desc">
-                          按环境法规、标准导则、政策问答分别验证(见下方验证卡片)
+                          在对话中发送「用环评云助手MCP检索《大气污染物综合排放标准》中关于 VOCs 排放限值的规定」
                         </div>
                       </div>
                     </div>
@@ -603,11 +603,11 @@ onMounted(() => {
   fetchMcpToken();
 });
 const guideAccessTab = ref("mcp");
-const guideToolTab = ref("workbuddy");
+const guideToolTab = ref("qianwen");
 const guideTools = [
+  { key: "qianwen", label: "千问办公", iconName: "qianwen_icon" },
   { key: "workbuddy", label: "WorkBuddy", iconName: "WorkBuddy_icon" },
   { key: "doubao", label: "豆包", iconName: "doubao_icon" },
-  { key: "qianwen", label: "千问办公", iconName: "qianwen_icon" },
   { key: "qoderwork", label: "Qoderwork", iconName: "Qoderwork_icon" },
 ];
 const guideDoubaoContent = {

+ 30 - 64
src/pages/home/index.vue

@@ -15,16 +15,16 @@
           面向标准核查、报告编制、合规咨询、政策问答等场景,为 AI 工具提供专业、可信、可追溯的环境知识服务。
         </p>
         <div class="home-hero-actions">
-          <button type="button" class="home-hero-btn home-hero-btn-primary" @click="router.push({ name: 'mcpServer' })">
+          <button type="button" class="home-hero-btn home-hero-btn-primary" @click="openRouteInNewTab('mcpServer')">
             <icon-svg name="cut_in_Mcp" size="16px" />
             <span>立即接入 MCP</span>
           </button>
-          <button type="button" class="home-hero-btn home-hero-btn-secondary" @click="router.push({ name: 'guide' })">
+          <button type="button" class="home-hero-btn home-hero-btn-secondary" @click="openRouteInNewTab('guide')">
             <icon-svg name="connection_guide" size="16px" />
             <span>接入指南</span>
           </button>
           <button type="button" class="home-hero-btn home-hero-btn-secondary"
-            @click="router.push({ name: 'mcpOnlineTest' })">
+            @click="openRouteInNewTab('mcpOnlineTest')">
             <icon-svg name="effect_experience" size="16px" />
             <span>效果体验</span>
           </button>
@@ -124,20 +124,11 @@
             </div>
           </div>
           <div class="home-scenes-cards">
-            <div
-              v-for="item in hotServerList"
-              :key="item.id"
-              class="home-scenes-card"
-              :style="item.cardBackground ? { background: item.cardBackground } : undefined"
-            >
+            <div v-for="item in hotServerList" :key="item.id" class="home-scenes-card"
+              :style="item.cardBackground ? { background: item.cardBackground } : undefined">
               <div class="home-scenes-card-head">
                 <div class="home-scenes-card-icon-box" :style="parseCssStyle(item.iconStyle)">
-                  <img
-                    v-if="item.iconUrl"
-                    :src="item.iconUrl"
-                    :alt="item.name"
-                    class="home-scenes-card-icon-img"
-                  />
+                  <img v-if="item.iconUrl" :src="item.iconUrl" :alt="item.name" class="home-scenes-card-icon-img" />
                 </div>
                 <div class="home-scenes-card-title">{{ item.name }}</div>
               </div>
@@ -147,10 +138,8 @@
               </div>
               <div class="home-scenes-card-footer">
                 <span class="home-scenes-card-stat">近30天请求 {{ formatHotRequestCount(item.requestCount30d) }}</span>
-                <router-link
-                  class="home-scenes-card-link"
-                  :to="{ name: 'mcpServer', query: { id: item.id } }"
-                >查看详情</router-link>
+                <router-link class="home-scenes-card-link"
+                  :to="{ name: 'mcpServer', query: { id: item.id } }">查看详情</router-link>
               </div>
             </div>
           </div>
@@ -175,11 +164,8 @@
               </div>
             </div>
             <div class="home-scenes-demo-preview">
-              <img
-                :src="demoCaseImages[activeDemoQuestion]"
-                :alt="demoQuestions[activeDemoQuestion]"
-                class="home-scenes-demo-preview-img"
-              />
+              <img :src="demoCaseImages[activeDemoQuestion]" :alt="demoQuestions[activeDemoQuestion]"
+                class="home-scenes-demo-preview-img" />
             </div>
           </div>
         </div>
@@ -234,12 +220,7 @@
                       @click="copyText(`Bearer ${guideToken}`)" />
                   </div>
                 </div>
-                <button
-                  v-else
-                  type="button"
-                  class="home-guide-token-btn"
-                  @click="createToken"
-                >
+                <button v-else type="button" class="home-guide-token-btn" @click="createToken">
                   <icon-svg name="gain_token" size="14px" class="home-guide-token-btn-icon" />
                   <span>获取 Token</span>
                 </button>
@@ -314,7 +295,7 @@
                       <div class="home-guide-tool-step-copy">
                         <div class="home-guide-tool-step-title">验证接入是否成功</div>
                         <div class="home-guide-tool-step-desc">
-                          按环境法规、标准导则、政策问答分别验证(见下方验证卡片)
+                          在对话中发送「用环评云助手MCP检索《大气污染物综合排放标准》中关于 VOCs 排放限值的规定」
                         </div>
                       </div>
                     </div>
@@ -406,11 +387,7 @@
                     </div>
                   </div>
                   <div class="home-guide-doubao-right">
-                    <img
-                      src="@/assets/images/doubao_img.png"
-                      alt="豆包自定义连接器示意"
-                      class="home-guide-doubao-img"
-                    />
+                    <img src="@/assets/images/doubao_img.png" alt="豆包自定义连接器示意" class="home-guide-doubao-img" />
                   </div>
                 </div>
 
@@ -756,30 +733,14 @@
               </div>
             </div>
             <div class="home-footer-links">
-              <a
-                class="home-footer-link"
-                href="https://www.eiacloud.com/lxwmhjzx/550.jhtml"
-                target="_blank"
-                rel="noopener noreferrer"
-              >关于我们</a>
-              <a
-                class="home-footer-link"
-                href="https://www.eiacloud.com/bbs/userAgreement"
-                target="_blank"
-                rel="noopener noreferrer"
-              >用户协议</a>
-              <a
-                class="home-footer-link"
-                href="https://www.eiacloud.com/hpy/lawstandardApp/getDetailYS"
-                target="_blank"
-                rel="noopener noreferrer"
-              >隐私政策</a>
-              <a
-                class="home-footer-link"
-                href="https://www.eiacloud.com/lxwmlxfs/669.jhtml"
-                target="_blank"
-                rel="noopener noreferrer"
-              >联系我们</a>
+              <a class="home-footer-link" href="https://www.eiacloud.com/lxwmhjzx/550.jhtml" target="_blank"
+                rel="noopener noreferrer">关于我们</a>
+              <a class="home-footer-link" href="https://www.eiacloud.com/bbs/userAgreement" target="_blank"
+                rel="noopener noreferrer">用户协议</a>
+              <a class="home-footer-link" href="https://www.eiacloud.com/hpy/lawstandardApp/getDetailYS" target="_blank"
+                rel="noopener noreferrer">隐私政策</a>
+              <a class="home-footer-link" href="https://www.eiacloud.com/lxwmlxfs/669.jhtml" target="_blank"
+                rel="noopener noreferrer">联系我们</a>
             </div>
           </div>
         </div>
@@ -801,6 +762,11 @@ import demoImgPurple from "@/assets/images/test_instruction_purple.jpg";
 
 const router = useRouter();
 const global = globalStore();
+
+const openRouteInNewTab = (name) => {
+  const { href } = router.resolve({ name });
+  window.open(href, "_blank");
+};
 const demoQuestions = [
   "「大气污染物综合排放标准 GB16297 相关限值要求?」",
   "「建设项目环境影响评价分类管理名录中化工项目如何分类?」",
@@ -901,11 +867,11 @@ onMounted(() => {
   fetchHotServerList();
 });
 const guideAccessTab = ref("mcp");
-const guideToolTab = ref("workbuddy");
+const guideToolTab = ref("qianwen");
 const guideTools = [
+  { key: "qianwen", label: "千问办公", iconName: "qianwen_icon" },
   { key: "workbuddy", label: "WorkBuddy", iconName: "WorkBuddy_icon" },
   { key: "doubao", label: "豆包", iconName: "doubao_icon" },
-  { key: "qianwen", label: "千问办公", iconName: "qianwen_icon" },
   { key: "qoderwork", label: "Qoderwork", iconName: "Qoderwork_icon" },
 ];
 const guideDoubaoContent = {
@@ -2173,13 +2139,13 @@ const guideVerifyCards = [
   min-width: 0;
 }
 
-.home-guide-feature > :first-child {
+.home-guide-feature> :first-child {
   flex-shrink: 0;
   width: 38px;
   height: 38px;
 }
 
-.home-guide-feature > div {
+.home-guide-feature>div {
   flex: 0 1 auto;
   min-width: 0;
 }