- 饿百与京东拉门店数据基本OK
This commit is contained in:
26
business/jxutils/ditu/ditu_test.go
Normal file
26
business/jxutils/ditu/ditu_test.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package ditu
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/globals/testinit"
|
||||
)
|
||||
|
||||
func init() {
|
||||
testinit.Init()
|
||||
}
|
||||
|
||||
func TestGetCityCoordinateLists(t *testing.T) {
|
||||
coords := GetCityCoordinateList(110100, 5*1000, 2*1000)
|
||||
// coords := GetDistrictCoordinateLists(510105, 10*1000, 2*1000)
|
||||
t.Log(len(coords))
|
||||
// t.Log(utils.Format4Output(coords, false))
|
||||
var list []map[string]interface{}
|
||||
for _, v := range coords {
|
||||
list = append(list, map[string]interface{}{
|
||||
"position": []float64{v.Lng, v.Lat},
|
||||
})
|
||||
}
|
||||
t.Log(utils.Format4Output(list, true))
|
||||
}
|
||||
Reference in New Issue
Block a user