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

优化回答面板样式和删除冗余代码

songxy 2 місяців тому
батько
коміт
84356f070a

BIN
web_ui/src/assets/image/box_bg2.png


+ 54 - 231
web_ui/src/views/industrial-land/AiIndustriaLandDetail.vue

@@ -156,6 +156,7 @@
           v-if="showQuery"
         >
           <div class="left-panel-content">
+            <span class="back_icon" @click="onBackHandle"></span>
             <div v-for="(item, index) in hzData" :key="index">
               <div class="title" @click="resetAnswer(index)">
                 {{ item.name }}
@@ -274,7 +275,7 @@
             </template>
             <Spin size="large" class="span" fix v-if="loading"></Spin>
           </div>
-          <div class="textarea-panel">
+          <div class="m-textarea-panel">
             <textarea
               v-model="zwinputText"
               type="text"
@@ -565,6 +566,13 @@ export default {
   },
 
   methods: {
+    onBackHandle () {
+      this.showResult = this.showQuery = false;
+      this.hzData = []
+      this.listType = ''
+      this.inputText = ''
+      this.hintText = '思考中...'
+    },
     dSourceChange() {
       if (this.dSource === "3") {
         this.$Message.error("暂无数据,请选择其他数据源!");
@@ -669,15 +677,6 @@ export default {
           }
         });
     },
