Вопрос

I have been spinning my wheels on this one. Reading through most of the answers on stackoverfolw has helped me understand more about building nested arrays and using .json files. I still cannot figure out what I'm not doing correctly.
I am trying to build a image viewer for my artwork using Angular. I want to create a .json file that will used to "index/category my work" This way I can use Angular to call the files, names and other data to view without all the hard coding img src and such. Here is a link to JSFiddle that I have been messing with. I cannot understand how to pull data from the nested array. If someone could point me in the right direction I would really appreciate the help on this.

Это было полезно?

Решение

I have updated the plunker, Please see. Your json was coming in data object in received output of web service.

 $scope.fetchContent = function () {
    $http.get($scope.url).then(function (data){
        $scope.portfolio = data.data;
      });
  }

http://plnkr.co/edit/GH14vIWzKVSOdA3wI0Bb?p=preview

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top