diff --git a/store/index.js b/store/index.js index 809f0d0..54c41fe 100644 --- a/store/index.js +++ b/store/index.js @@ -156,11 +156,11 @@ const store = new Vuex.Store({ //异步修改 actions: { //获取订单列表 - fetchOrderList({ + async fetchOrderList({ state, commit }) { - uni.$u.http.get('/Api/Check/getOrderList', { + await uni.$u.http.get('/Api/Check/getOrderList', { header:{ 'Token': state.userInfo.token, } @@ -174,11 +174,11 @@ const store = new Vuex.Store({ }) }, //获取站点列表 - fetchSiteList({ + async fetchSiteList({ state, commit }) { - uni.$u.http.get('/Api/Normal/getSiteList', { + await uni.$u.http.get('/Api/Normal/getSiteList', { params: { shop_id: state.shop_id } @@ -199,11 +199,11 @@ const store = new Vuex.Store({ }) }, //获取分类列表 - fetchMenuList({ + async fetchMenuList({ state, commit }) { - uni.$u.http.get('/Api/Normal/getCategoryList', { + await uni.$u.http.get('/Api/Normal/getCategoryList', { params: { shop_id: state.shop_id } @@ -294,11 +294,11 @@ const store = new Vuex.Store({ }) }, //获取商品信息 - fetchShopCon({ + async fetchShopCon({ state, commit }) { - uni.$u.http.get('/Api/Normal/getShopCon', { + await uni.$u.http.get('/Api/Normal/getShopCon', { params: { shop_id: state.shop_id }