{"action":"created","issue":{"url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/1016","labels_url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/1016/labels{/name}","comments_url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/1016/comments","events_url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/1016/events","html_url":"https://github.com/tombatossals/angular-leaflet-directive/issues/1016","id":115338985,"number":1016,"title":"Compile Popup Msg ng-click w/ Controller As syntax","user":{"login":"dkromp","id":12497334,"avatar_url":"https://avatars.githubusercontent.com/u/12497334?v=3","gravatar_id":"","url":"https://api.github.com/users/dkromp","html_url":"https://github.com/dkromp","followers_url":"https://api.github.com/users/dkromp/followers","following_url":"https://api.github.com/users/dkromp/following{/other_user}","gists_url":"https://api.github.com/users/dkromp/gists{/gist_id}","starred_url":"https://api.github.com/users/dkromp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkromp/subscriptions","organizations_url":"https://api.github.com/users/dkromp/orgs","repos_url":"https://api.github.com/users/dkromp/repos","events_url":"https://api.github.com/users/dkromp/events{/privacy}","received_events_url":"https://api.github.com/users/dkromp/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-11-05T17:56:19Z","updated_at":"2015-11-06T14:28:34Z","closed_at":"2015-11-06T13:02:08Z","body":"I am using Controller As syntax and am trying to get the popup to compile my html message using the settings below. Controller 'X' is known as dep in the html, and the alert function is defined in the controller as such.\r\n\r\n    vm.alert= function() {\r\n        alert('hi');\r\n     }\r\n\r\n    vm.mapMarkers.push({\r\n       lat : 40.703289,\r\n       lng : -74.014192,\r\n       message : \"<div ng-click=\\\"dep.alert()\\\">howdy</div>\",\r\n       compileMessage : true,\r\n       getMessageScope : function() { return vm; },\r\n       layer : 'vehicles'\r\n    })\r\n\r\nIt throws this error\r\nUncaught TypeError: c.$apply is not a function.\r\n\r\nI am using packages:\r\n\"angular\": \"^1.4.7\",\r\n\"angular-leaflet-directive\": \"^0.9.0\",\r\n\"leaflet\": \"^0.7.7\"\r\n\r\nAny ideas?"},"comment":{"url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/comments/154422206","html_url":"https://github.com/tombatossals/angular-leaflet-directive/issues/1016#issuecomment-154422206","issue_url":"https://api.github.com/repos/tombatossals/angular-leaflet-directive/issues/1016","id":154422206,"user":{"login":"dkromp","id":12497334,"avatar_url":"https://avatars.githubusercontent.com/u/12497334?v=3","gravatar_id":"","url":"https://api.github.com/users/dkromp","html_url":"https://github.com/dkromp","followers_url":"https://api.github.com/users/dkromp/followers","following_url":"https://api.github.com/users/dkromp/following{/other_user}","gists_url":"https://api.github.com/users/dkromp/gists{/gist_id}","starred_url":"https://api.github.com/users/dkromp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkromp/subscriptions","organizations_url":"https://api.github.com/users/dkromp/orgs","repos_url":"https://api.github.com/users/dkromp/repos","events_url":"https://api.github.com/users/dkromp/events{/privacy}","received_events_url":"https://api.github.com/users/dkromp/received_events","type":"User","site_admin":false},"created_at":"2015-11-06T14:28:34Z","updated_at":"2015-11-06T14:28:34Z","body":"The example jsfiddle isn't showing any markers."}}