-    fullInput(item) {
-      if (!this.loading) {
-        this.activeIndex = 0;
-        this.inputText = item.name;
-        this.showQuery = false;
-      } else {
-        this.$Messages.info("正在请求中,请稍后!");
-      }
-    },
     logout() {
       this.$store.dispatch("LogOut").then(() => {
         this.$router.push({ name: "login" });
@@ -754,12 +753,6 @@ export default {
         this.questionModal = true;
       }
     },
-    showFlowChart() {
-      this.modal = true;
-      this.$nextTick(() => {
-        this.$refs.flow.open();
-      });
-    },
 
     hideModal() {
       this.modal = false;
@@ -2019,6 +2012,37 @@ export default {
   height: 200px;
 }
 
+.m-textarea-panel {
+  width: 100%;
+  height: 150px;
+  background: #ffffff;
+  position: relative;
+  padding: 17px 0px 0px 19px;
+  box-shadow: 0px 8px 16px 1px rgba(0, 57, 124, 0.2);
+  border-radius: 16px 16px 16px 16px;
+  position: relative;
+  padding-bottom: 50px;
+  border: 1px solid #E5E6EA;
+  textarea {
+    border: none;
+    resize: none;
+    width: calc(100% - 40px);
+    font-weight: normal;
+    font-size: 18px;
+    height: 100%;
+    &:focus-visible {
+      outline: none;
+    }
+
+    &::placeholder {
+      font-family: Microsoft YaHei;
+      font-weight: bold;
+      font-size: 18px;
+      color: #6a7177;
+    }
+  }
+}
+
 .industria-land-detail {
   width: 100%;
   position: relative;
@@ -2249,7 +2273,7 @@ export default {
         background-image: url(~@/assets/image/box_bg.png);
         background-repeat: no-repeat;
         background-size: 100% 100%;
-        padding: 40px 20px;
+        padding: 30px 20px;
         > .box {
           flex: 1;
           display: flex;
@@ -2363,36 +2387,6 @@ export default {
             }
           }
         }
-        .m-textarea-panel {
-          width: 100%;
-          height: 150px;
-          background: #ffffff;
-          position: relative;
-          padding: 17px 0px 0px 19px;
-          box-shadow: 0px 8px 16px 1px rgba(0, 57, 124, 0.2);
-          border-radius: 16px 16px 16px 16px;
-          position: relative;
-          padding-bottom: 50px;
-          border: 1px solid #E5E6EA;
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 40px);
-            font-weight: normal;
-            font-size: 18px;
-            height: 100%;
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-weight: bold;
-              font-size: 18px;
-              color: #6a7177;
-            }
-          }
-        }
       }
 
       .left-panel {
@@ -2408,20 +2402,22 @@ export default {
 
         .left-panel-content {
           width: 100%;
-          height: calc(100% - 120px);
+          height: calc(100% - 150px);
           overflow-x: hidden;
           overflow-y: auto;
+          position: relative;
+          >.back_icon {
+            position: absolute;
+            top: 6px;
+            right: 0px;
+            width: 30px;
+            height: 30px;
+            cursor: pointer;
+            background: url("../../assets/image/back-icon.png") no-repeat;
+            background-size: 100% 100%;
+          }
         }
 
-        .logo {
-          font-family: REEJI-FlashSansN95;
-          font-weight: 900;
-          font-size: 28px;
-          color: #333333;
-          line-height: 36px;
-          margin-bottom: 31px;
-          height: 30px;
-        }
 
         .desc {
           font-family: Microsoft YaHei;
@@ -2430,94 +2426,6 @@ export default {
           color: #333333;
         }
 
-        .hint {
-          font-family: Microsoft YaHei;
-          font-weight: 400;
-          font-size: 16px;
-          color: #2879e7;
-          margin-bottom: 30px;
-          margin-top: 40px;
-        }
-
-        .hot-question-item {
-          display: flex;
-          margin-bottom: 20px;
-
-          img {
-            width: 32px;
-            height: 32px;
-            margin-right: 8px;
-          }
-
-          .right-nr {
-            width: calc(100% - 43px);
-            cursor: pointer;
-            padding: 17px 32px 16px 20px;
-            background: linear-gradient(90deg, #c7dcf8, #e8eafd);
-            border-radius: 10px;
-            font-family: PingFang SC;
-            font-weight: 500;
-            font-size: 14px;
-            color: #333333;
-          }
-
-          .right-nr:hover {
-            border: 1px solid #2879e7;
-          }
-        }
-
-        .diver44 {
-          height: 44px;
-        }
-
-        .m-textarea-panel {
-          width: 100%;
-          height: 105px;
-          background: #ffffff;
-          border-radius: 10px;
-          position: relative;
-          padding: 17px 0px 0px 19px;
-
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 60px);
-            font-weight: normal;
-            font-size: 16px;
-            height: 100%;
-
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-weight: 400;
-              font-size: 14px;
-              color: #999999;
-            }
-          }
-
-          .btn {
-            width: 40px;
-            height: 40px;
-            position: absolute;
-            right: 17px;
-            cursor: pointer;
-            bottom: 14px;
-            display: flex;
-            align-items: center;
-            justify-content: center;
-            background: linear-gradient(90deg, #5c62ea, #517de2);
-            border-radius: 20px;
-
-            img {
-              width: 20px;
-              height: 20px;
-            }
-          }
-        }
-
         .back-icon {
           position: absolute;
           top: 26px;
@@ -2538,6 +2446,7 @@ export default {
           cursor: pointer;
           line-height: 36px;
           margin-bottom: 36px;
+          padding-right: 50px;
         }
         .jsz {
           margin: 0 0px 17px 0px;
@@ -2603,42 +2512,6 @@ export default {
           }
         }
 
-        .tab-panel {
-          padding-left: 3px;
-          display: flex;
-
-          .item {
-            display: flex;
-            margin-right: 48px;
-            cursor: pointer;
-            flex-direction: column;
-
-            .name {
-              width: 120px;
-              height: 20px;
-              font-family: Microsoft YaHei;
-              font-weight: 400;
-              font-size: 20px;
-              color: #465d7c;
-              line-height: 36px;
-            }
-
-            .selected {
-              font-weight: bold;
-              color: #333333;
-            }
-
-            .line {
-              margin-top: 20px;
-              width: 116px;
-              height: 6px;
-              background: url("~@/assets/image/cyyd/tab-select.png") no-repeat
-                center;
-              background-size: 100% 100%;
-            }
-          }
-        }
-
         .summary-content {
           display: flex;
 
@@ -2764,56 +2637,6 @@ export default {
           }
         }
 
-        .textarea-panel {
-          margin: 28px 3px 0px 3px;
-          width: 424px;
-          height: 120px;
-          background: #ffffff;
-          position: absolute;
-          bottom: 26px;
-          padding: 18px 0px 0px 19px;
-          box-shadow: 0px 6px 12px 1px rgba(11, 53, 103, 0.08);
-          border-radius: 16px 16px 16px 16px;
-          border: 1px solid #e5e6ea;
-          position: relative;
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 60px);
-            font-weight: normal;
-            font-size: 18px;
-
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-size: 20px;
-              color: #a7aeb4;
-            }
-          }
-
-          .btn {
-            width: 40px;
-            height: 40px;
-            position: absolute;
-            right: 17px;
-            cursor: pointer;
-            bottom: 14px;
-            display: flex;
-            align-items: center;
-            justify-content: center;
-            background: linear-gradient(124deg, #505dff 0%, #418cff 100%);
-            border-radius: 10px 10px 10px 10px;
-
-            img {
-              width: 20px;
-              height: 20px;
-            }
-          }
-        }
-
         .xg-title {
           height: 20px;
           margin-top: 28px;

+ 48 - 245
web_ui/src/views/znzt-land/AiZtzsDetail.vue

@@ -224,7 +224,7 @@
             </template>
             <Spin size="large" class="span" fix v-if="loading"></Spin>
           </div>
-          <div class="textarea-panel">
+          <div class="m-textarea-panel">
             <textarea
               v-model="zwinputText"
               type="text"
@@ -685,15 +685,6 @@ export default {
           }
         });
     },
