lsc пре 2 месеци
родитељ
комит
b4a2218cdf
1 измењених фајлова са 34 додато и 1 уклоњено
  1. 34 1
      src/components/pages/knowledge/folderFileBox.vue

+ 34 - 1
src/components/pages/knowledge/folderFileBox.vue

@@ -32,7 +32,12 @@
           />
           <div class="serch"></div>
         </div>
-
+        <!-- <el-button type="primary" size="small" @click="resetGraphs">
+          重置文件夹
+        </el-button>
+        <el-button type="primary" size="small" @click="getGraph">
+          获取文件夹图谱
+        </el-button> -->
         <el-button type="primary" size="small" @click="serchFile">
           <img
             style="
@@ -575,6 +580,34 @@ export default {
     },
   },
   methods: {
+    getGraph(){
+      let params = {
+        collectionId: this.folderid
+      };
+
+      this.ajax
+        .post(this.$store.state.fileApi + "getRelationshipsGraphs", [params])
+        .then(res => {
+          console.log('getRelationshipsGraphs',res);
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    resetGraphs(){
+      let params = {
+        collectionId: this.folderid
+      };
+
+      this.ajax
+        .post(this.$store.state.fileApi + "resetGraphs", [params])
+        .then(res => {
+          console.log('resetGraphs',res);
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
     goBackPage() {
       this.$emit("goCheckType", this.pid.split("/")[0]);
     },