Browse Source

fix:组织修改,地图不好用的问题2

feature
wxz 2 years ago
parent
commit
a8bd1c2c00
  1. 12
      src/views/modules/base/organization/organization.vue

12
src/views/modules/base/organization/organization.vue

@ -2568,7 +2568,10 @@ export default {
//
map.on("dragend", (e) => {
handleMoveCenter(e, this);
handleMoveCenter(e, (lng, lat) => {
this.longitude = lng;
this.latitude = lat;
});
});
// map.setCenter(latitude, longitude);
@ -2592,16 +2595,15 @@ export default {
// ]);
// }
function handleMoveCenter (e, env) {
function handleMoveCenter (e, callback) {
//
const { lat, lng } = map.getCenter();
// const lat = lat;
// const lng = lng;
map.setMarker(lat, lng);
// thisthisenv
env.latitude = lat;
env.longitude = lng;
// this
callback(lng, lat)
// let { msg, data } = await map.getAddress(lat, lng);
// if (msg == "success") {

Loading…
Cancel
Save