Closed neyaoz closed 3 years ago
Thanks,
I will have a look at this and test it out :)
@davidpiesse Can you try to merge this? I've been having this issue for a while.
@davidpiesse Thanks a lot for for the quick merge! Maybe it was too quick.
The error is gone, but the field is now blank like this:
My code:
Map::make('Current Location', function () {
$location = $this->resource->getPosition();
if ($location) {
return new Point($location['lat'], $location['lng']);
}
return null;
})
->hideFromIndex()
->hideWhenCreating()
->spatialType('Point'),
It's not returning null. That if clause is just to avoid errors just after creation before the coordinates are set.
Are there any errors in the console? It may be that the compile/ build has not been successful.
@davidpiesse No, no other errors. I also tried rebuilding the assets in a fork, but that didn't help. https://github.com/heap-carsharing/nova-map
@davidpiesse If you have problems reproducing this, please tell me where I should look or what additional information you think you would need.
My Dev env is kicking up a shit storm (npm and yarn). I have not yet been able to rebuild it on the current master.. Have you tried using your fork and seeing if it works still?
Upgrade npm packages. by the way, vue2-leaflet is already 1 year old. [v2.0.0(https://github.com/vue-leaflet/Vue2Leaflet/releases/tag/v2.0.0)
Add peer dependencies as dependencies. https://github.com/vue-leaflet/Vue2Leaflet#leaflet-is-not-automatically-installed-anymore
Fixes
fitBounds() - Error: Bounds are not valid
error when another Nova tool uses vue2-leaflet v2.