Angularjs Directive not loading PopOver content -


I'm trying to develop a Facebook like notification (such as when an icon receives requests, Item number in the item which is the number of notifications app.directive ('popOver', function ($ COLLECTION) {var itemsTemplate = " & lt; div ng-repeat = 'item '& Gt; {{items}}


"var getTemplate = function (contentType) {var template ='; ',' A ', transclusions true, templates: " "; return {contentType} {case:' item ': template = item; ("Scope"), link: function (scope, element, etter) {var popOverContent = "
", if (scope.itm) {var html = getTemplate ("item "); popOverContent = $ compile html} (scope);} var option = {content: pop oversantant, placement:" bottom ", html: true, title: scopetytile}; $ (element) .popover (options);} Ope: {items: '=', Title: '@'}};

});

The items are settled in the controller, and there I am using $ timeout to fetch new data from the database and fill the scope.

In the UI, I have a button that shows the number of new notifications and on the click I want to show popup with the item The problem is that when the button is clicked, Popovar does not load new items Used to be.

  & lt; Button pop-over item = "item" class = "navbar-btn btn-info round-button" title = "notifications:" & gt; {{NewAlertCount}} & lt; / Button & gt; The director has his own scope, so I believe that when you change the    

$ Scope .items In your controller you are talking about a different area; I think that whatever you want is to look directly at the original $ scope.items object, so I will add it:
  scope: {items: '= Items'},   

for your instructions.

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -