From 1ceae382ec367b71df602e2cfd97a273dfaacecb Mon Sep 17 00:00:00 2001
From: boyang <1920788179@qq.com>
Date: Thu, 21 Nov 2024 09:46:03 +0800
Subject: [PATCH] fix: prod2.sh-20/21

---
 components/ProductDetail.vue | 19 +++++++++++--------
 deploy/prod2.sh              |  4 ++--
 2 files changed, 13 insertions(+), 10 deletions(-)

diff --git a/components/ProductDetail.vue b/components/ProductDetail.vue
index f1d2f9d..572123a 100644
--- a/components/ProductDetail.vue
+++ b/components/ProductDetail.vue
@@ -362,7 +362,7 @@ const items = ref<BreadcrumbItem[]>([
   {
     title: "Products",
     disabled: false,
-    href: "/products",
+    href: "https://www.canrud.com/products",
   },
   {
     title: "CATEGORY",
@@ -406,12 +406,11 @@ let { data: resData } = await useAsyncData(
   }
 );
 watchEffect(() => {
-  console.log(info,'5656info');
   if (info?.productCrumbsVO?.category1 && productStore.keyword) {
     items.value[1].title = info.productCrumbsVO.category1;
     items.value[1].href =
-      href1.value + "?categories=" + info.productCrumbsVO.category1;
-    href1.value = href1.value + "?categories=" + info.productCrumbsVO.category1;
+        "https://www.canrud.com/products?categories=" + info.productCrumbsVO.category1;
+    href1.value = "https://www.canrud.com/products?categories=" + info.productCrumbsVO.category1;
     if (info?.productCrumbsVO?.category2) {
       items.value[2].title = info.productCrumbsVO.category2;
       href2.value = href1.value + "," + info.productCrumbsVO.category2;
@@ -427,6 +426,8 @@ watchEffect(() => {
       items.value[3].href =
         href2.value + "&function=" + info.productCrumbsVO.function;
     }
+    items.value[4].title = info.name;
+    items.value[4].href = "https://www.canrud.com/products/detail/" + info.id;
   } else if (routeQuery.categories) {
     if (!routeQuery.categories.includes("Energy materials")) {
       routeQuery.updateFunction("Not specified");
@@ -443,8 +444,8 @@ watchEffect(() => {
       items.value[2].title = subCategoryName.value;
     }
     items.value[1].title = mainCategory;
-    items.value[1].href = href1.value + "?categories=" + mainCategory;
-    href1.value = href1.value + "?categories=" + mainCategory;
+    items.value[1].href = "https://www.canrud.com/products?categories=" + mainCategory;
+    href1.value = "https://www.canrud.com/products?categories=" + mainCategory;
     // items.value[1].title = subCategoryName.value;
     href2.value = href1.value + "," + subCategoryName.value;
     items.value[2].href = href1.value + "," + subCategoryName.value;
@@ -459,11 +460,13 @@ watchEffect(() => {
         href2.value + "&function=" + routeQuery.selectedFunction;
       // routeQuery.updateFunction(null);
     }
+    items.value[4].title = info.name;
+    items.value[4].href = "https://www.canrud.com/products/detail/" + info.id;
   } else if (info?.productCrumbsVO?.category1) {
     items.value[1].title = info.productCrumbsVO.category1;
     items.value[1].href =
-      href1.value + "?categories=" + info.productCrumbsVO.category1;
-    href1.value = href1.value + "?categories=" + info.productCrumbsVO.category1;
+        "https://www.canrud.com/products?categories=" + info.productCrumbsVO.category1;
+    href1.value = "https://www.canrud.com/products?categories=" + info.productCrumbsVO.category1;
     if (info?.productCrumbsVO?.category2) {
       items.value[2].title = info.productCrumbsVO.category2;
       href2.value = href1.value + "," + info.productCrumbsVO.category2;
diff --git a/deploy/prod2.sh b/deploy/prod2.sh
index 5a1fe2d..216f73a 100644
--- a/deploy/prod2.sh
+++ b/deploy/prod2.sh
@@ -1,7 +1,7 @@
 #!/bin/bash
 # 变量定义
-LAST_TAG="1.0.19"
-TAG="1.0.20"
+LAST_TAG="1.0.20"
+TAG="1.0.21"
 TARGET_PATH="/root/web/canrud-outside-nuxt-front"
 DOCKERFILE_PATH="/root/web/canrud-outside-nuxt-front/canrud-nuxt-front"
 IMAGE_NAME="canrud-outside-front"
--
libgit2 0.23.3