Downloads
Stars
Version
Laravel 百度 LBS云 SDK Service Provider
composer require hivenkay/easylbs
在app/config.php
中的 providers数组增加:
HivenKay\LaravelLbs\ServiceProvider::class,
在命令行执行php artisan vendor:publish
发布 lbs 配置文件
在app/easy_lbs.php
中配置百度云的ak和 sk
EasyLbs::XXX()
GeoTable::XXX()
...
* create
* getList
* update
* detail
* delete
$geoTable = new GeoTable('your-ak','your-sk');
$geoColumn = new GeoColumn('your-ak','your-sk');
$geoPoi = new GeoPoi('your-ak','your-sk');
$geoSearch = new GeoSearch('your-ak','your-sk');
//$attributes 请参考百度云文档
$geoSearch->searchOfNearBy($attributes);
$geoSearch = new GeoSearch('your-ak','your-sk');
//$attributes 请参考百度云文档
$geoSearch->searchOfLocal($attributes);
$geoSearch = new GeoSearch('your-ak','your-sk');
//$attributes 请参考百度云文档
$geoSearch->searchOfDetail($attributes);