Browse Source

fix: 火灾分布排序

TwoKe945 1 year ago
parent
commit
9c65b60c76
1 changed files with 4 additions and 3 deletions
  1. 4 3
      app/src/views/FireCondition/components/FireDistribution.vue

+ 4 - 3
app/src/views/FireCondition/components/FireDistribution.vue

@@ -92,7 +92,9 @@ export default {
   methods: {
     changeHandler(idx) {
       this.idx = idx;
-      this.list = toFirst(this.sortData(this.list), this.qx, "qx");
+      const temp = JSON.parse(JSON.stringify(this.list))
+      this.list = []
+      this.list = toFirst(this.sortData(temp), this.qx, "qx");
     },
     getPercent(bn, tq) {
       if (bn - tq === 0) {
@@ -155,7 +157,6 @@ export default {
       if (this.idx == 0) {
         return tempData.sort((a, b) => b.bnhzqs - a.bnhzqs);
       }
-     
       if (this.idx == 1) {
         return tempData.sort((a, b) => b.bnwrs - a.bnwrs);
       }
@@ -163,7 +164,7 @@ export default {
     loadData() {
       this.reload = false;
       fireDistribution({
-        pageSize: 100,
+        pageSize: 41,
         pageNum: 1,
       }).then((res) => {
         let tempData = res.data.rows.map((item) => ({