瀏覽代碼

fix: 抢单后没刷新页面

seimin 1 年之前
父節點
當前提交
d7bb4384be
共有 2 個文件被更改,包括 10 次插入4 次删除
  1. 5 2
      src/views/IncidentNewList.vue
  2. 5 2
      src/views/incidentList.vue

+ 5 - 2
src/views/IncidentNewList.vue

@@ -420,7 +420,7 @@ export default {
420
             "service/bpm/bpm/claimAndCompletedTask/" + incident.taskId,
420
             "service/bpm/bpm/claimAndCompletedTask/" + incident.taskId,
421
             { receive_code: "handler", userId: that.loginUser.id }
421
             { receive_code: "handler", userId: that.loginUser.id }
422
           )
422
           )
423
-          .then(function (res) {
423
+          .then((res) => {
424
             console.log(res.data);
424
             console.log(res.data);
425
             if (res.data.status == 200) {
425
             if (res.data.status == 200) {
426
               that
426
               that
@@ -430,7 +430,10 @@ export default {
430
                   content: "点击返回首页",
430
                   content: "点击返回首页",
431
                   icon: "cubeic-right",
431
                   icon: "cubeic-right",
432
                   onConfirm: (e, promptValue) => {
432
                   onConfirm: (e, promptValue) => {
433
-                    that.$router.push({ path: "/main" });
433
+                    this.loadShow = true;
434
+                    this.items = [];
435
+                    this.idx = 0;
436
+                    this.getData();
434
                   },
437
                   },
435
                 })
438
                 })
436
                 .show();
439
                 .show();

+ 5 - 2
src/views/incidentList.vue

@@ -354,7 +354,7 @@ export default {
354
             "service/bpm/bpm/claimAndCompletedTask/" + incident.taskId,
354
             "service/bpm/bpm/claimAndCompletedTask/" + incident.taskId,
355
             { receive_code: "handler", userId: that.loginUser.id }
355
             { receive_code: "handler", userId: that.loginUser.id }
356
           )
356
           )
357
-          .then(function (res) {
357
+          .then((res) => {
358
             console.log(res.data);
358
             console.log(res.data);
359
             if (res.data.status == 200) {
359
             if (res.data.status == 200) {
360
               that
360
               that
@@ -364,7 +364,10 @@ export default {
364
                   content: "点击返回首页",
364
                   content: "点击返回首页",
365
                   icon: "cubeic-right",
365
                   icon: "cubeic-right",
366
                   onConfirm: (e, promptValue) => {
366
                   onConfirm: (e, promptValue) => {
367
-                    that.$router.push({ path: "/main" });
367
+                    this.loadShow = true;
368
+                    this.items = [];
369
+                    this.idx = 0;
370
+                    this.getData();
368
                   },
371
                   },
369
                 })
372
                 })
370
                 .show();
373
                 .show();