Ng-click 1 error


#1

Hello there!
I faced with an “Did you display the product’s likes?” error and can’t find what’s wrong. Hope, someone’ll help me :slightly_smiling_face:

app.controller(‘MainController’, [’$scope’, function($scope) {
$scope.title = ‘This Month’s Bestsellers’;
$scope.promo = ‘The most popular books this month.’;
$scope.products = [
{
name: ‘The Book of Trees’,
price: 19,
pubdate: new Date(‘2014’, ‘03’, ‘08’),
cover: ‘img/the-book-of-trees.jpg’,
likes:0
},
{
name: ‘Program or be Programmed’,
price: 8,
pubdate: new Date(‘2013’, ‘08’, ‘01’),
cover: ‘img/program-or-be-programmed.jpg’,
likes:0
},
{
name: ‘Harry Potter & The Prisoner of Azkaban’,
price: 11.99,
pubdate: new Date(‘1999’, ‘07’, ‘08’),
cover: ‘http://upload.wikimedia.org/wikipedia/en/b/b4/Harry_Potter_and_the_Prisoner_of_Azkaban_(US_cover).jpg’,
likes:0
},
{
name: ‘Ready Player One’,
price: 7.99,
pubdate: new Date(‘2011’, ‘08’, ‘16’),
cover: ‘http://upload.wikimedia.org/wikipedia/en/a/a4/Ready_Player_One_cover.jpg’,
likes:0
}
];
}]);

 <div ng-repeat="product in products" class="col-md-6"> 
  				<div class="thumbnail"> 
    				<img ng-src="{{ product.cover }}"> 
    				<p class="title">{{ product.name }}</p> 
				    <p class="price">{{ product.price | currency }}</p> 
				    <p class="date">{{ product.pubdate | date }}</p> 
            <div class="rating">
              <p class="likes">+ </p>
            </div>
  				</div> 
				</div>

#2

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.