Sfoglia il codice sorgente

修改可预测文件

chenbaoxin 4 mesi fa
parent
commit
09952d6324

+ 1 - 1
src/style.css

@@ -280,7 +280,7 @@ body {
   line-height: 30px;
 }
 .el-popper.is-light {
-  background: rgba(0, 122, 255, 0.3);
+  background: rgba(2, 22, 43, 0.95);
 
     border: 1px solid transparent;
 }

+ 10 - 1
src/views/HealthStatusAnalysis/index.vue

@@ -557,7 +557,14 @@ const invertObjectKeysAndValues = (
 };
 const inverParams = invertObjectKeysAndValues(COLUMN_MAP);
 // 设置默认5个数值
-checkedParams.value = Object.values(COLUMN_MAP).slice(0, 5);
+// checkedParams.value = Object.values(COLUMN_MAP).slice(0, 5);
+let cachecheckedParams= localStorage.getItem('OE_checked_params')
+if(cachecheckedParams){
+checkedParams.value=JSON.parse(cachecheckedParams)
+}
+else {
+checkedParams.value = Object.values(COLUMN_MAP).slice(0,5);
+}
 /**
  * @param dataAll 全部数据,获取数据中的time
  * @param selectData 折线图数据,符合格式返回
@@ -646,6 +653,7 @@ watch(
 const setParams = ref(convertObjectToArray(COLUMN_MAP));
 
 const changeAttr = (val: string[]) => {
+
   if (val.length > 5) {
     ElMessage({
       message: `最多选择5个参数`,
@@ -654,6 +662,7 @@ const changeAttr = (val: string[]) => {
     checkedParams.value = checkedParams.value.slice(0, 5);
     console.log(checkedParams.value);
   }
+  localStorage.setItem('OE_checked_params', JSON.stringify(checkedParams.value))
 };
 // 健康状态评估结果(模态框)
 const showWarningModal = ref(false);

+ 2 - 1
src/views/OperationalReliabilityPrediction/index.vue

@@ -117,6 +117,7 @@
         </div>
         <div class="buttons">
           <button
+            
             class="btn btn-big"
             @click="goAdvice(currentBtn.name, currentBtn.name)"
           >
@@ -161,7 +162,7 @@ const getAllDomElements = async () => {
     ...serviceDataRef.value,
     image:imgBase64.split(',')[1]
    }
-     downloadFile(downloadStrategy(), "预测结果.docx", { ...serviceDataRef.value });
+     downloadFile(downloadStrategy(), "预测结果.docx", { fileName:fileName.value,...serviceDataRef.value });
 
   //  downloadStrategy({...serviceDataRef.value}).then((res:any)=>{
   //   debugger