Il y a un tableau d'objets. Je trier de sa boucle. Dans les deux séries pour obtenir un lien vers l'image? vm.data.list- tableau d'objet. Loop:Préparation des liens dans la boucle
<tr ng-repeat="item in vm.data.list">
<td ng-bind="item.temp.day"></td>
<td ng-bind="vm.symbal"></td>
<td ng-bind-template="{{ item.humidity }} %"></td>
</tr>
Comme dans le cycle d'obtenir des liens à l'image? (http://openweathermap.org/img/w/vm.data.list[0].weather[0].icon.png, http://openweathermap.org/img/w/vm.data.list[1].weather[0].icon.png et autres)
J'ai essayé de le faire:
<tr ng-repeat="item in vm.data.list">
<td ng-bind="item.temp.day"></td>
<td ng-bind="vm.symbal"></td>
<td ng-bind-template="{{ item.humidity }} %"></td>
<!-- <td img ng-src="http://openweathermap.org/img/w/{{item.weather[0].icon.png}}">-->
<td> <img src=http://openweathermap.org/img/w/{{item}}.weather[0].icon.png></td>
</tr>
Comme cela?
Comme ça?
voir ma réponse modifiée. Toute l'expression angulaire devrait être à l'intérieur du {{}}. – Derlin