25 lines
730 B
JavaScript
25 lines
730 B
JavaScript
//index.js
|
|
//获取应用实例
|
|
const { $http, $utils } = getApp().globalData
|
|
|
|
Page({
|
|
data: {
|
|
swiperList: [
|
|
{ id: 1, url: 'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/aa34be7e8eda3b108ba6c62a7367868b.jpeg?thumb=1&w=720&h=360' },
|
|
{ id: 2, url: 'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/05f7665eadee22e00a50cb1e54943364.jpg?thumb=1&w=720&h=360' },
|
|
{ id: 3, url: 'https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/03ff022009a635262d53451d532518ed.jpg?thumb=1&w=720&h=360' }
|
|
]
|
|
},
|
|
//事件处理函数
|
|
bindViewTap: function() {
|
|
|
|
},
|
|
onLoad: async function () {
|
|
let res = await $http.HomeService.IndexType({});
|
|
console.log("数据请求:",res);
|
|
},
|
|
getUserInfo: function(e) {
|
|
|
|
}
|
|
})
|