Skip to content

when lat and lng, map still show by address #2

@mihail201

Description

@mihail201

change:
initYandexMaps(res.geoObjects.get(0).geometry.getCoordinates());
to:
{% load l10n %}
{% if object.lat and object.lng %}
initYandexMaps([{{ object.lat|unlocalize }}, {{ object.lng|unlocalize }}]);
{% else %}
initYandexMaps(res.geoObjects.get(0).geometry.getCoordinates());
{% endif %}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions