Slick carusel angular with multiple images stored in api rest

1

I'm trying to make a carusel using slick carusel with multiple images that are stored in a database and I send them by means of an api rest but when I execute it, it does not make me the carousel but it only shows me the images

asi:

this is the view

<!doctype html>
<html ng-app="demo">
  <head>
    <script src="jquery.js"></script>
    <script src="slick.js"></script>
    <script src="angular.min.js"></script>
    <script src="angular-resource.min.js"></script>
    <script src="slick.min.js"></script>
    <script src="script.js"></script>

    <link rel="stylesheet" type="text/css" href="slick.css"/>
  </head>
  <body ng-controller="Ctrl">
  <slick infinite="true" slides-to-show="3" slides-to-scroll="3"  init-onload=true>
    <div ng-class  ng-repeat="image in images">
      <img ng-src="{{image.ruta}}">
    </div>
    </slick>
  </body>
</html>

and this the controller:

var app = angular.module('demo',['slick','ngResource']);

app.controller('Ctrl', function($scope,$http) {
  $scope.images = [];

  $http.get('http://192.168.100.15/api/hbo_max').success(function(data) 
  {
    $scope.images = data;
  })
  .error(function() {
      alert("error");
    })
});

I do not think it could be wrong, I hope someone could help me with your attention, thanks

    
asked by Esteban Flores 25.07.2016 в 22:50
source

0 answers