Эх сурвалжийг харах

feat: 搜索折叠以及自测

sunxiao 9 сар өмнө
parent
commit
71cf50a86c

+ 3 - 3
src/api/business/record.js

@@ -20,7 +20,7 @@ export function getRecord(id) {
 // 新增信义大模型问答记录
 export function addRecord(data) {
   return request({
-    url: '/business/record',
+    url: '/business/chatRecord',
     method: 'post',
     data: data
   })
@@ -29,7 +29,7 @@ export function addRecord(data) {
 // 修改信义大模型问答记录
 export function updateRecord(data) {
   return request({
-    url: '/business/record',
+    url: '/business/chatRecord',
     method: 'put',
     data: data
   })
@@ -38,7 +38,7 @@ export function updateRecord(data) {
 // 删除信义大模型问答记录
 export function delRecord(id) {
   return request({
-    url: '/business/record/' + id,
+    url: '/business/chatRecord/' + id,
     method: 'delete'
   })
 }

+ 3 - 2
src/views/business/assistant/index.vue

@@ -63,7 +63,7 @@
             @click="handleExport"
           >导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
 
       <el-table v-loading="loading" :data="assistantList" @selection-change="handleSelectionChange">
@@ -133,7 +133,7 @@
           <el-input
             v-model="form.content"
             :rows="4"
-            resize="none" 
+            resize="none"
             type="textarea"
             placeholder="提示词内容"
           />
@@ -141,6 +141,7 @@
         <el-form-item label="icon地址" prop="banner">
           <el-upload
             class="avatar-uploader"
+            accept="image/gif,image/jpeg,image/jpg,image/bmp,image/png"
             :headers="headers"
             :action="path"
             :show-file-list="false"

+ 0 - 18
src/views/business/comparison/index.vue

@@ -63,24 +63,6 @@
         <el-table-column label="TFT预测3小时误差" align="center" prop="hsErrorRateThreeStr" width="120"/>
         <el-table-column label="LSTM预测3小时值" align="center" prop="yyForecastThree" width="120"/>
         <el-table-column label="LSTM预测3小时误差" align="center" prop="yyErrorRateThreeStr" width="120"/>
-        <!-- <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="160">
-          <template #default="scope">
-            <el-button
-              size="small"
-              text
-              icon="edit"
-              @click="handleUpdate(scope.row)"
-              v-hasPermi="['business:comparison:edit']"
-            >修改</el-button>
-            <el-button
-              size="small"
-              text
-              icon="delete"
-              @click="handleDelete(scope.row)"
-              v-hasPermi="['business:comparison:remove']"
-            >删除</el-button>
-          </template>
-        </el-table-column> -->
       </el-table>
   
       <pagination

+ 1 - 1
src/views/business/feedback/index.vue

@@ -62,7 +62,7 @@
           @click="handleExport"
         >导出</el-button>
       </el-col>
-      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+      <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
 
     <el-table v-loading="loading" :data="feedbackList" @selection-change="handleSelectionChange">

+ 3 - 3
src/views/business/forecast/index.vue

@@ -44,7 +44,7 @@
         <el-col :span="1.5">
           <el-button type="warning" plain icon="download" size="small" @click="handleExport">导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
       <el-table v-loading="loading" :data="recordList" @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55" align="center" />
@@ -221,11 +221,11 @@
 </template>
 
 <script>
-import { listWarn, getWarn } from "@/api/business/water";
+import { listWarn, getWarn, delRecord } from "@/api/business/water";
 import { formatToData, replaceArray  } from "@/utils/format";
 import * as echarts from 'echarts';
 import { getAreaOptions } from "@/utils/echartOptions";
-import { listRecord, getRecord, delRecord, addRecord, updateRecord } from "@/api/business/record";
+import { getRecord, addRecord, updateRecord } from "@/api/business/record";
 import { ChatAsk, ChatAnswer, ChatBaseCard } from "@/components/chat"
 export default {
   name: "Record",

+ 1 - 1
src/views/business/order/index.vue

@@ -31,7 +31,7 @@
         <el-col :span="1.5">
           <el-button type="warning" plain icon="download" size="small" @click="handleExport">导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
       <el-table v-loading="loading" :data="recordList" @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55" align="center" />

+ 3 - 3
src/views/business/pymol/index.vue

@@ -55,7 +55,7 @@
         <el-col :span="1.5">
           <el-button type="warning" plain icon="download" size="small" @click="handleExport">导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
       <el-table v-loading="loading" :data="recordList" @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55" align="center" />
@@ -204,11 +204,11 @@
 </template>
 
 <script>
-import { listWarn, getWarn } from "@/api/business/water";
+import { listWarn, getWarn, delRecord } from "@/api/business/water";
 import { formatToData, replaceArray  } from "@/utils/format";
 import * as echarts from 'echarts';
 import { getAreaOptions } from "@/utils/echartOptions";
-import { listRecord, getRecord, delRecord, addRecord, updateRecord } from "@/api/business/record";
+import { listRecord, getRecord, addRecord, updateRecord } from "@/api/business/record";
 import { ChatAsk, ChatAnswer, ChatBaseCard } from "@/components/chat"
 export default {
   name: "Record",

+ 3 - 4
src/views/business/qa/index.vue

@@ -66,7 +66,7 @@
             @click="handleExport"
           >导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
 
       <el-table v-loading="loading" :data="qaList" @selection-change="handleSelectionChange">
@@ -129,7 +129,6 @@
       />
     </el-card>
     
-
     <!-- 添加或修改信义推荐问答列对话框 -->
     <el-dialog :title="title" v-model="open" width="900px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
@@ -282,7 +281,7 @@ export default {
     handleAdd() {
       this.reset();
       this.open = true;
-      this.title = "添加推荐问";
+      this.title = "添加推荐问";
     },
     /** 修改按钮操作 */
     handleUpdate(row) {
@@ -291,7 +290,7 @@ export default {
       getQa(id).then(response => {
         this.form = response.data;
         this.open = true;
-        this.title = "修改推荐问";
+        this.title = "修改推荐问";
       });
     },
     /** 提交按钮 */

+ 4 - 7
src/views/business/record/index.vue

@@ -6,9 +6,6 @@
       <el-form-item label="问题内容" prop="question">
         <el-input v-model="queryParams.question" placeholder="请输入问题内容" clearable @keyup.enter.native="handleQuery" />
       </el-form-item>
-      <!-- <el-form-item label="类型" prop="unknown">
-        <el-input v-model="queryParams.module" placeholder="请输入隶属哪个模块" clearable @keyup.enter.native="handleQuery" />
-      </el-form-item> -->
       <el-form-item>
         <el-button type="primary" icon="search" size="small" @click="handleQuery">搜索</el-button>
         <el-button icon="refresh" size="small" @click="resetQuery">重置</el-button>
@@ -31,7 +28,8 @@
         <el-col :span="1.5">
           <el-button type="warning" plain icon="download" size="small" @click="handleExport">导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
+        <!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
       </el-row>
       <el-table v-loading="loading" :data="recordList" @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55" align="center" />
@@ -43,11 +41,10 @@
           </template>
         </el-table-column>
         <el-table-column label="用户名" align="center" prop="userId" />
-        <el-table-column label="手机号" align="center" prop="phone" />
-        <!-- <el-table-column label="回答" align="center" prop="showVal" /> -->
+        <el-table-column label="手机号" align="center" prop="phonenumber" />
         <el-table-column label="问题内容" align="center" prop="question" width="500px">
           <template #default="scope">
-            <el-popover effect="light" trigger="hover" placement="top" width="600">
+           <el-popover effect="light" trigger="hover" placement="top" width="600">
               <template #default>
                 <div style="font-weight: bold;">问题:</div>
                 <div>{{ scope.row.question }}</div>

+ 10 - 21
src/views/business/water/index.vue

@@ -9,22 +9,11 @@
       <el-form-item label="报警类型" prop="category">
         <el-select v-model="queryParams.category">
           <el-option value="" label="全部"></el-option>
-          <el-option key="内回流比" value="内回流比" label="内回流比"></el-option>
-          <el-option key="外回流比" value="外回流比" label="外回流比"></el-option>
-          <el-option key="污泥浓度" value="污泥浓度" label="污泥浓度"></el-option>
-          <el-option key="污泥负荷" value="污泥负荷" label="污泥负荷"></el-option>
-          <el-option key="碳氮比" value="碳氮比" label="碳氮比"></el-option>
-          <el-option key="碳磷比" value="碳磷比" label="碳磷比"></el-option>
-          <el-option key="BOD比COD" value="BOD比COD" label="BOD比COD"></el-option>
-          <el-option key="好氧区DO#1" value="好氧区DO#1" label="好氧区DO#1"></el-option>
-          <el-option key="好氧区DO#2" value="好氧区DO#2" label="好氧区DO#2"></el-option>
-          <el-option key="气水比" value="气水比" label="气水比"></el-option>
-          <el-option key="污泥浓度MLSS#1" value="污泥浓度MLSS#1" label="污泥浓度MLSS#1"></el-option>
-          <el-option key="污泥浓度MLSS#2" value="污泥浓度MLSS#2" label="污泥浓度MLSS#2"></el-option>
-          <el-option key="挥发性污泥浓度占比(MLVSS/MLSS)" value="挥发性污泥浓度占比(MLVSS/MLSS)" label="挥发性污泥浓度占比(MLVSS/MLSS)"></el-option>
-          <el-option key="二沉池表面负荷" value="二沉池表面负荷" label="二沉池表面负荷"></el-option>
-          <el-option key="二沉池固体负荷" value="二沉池固体负荷" label="二沉池固体负荷"></el-option>
-          <el-option key="反冲洗水量" value="反冲洗水量" label="反冲洗水量"></el-option>
+          <el-option key="出水COD" value="出水COD" label="出水COD"></el-option>
+          <el-option key="出水SS" value="出水SS" label="出水SS"></el-option>
+          <el-option key="出水总氮" value="出水总氮" label="出水总氮"></el-option>
+          <el-option key="出水总磷" value="出水总磷" label="出水总磷"></el-option>
+          <el-option key="出水氨氮" value="出水氨氮" label="出水氨氮"></el-option>
         </el-select>
       </el-form-item>
       <!-- <el-form-item label="报警原因" prop="reason">
@@ -64,7 +53,7 @@
         <el-col :span="1.5">
           <el-button type="warning" plain icon="download" size="small" @click="handleExport">导出</el-button>
         </el-col>
-        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+        <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
       </el-row>
       <el-table v-loading="loading" :data="recordList" @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55" align="center" />
@@ -216,7 +205,8 @@
                   <p class="radio-btn-group space-x-[14px]">
                     <span v-for="option, index in val.options"
                       :class="['radio-btn', { active: val.isActive === index }]"
-                      @click="handlerAlertOptions(item, val, index)">{{ option }}</span>
+                    >{{ option }}</span>
+                    <!-- @click="358(item, val, index)" -->
                   </p>
                 </li>
               </ul>
@@ -270,9 +260,9 @@
 </template>
 
 <script>
-import { listWarn, getWarn } from "@/api/business/water";
+import { listWarn, getWarn, delRecord } from "@/api/business/water";
 import { formatToData } from "@/utils/format";
-import { listRecord, getRecord, delRecord, addRecord, updateRecord } from "@/api/business/record";
+import { getRecord, addRecord, updateRecord } from "@/api/business/record";
 import { ChatAsk, ChatAnswer, ChatBaseCard } from "@/components/chat"
 export default {
   name: "Record",
@@ -355,7 +345,6 @@ export default {
 
           answer.map(item => {
             const answerObjItem = JSON.parse(item);
-            console.log( answerObjItem );
             switch (answerObjItem.biz) {
               case "DECISION_REPORT":
                 reportList.push(answerObjItem.message);