seimin hace 2 años
padre
commit
14931b4ebe
Se han modificado 1 ficheros con 10 adiciones y 7 borrados
  1. 10 7
      src/views/ConsumableList.vue

+ 10 - 7
src/views/ConsumableList.vue

@@ -306,6 +306,7 @@ export default {
306 306
       if (this.searching) {
307 307
         this.idx = 0;
308 308
       }
309
+      let title = this.title;
309 310
       let postData = {
310 311
         idx: this.idx,
311 312
         sum: this.sum,
@@ -320,15 +321,17 @@ export default {
320 321
         )
321 322
         .then((res) => {
322 323
           if(res.status == 200){
323
-            if (res.data.list.length > 0) {
324
-              this.wushuju = false;
325
-              if (this.searching) {
326
-                this.items = res.data.list;
324
+            if(title == this.title){
325
+              if (res.data.list.length > 0) {
326
+                this.wushuju = false;
327
+                if (this.searching) {
328
+                  this.items = res.data.list;
329
+                } else {
330
+                  this.items = this.items.concat(res.data.list);
331
+                }
327 332
               } else {
328
-                this.items = this.items.concat(res.data.list);
333
+                this.wushuju = this.searching;
329 334
               }
330
-            } else {
331
-              this.wushuju = this.searching;
332 335
             }
333 336
           }else{
334 337
             this.$createDialog({