Commit 0c80e5ee4b4ef1059dee3e741e510a9f094bfe15
1 parent
49bfbe15
要等到结果才显示
Showing
1 changed file
with
8 additions
and
6 deletions
pages/index/index/index.js
| @@ -1010,12 +1010,14 @@ Page({ | @@ -1010,12 +1010,14 @@ Page({ | ||
| 1010 | check_holiday_pop:function(){ | 1010 | check_holiday_pop:function(){ |
| 1011 | var th=this; | 1011 | var th=this; |
| 1012 | getApp().waitfor2(th,'w_holiday_pop','holiday_image',function(){ | 1012 | getApp().waitfor2(th,'w_holiday_pop','holiday_image',function(){ |
| 1013 | - console.log(th.data.holiday_image); | ||
| 1014 | - th.setData({ | ||
| 1015 | - new_image: th.data.holiday_image, | ||
| 1016 | - new_nav: th.data.holiday_url, | ||
| 1017 | - is_disgraceful: 1 | ||
| 1018 | - }) | 1013 | + //等到结果才显示 |
| 1014 | + if(th.data.holiday_image){ | ||
| 1015 | + th.setData({ | ||
| 1016 | + new_image: th.data.holiday_image, | ||
| 1017 | + new_nav: th.data.holiday_url, | ||
| 1018 | + is_disgraceful: 1 | ||
| 1019 | + }) | ||
| 1020 | + } | ||
| 1019 | }) | 1021 | }) |
| 1020 | }, | 1022 | }, |
| 1021 | 1023 |