Bläddra i källkod

图表分析分析栏位显示不及时问题

zhuliu 1 år sedan
förälder
incheckning
18e6907be4
1 ändrade filer med 4 tillägg och 4 borttagningar
  1. 4 4
      src/views/analyse/custom/index.vue

+ 4 - 4
src/views/analyse/custom/index.vue

@@ -118,13 +118,13 @@ export default {
     }
   },
   created() {},
-  mounted() {
-    this.getPatentNum()
+  async mounted() {
+    await this.getPatentNum()
     this.getData()
     window.addEventListener('resize',this.refreshChart)
   },
   methods: {
-    getPatentNum(){
+    async getPatentNum(){
       if(!this.searchPatentNum){
         this.patentNum = this.patentNums
         return
@@ -132,7 +132,7 @@ export default {
       let params1 = {
         projectId: this.projectId,
       }
-      this.$api.getAllCountColumns(params1).then(res => {
+      await this.$api.getAllCountColumns(params1).then(res => {
         if (res.code == 200) {
           var data = []
           res.data.data.forEach(item => {