xiangpei
2025-06-05 1fa6ac40e2ce16e1174cec9ca538d45eeb660fdc
src/views/projectEngineering/projectLibrary/component/DocumentsInfo.vue
@@ -76,10 +76,26 @@
    if (this.$route.query.projectId && !parsedDocumentsInfoForm) {
      this.getDocumentsInfo();
    }
    this.documentsInfoForm.projectId = this.projectForm.id;
  },
  beforeDestroy() {
    if(Object.keys(this.documentsInfoForm).length !==0) localStorage.setItem("documentsInfoForm", JSON.stringify(this.documentsInfoForm));
  },
  watch: {
    documentsInfoForm:{
      deep: true,
      handler(newVal) {
        this.$emit('documentsInfoForm', newVal)
      }
    },
    fileList: {
      deep: true,
      handler(newVal) {
        this.documentsInfoForm.fileList = newVal
      }
    }
  }
};
</script>