Commit
c54581745c053e12f0269d85c18b16f7c5a94a56
Authored by
yvan.ni
秒杀,拼团清理定时器
| @@ -47,7 +47,12 @@ Component({ |
| @@ -47,7 +47,12 @@ Component({ |
47
| th.countDown2(th); |
47
| th.countDown2(th); |
48
| }, 1000); |
48
| }, 1000); |
49
| } |
49
| } |
50
| - } |
50
| + }, |
| |
51
| + |
| |
52
| + hide:function () { |
| |
53
| + // 页面被被销毁的时候,清除定时器 |
| |
54
| + clearInterval(this.data.timer); |
| |
55
| + } |
51
| }, |
56
| }, |
52
| |
57
| |
53
| |
58
| |
| @@ -51,6 +51,11 @@ Component({ |
| @@ -51,6 +51,11 @@ Component({ |
51
| }, 1000); |
51
| }, 1000); |
52
| } |
52
| } |
53
| },600) |
53
| },600) |
| |
54
| + }, |
| |
55
| + |
| |
56
| + hide:function () { |
| |
57
| + // 页面被被销毁的时候,清除定时器 |
| |
58
| + clearInterval(this.data.timer); |
54
| } |
59
| } |
55
| }, |
60
| }, |
56
| |
61
| |