Skip to content
Browse files

Display 'Not Rated' for destinations without ratings

  • Loading branch information...
1 parent be27eec commit edb6b0eda91eed080892d7fb5c8a1ce7c6d151bb @eromba eromba committed Nov 30, 2011
Showing with 2 additions and 2 deletions.
  1. +1 −1 assets/www/index.html
  2. +1 −1 assets/www/js/main.js
View
2 assets/www/index.html
@@ -210,7 +210,7 @@ <h1 id="hotness-scale" style="text-align: center" class="hotness-1"></h1>
<h2 class="name"><%= this.name %></h2>
<p class="rating">
<span class="label">Rating:</span>
- <span class="value"><%= (this.rating == null) ? '0' : parseFloat(this.rating).toFixed(1) %> out of 5.0</span>
+ <span class="value"><%= (this.rating == null) ? 'Not Rated' : parseFloat(this.rating).toFixed(1) + ' out of 5.0' %></span>
</p>
<p class="distance">
<span class="label">Distance:</span>
View
2 assets/www/js/main.js
@@ -362,7 +362,7 @@ WUR.loadMapPage = function(places) {
WUR.markers.push(marker);
bounds.extend(placeLatLng);
google.maps.event.addListener(marker, 'click', function() {
- WUR.infoWindow.setContent(this.place.name + ' : ' + ((this.place.rating == null) ? '0' : parseFloat(this.place.rating).toFixed(1)) + '/5.0 Rating');
+ WUR.infoWindow.setContent(this.place.name + ' : ' + ((this.place.rating == null) ? 'Not Rated' : parseFloat(this.place.rating).toFixed(1) + '/5.0 Rating'));
WUR.infoWindow.open(WUR.map, this);
});
}

0 comments on commit edb6b0e

Please sign in to comment.
Something went wrong with that request. Please try again.