Problem icon URL in tabs- I want do that in Angular way

Hello, I want to do that something like this: http://pastebin.com/UHE9MvU8 and this way this doesn’t work.
Where tab icon backround is link from controller. It work, when url is in css, but in my case I get the URL from API and this URL cannot be hardcoded in css!
How to set tab icon- i want get url from angular controller.
Please, I really need help, and I’m out of ideas.

Just use some workaround- here is it: Dynamic image icon in "ion-tab"

.directive(‘ycBackColor’, function() {
return function(scope, element, attrs){
attrs.$observe(‘ycBackColor’, function(value) {
element[0].childNodes[0].style[‘background-color’] = value;
});
};
});

usage:

Dude this is my way to solve it. i make a directive to dynamically change background color of ion-tabs bar. Maybe you can use this way to dynamically import url.