-    fullInput(item) {
-      if (!this.loading) {
-        this.activeIndex = 0;
-        this.inputText = item.name;
-        this.showQuery = false;
-      } else {
-        this.$Messages.info("正在请求中,请稍后!");
-      }
-    },
     logout() {
       this.$store.dispatch("LogOut").then(() => {
         this.$router.push({ name: "login" });
@@ -784,27 +775,11 @@ export default {
         this.questionModal = true;
       }
     },
-    showFlowChart() {
-      this.modal = true;
-      this.$nextTick(() => {
-        this.$refs.flow.open();
-      });
-    },
 
     hideModal() {
       this.modal = false;
     },
     hideFeekBackModal() {},
-    showTableInfo() {
-      this.showTableModal = true;
-      this.$nextTick(() => {
-        this.$refs.table.open();
-      });
-    },
-
-    hideTableModal() {
-      this.showTableModal = false;
-    },
     //图层控制
     switchMapLayer(item) {
       if (item.checked) {
@@ -1813,6 +1788,36 @@ export default {
   height: 200px;
 }
 
+.m-textarea-panel {
+  width: 100%;
+  height: 150px;
+  background: #ffffff;
+  position: relative;
+  padding: 17px 0px 0px 19px;
+  box-shadow: 0px 8px 16px 1px rgba(0, 57, 124, 0.2);
+  border-radius: 16px 16px 16px 16px;
+  position: relative;
+  padding-bottom: 50px;
+  border: 1px solid #E5E6EA;
+  textarea {
+    border: none;
+    resize: none;
+    width: calc(100% - 40px);
+    font-weight: normal;
+    font-size: 18px;
+    height: 100%;
+    &:focus-visible {
+      outline: none;
+    }
+
+    &::placeholder {
+      font-family: Microsoft YaHei;
+      font-weight: bold;
+      font-size: 18px;
+      color: #6a7177;
+    }
+  }
+}
 .industria-land-detail {
   width: 100%;
   position: relative;
@@ -2040,7 +2045,7 @@ export default {
         background-image: url(~@/assets/image/box_bg.png);
         background-repeat: no-repeat;
         background-size: 100% 100%;
-        padding: 40px 20px;
+        padding: 30px 20px;
         > .box {
           flex: 1;
           display: flex;
@@ -2179,52 +2184,33 @@ export default {
             }
           }
         }
-        .m-textarea-panel {
-          width: 100%;
-          height: 150px;
-          background: #ffffff;
-          position: relative;
-          padding: 17px 0px 0px 19px;
-          box-shadow: 0px 8px 16px 1px rgba(0, 57, 124, 0.2);
-          border-radius: 16px 16px 16px 16px;
-          position: relative;
-          padding-bottom: 50px;
-          border: 1px solid #E5E6EA;
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 40px);
-            font-weight: normal;
-            font-size: 18px;
-            height: 100%;
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-weight: bold;
-              font-size: 18px;
-              color: #6a7177;
-            }
-          }
-        }
       }
 
       .left-panel {
         width: 486px;
-        padding: 26px 29px 32px 31px;
         z-index: 11;
         height: 100%;
         position: absolute;
         left: 0;
         top: 0;
-        // background: linear-gradient(-30deg, #d6e8fb, #ffffff);
         background-color: #fff;
-
+        padding: 30px 20px;
+        &::before {
+          content: "";
+          display: block;
+          position: absolute;
+          left: 0px;
+          right: 0px;
+          top: 0px;
+          bottom: 0px;
+          background-image: url(~@/assets/image/box_bg2.png);
+          background-repeat: no-repeat;
+          background-size: 100% 100%;
+          opacity: 0.4;
+        }
         .left-panel-content {
           width: 100%;
-          height: calc(100% - 90px);
+          height: calc(100% - 150px);
           overflow-x: hidden;
           overflow-y: auto;
           position: relative;
@@ -2240,16 +2226,6 @@ export default {
           }
         }
 
-        .logo {
-          font-family: REEJI-FlashSansN95;
-          font-weight: 900;
-          font-size: 28px;
-          color: #333333;
-          line-height: 36px;
-          margin-bottom: 31px;
-          height: 30px;
-        }
-
         .desc {
           font-family: Microsoft YaHei;
           font-weight: 400;
@@ -2257,94 +2233,6 @@ export default {
           color: #333333;
         }
 
-        .hint {
-          font-family: Microsoft YaHei;
-          font-weight: 400;
-          font-size: 16px;
-          color: #2879e7;
-          margin-bottom: 30px;
-          margin-top: 40px;
-        }
-
-        .hot-question-item {
-          display: flex;
-          margin-bottom: 20px;
-
-          img {
-            width: 32px;
-            height: 32px;
-            margin-right: 11px;
-          }
-
-          .right-nr {
-            width: calc(100% - 43px);
-            cursor: pointer;
-            padding: 17px 32px 16px 20px;
-            background: linear-gradient(90deg, #c7dcf8, #e8eafd);
-            border-radius: 10px;
-            font-family: PingFang SC;
-            font-weight: 500;
-            font-size: 14px;
-            color: #333333;
-          }
-
-          .right-nr:hover {
-            border: 1px solid #2879e7;
-          }
-        }
-
-        .diver44 {
-          height: 44px;
-        }
-
-        .m-textarea-panel {
-          width: 100%;
-          height: 105px;
-          background: #ffffff;
-          border-radius: 10px;
-          position: relative;
-          padding: 17px 0px 0px 19px;
-
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 60px);
-            font-weight: normal;
-            font-size: 16px;
-            height: 100%;
-
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-weight: 400;
-              font-size: 14px;
-              color: #999999;
-            }
-          }
-
-          .btn {
-            width: 40px;
-            height: 40px;
-            position: absolute;
-            right: 17px;
-            cursor: pointer;
-            bottom: 14px;
-            display: flex;
-            align-items: center;
-            justify-content: center;
-            background: linear-gradient(90deg, #5c62ea, #517de2);
-            border-radius: 20px;
-
-            img {
-              width: 20px;
-              height: 20px;
-            }
-          }
-        }
-
         .back-icon {
           position: absolute;
           top: 26px;
@@ -2365,6 +2253,7 @@ export default {
           cursor: pointer;
           line-height: 36px;
           margin-bottom: 36px;
+          padding-right: 50px;
         }
         .jsz {
           margin: 0 0px 17px 0px;
@@ -2430,42 +2319,6 @@ export default {
           }
         }
 
-        .tab-panel {
-          padding-left: 3px;
-          display: flex;
-
-          .item {
-            display: flex;
-            margin-right: 48px;
-            cursor: pointer;
-            flex-direction: column;
-
-            .name {
-              width: 120px;
-              height: 20px;
-              font-family: Microsoft YaHei;
-              font-weight: 400;
-              font-size: 20px;
-              color: #465d7c;
-              line-height: 36px;
-            }
-
-            .selected {
-              font-weight: bold;
-              color: #333333;
-            }
-
-            .line {
-              margin-top: 20px;
-              width: 116px;
-              height: 6px;
-              background: url("~@/assets/image/cyyd/tab-select.png") no-repeat
-                center;
-              background-size: 100% 100%;
-            }
-          }
-        }
-
         .summary-content {
           display: flex;
 
@@ -2591,56 +2444,6 @@ export default {
           }
         }
 
-        .textarea-panel {
-          margin: 28px 3px 0px 3px;
-          width: 424px;
-          height: 90px;
-          background: #ffffff;
-          position: absolute;
-          bottom: 26px;
-          padding: 18px 0px 0px 19px;
-          box-shadow: 0px 6px 12px 1px rgba(11, 53, 103, 0.08);
-          border-radius: 16px 16px 16px 16px;
-          border: 1px solid #e5e6ea;
-
-          textarea {
-            border: none;
-            resize: none;
-            width: calc(100% - 60px);
-            font-weight: normal;
-            font-size: 18px;
-
-            &:focus-visible {
-              outline: none;
-            }
-
-            &::placeholder {
-              font-family: Microsoft YaHei;
-              font-size: 20px;
-              color: #a7aeb4;
-            }
-          }
-
-          .btn {
-            width: 40px;
-            height: 40px;
-            position: absolute;
-            right: 17px;
-            cursor: pointer;
-            bottom: 14px;
-            display: flex;
-            align-items: center;
-            justify-content: center;
-            background: linear-gradient(124deg, #505dff 0%, #418cff 100%);
-            border-radius: 10px 10px 10px 10px;
-
-            img {
-              width: 20px;
-              height: 20px;
-            }
-          }
-        }
-
         .xg-title {
           height: 20px;
           margin-top: 28px;

+ 2 - 2
web_ui/static/config.js

@@ -1,9 +1,9 @@
 (function (window) {
   window.ApplicationConfig = {
     serverURL: "/server",
-    subscribeUrl: 'http://localhost:8511/subscribe/',
+    subscribeUrl: '/agentai/subscribe/',
     queryGeometryUrl: 'http://localhost:8511/queryGeometry',
-    kgQueryUrl: 'http://localhost:8511/kgQuery',
+    kgQueryUrl: '/agentai/kgQuery',
     klyzyQueryUrl: 'http://localhost:8511/klyzyQuery',
     queryGeometryListUrl: 'http://localhost:8511/queryGeometryList',
     yjjbntQueryUrl: 'http://localhost:8511/yjjbntQuery',