diff --git a/components/diy_store_select/diy_store_select.js b/components/diy_store_select/diy_store_select.js
index fdc6784..c83e633 100644
--- a/components/diy_store_select/diy_store_select.js
+++ b/components/diy_store_select/diy_store_select.js
@@ -44,10 +44,6 @@ Component({
//获取顶部的门店
getApp().get_user_store(function(){
- var top_store=getApp().globalData.pk_store;
- if(top_store){
- th.setData({top_store:top_store});
- }else{
wx.getLocation({
type: 'gcj02',
success: function(res) {
@@ -61,9 +57,12 @@ Component({
}
}
})
- }
+
})
},
+
+
+
//-- 设置最近的店为默认的店,一开始加载的时候 --
set_fir_store_to_def(){
var th=this;
@@ -74,7 +73,13 @@ Component({
page:1,
};
dd.lat = th.data.lat;
- dd.lon = th.data.lon;
+ dd.lon = th.data.lon;
+
+ var top_store=getApp().globalData.pk_store;
+ if(top_store){
+ dd.pickup_id=top_store.pickup_id;
+ }
+
//----------获取门店,最近的门店----------------
getApp().request.promiseGet("/api/weshop/pickup/list", {
data: dd,
@@ -173,8 +178,7 @@ Component({
this.deal_pickup(this.data.all_pick_list,func)
return false;
}
- var th = this,that=this;
- var i = getApp().request;
+ var th = this,that=this;
var dd = {
store_id: o.stoid,
isstop: 0,
diff --git a/components/diy_store_select/diy_store_select.wxml b/components/diy_store_select/diy_store_select.wxml
index 8db133f..b56406c 100644
--- a/components/diy_store_select/diy_store_select.wxml
+++ b/components/diy_store_select/diy_store_select.wxml
@@ -1,3 +1,5 @@
+
+
@@ -51,7 +53,7 @@
- 距离:{{item.distance>1000?filters.toFix(item.distance/1000,2)+'km':filters.toFix(item.distance,0)+"m"}}
+ 距离: {{item.distance>1000?filters.toFix(item.distance/1000,2)+'km':filters.toFix(item.distance,0)+"m"}}
地址:{{item.fulladdress}}