|
|
@ -57,9 +57,7 @@ Page({ |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
fail: function() {}, |
|
|
|
fail: function() {}, |
|
|
|
complete: function() { |
|
|
|
complete: function() {} |
|
|
|
that.getProductsFromServer() |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
wx.getStorage({ |
|
|
|
wx.getStorage({ |
|
|
@ -68,12 +66,15 @@ Page({ |
|
|
|
that.setData({'slides': res.data}) |
|
|
|
that.setData({'slides': res.data}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
fail: function() {}, |
|
|
|
fail: function() {}, |
|
|
|
complete: function() { |
|
|
|
complete: function() {} |
|
|
|
that.getSlidesFromServer() |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onReady: function() { |
|
|
|
|
|
|
|
this.getProductsFromServer() |
|
|
|
|
|
|
|
this.getSlidesFromServer() |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
getSlidesFromServer: function() { |
|
|
|
getSlidesFromServer: function() { |
|
|
|
var that = this |
|
|
|
var that = this |
|
|
|
productUtil.getSlides(function(result) { |
|
|
|
productUtil.getSlides(function(result) { |
|
|
|