不需要后台运行一直获取位置
// 若不设置,默认为NO。不会后台进行定位。
[manager._locationManager setAllowsBackgroundLocationUpdates:YES];//didi 等需要 只需要一次定位设为NO
plist不需要加
<key>UIBackgroundModes</key>
<array>
<string>location</string>
<string>remote-notification</string>
</array>