From e37e45cfe1123928dba5d9c5a427b0ee497b7ad6 Mon Sep 17 00:00:00 2001
From: zhangzengfei <zhangzengfei@smartai.com>
Date: 星期二, 23 八月 2022 03:21:32 +0800
Subject: [PATCH] 修复算法配置的字段内容

---
 src/views/index/components/productLeft.vue |   28 ++++++++++++++++++++++++----
 1 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/src/views/index/components/productLeft.vue b/src/views/index/components/productLeft.vue
index 9897cce..e1c213e 100644
--- a/src/views/index/components/productLeft.vue
+++ b/src/views/index/components/productLeft.vue
@@ -1,14 +1,21 @@
 <template>
-  <div class="productLeft" :style="{ background: ` url(${data.img})` }">
+  <div
+    class="productLeft"
+    :style="{
+      background: ` url(${pic})`,
+      backgroundSize: '100% 100%',
+      backgroundRepeat: 'no-repeat',
+    }"
+  >
     <div class="inner">
       <div class="title">
-        {{ data.title }}
+        {{ data.name }}
       </div>
       <div class="des">
-        {{ data.des }}
+        {{ data.desc }}
       </div>
       <div class="button">
-        <router-link :to="data.router">鏌ョ湅鍏ㄩ儴</router-link>
+        <router-link to="/product">鏌ョ湅鍏ㄩ儴</router-link>
       </div>
     </div>
   </div>
@@ -21,6 +28,19 @@
       type: Object,
     },
   },
+  created() {
+    var reg = /^[0-9]/;
+    if (reg.test(this.data.pic)) {
+      this.pic = "/httpImage/" + this.data.pic;
+    } else {
+      this.pic = this.data.pic;
+    }
+  },
+  data() {
+    return {
+      pic: "",
+    };
+  },
 };
 </script>
 

--
Gitblit v1.8.0