Skip to content
This repository was archived by the owner on May 11, 2020. It is now read-only.
This repository was archived by the owner on May 11, 2020. It is now read-only.

Custom marker ng-repeat not updating when changes made to model  #333

@harryj

Description

@harryj

So I'm using custom marker in ng-repeat like so:

<map zoom="11" center="[41.8369, -87.6847]" id="map-view-map">
    <custom-marker ng-repeat="clip in clips | filter:{clip_type:3}" position="[{{clip.lat}},{{clip.lng}}]" on-mouseover="markerMouseOver(clip)" on-mouseout="markerMouseOut(clip)">
        <div class='clip-marker'>{{clip.name}}</div>
    </custom-marker>
  </map>

I want to change something in the custom marker on mouseover/mouseout so to test I have something like this in my controller:

$scope.markerMouseOver = function(clip){

   clip.name = "NEWNAME";
};

But the markers don't update. I've tried other changes (such as modifying the lat/lng) and the markers/map don't automatically update. I know this functionality exists for regular markers (testapp example marker_dynamic_ng_repeat.html but it doesn't seem to be working for custom-markers? Or am is it supposed to and I'm just doing something wrong?

Thanks so much for building this by the way, it's super awesome!

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