diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index e9c4183ae..31d9d52f3 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -184,7 +184,8 @@ func GetStores(ctx *jxcontext.Context, keyword string, params map[string]interfa WHEN 3 THEN IF(eb.col_name IS NULL, '', eb.col_name) ELSE '' END, - '", "isSync":', m1.is_sync, '}')), ']') store_map_str, + '", "isSync":', m1.is_sync, + ', "fakeOpenStart":"', IF(m1.fake_open_start IS NULL, "1970-01-01 00:00:00", m1.fake_open_start), '", "fakeOpenStop":"', IF(m1.fake_open_stop IS NULL, "1970-01-01 00:00:00", m1.fake_open_stop), '"}')), ']') store_map_str, CONCAT('[', GROUP_CONCAT(DISTINCT CONCAT('{"vendorStoreID":"', m2.vendor_store_id, '", "vendorID":', m2.vendor_id, ', "status":', m2.status, '}')), ']') courier_map_str FROM store t1 @@ -364,6 +365,7 @@ func GetStores(ctx *jxcontext.Context, keyword string, params map[string]interfa mapRadius = params["mapRadius"].(int) } for _, v := range storeList { + globals.SugarLogger.Debug(v.StoreMapStr) valid := !mapLimit if mapLimit { valid = jxutils.EarthDistance(mapLongitude, mapLatitude, v.FloatLng, v.FloatLat)*1000 <= float64(mapRadius) diff --git a/business/model/store.go b/business/model/store.go index ab85c8ffc..469a6e3a3 100644 --- a/business/model/store.go +++ b/business/model/store.go @@ -366,8 +366,10 @@ type StoreMap struct { DeliveryFee int `json:"deliveryFee"` DeliveryCompetition int8 `orm:"default(1)" json:"deliveryCompetition"` // 是否支持配送竞争 - SyncStatus int8 `orm:"default(2)" json:"syncStatus"` - IsSync int8 `orm:"default(1)" json:"isSync"` // 是否同步 + SyncStatus int8 `orm:"default(2)" json:"syncStatus"` + IsSync int8 `orm:"default(1)" json:"isSync"` // 是否同步 + FakeOpenStart time.Time `orm:"null" json:"fakeOpenStart"` // 假开店开始 + FakeOpenStop time.Time `orm:"null" json:"fakeOpenStop"` // 假开店结束 } func (*StoreMap) TableUnique() [][]string {