1
0
Fork 0
mirror of https://github.com/Radarr/Radarr synced 2024-12-26 01:38:24 +00:00

added placeholder image for missing posters.

This commit is contained in:
kay.one 2013-06-06 20:52:46 -07:00
parent f94ea0e78a
commit 4015984900
6 changed files with 20 additions and 8 deletions

View file

@ -105,6 +105,10 @@ module.exports = function (grunt) {
src : 'UI/**/*.png',
dest: '_output/'
},
jpg : {
src : 'UI/**/*.jpg',
dest: '_output/'
},
fonts : {
src : 'UI/**/FontAwesome/*.*',
dest: '_output/'
@ -140,6 +144,10 @@ module.exports = function (grunt) {
files: '<%= copy.images.src %>',
tasks: ['copy:images']
},
copyImages : {
files: '<%= copy.jpg.src %>',
tasks: ['copy:jpg']
},
copyFonts : {
files: '<%= copy.fonts.src %>',
tasks: ['copy:fonts']

View file

@ -2,7 +2,7 @@
<div class="row">
<div class="span2">
<a href="{{traktUrl}}" target="_blank">
<img class="add-series-poster" src="{{remotePoster}}">
<img class="add-series-poster" src="{{remotePoster}}" {{defaultImg}}>
</a>
</div>
<div class="span9">

View file

@ -1,7 +1,7 @@
<div class="row series-page-header">
<div class="span3">
<a href="{{traktUrl}}" target="_blank">
<img class="series-poster" src="{{poster}}">
<img class="series-poster" src="{{poster}}" {{defaultImg}}>
</a>
</div>
<div class="offset1 span7">

View file

@ -2,7 +2,7 @@
<div class="row">
<div class="span2">
<a href="{{route}}">
<img class="series-poster" src="{{poster}}">
<img class="series-poster" src="{{poster}}" {{defaultImg}}>
</a>
</div>
<div class="span10">

View file

@ -11,7 +11,7 @@
<div class="ended-banner">Ended</div>
{{/unless}}
<a href="{{route}}">
<img class="series-poster" src="{{poster}} ">
<img class="series-poster" src="{{poster}}" {{defaultImg}}>
</a>
</div>
</div>

View file

@ -8,7 +8,7 @@ define(['app'], function () {
return new Handlebars.SafeString(templateFunction(this));
});
Handlebars.registerHelper("debug", function(optionalValue) {
Handlebars.registerHelper("debug", function (optionalValue) {
console.log("Current Context");
console.log("====================");
console.log(this);
@ -20,11 +20,11 @@ define(['app'], function () {
}
});
Handlebars.registerHelper("fileSize", function(size) {
Handlebars.registerHelper("fileSize", function (size) {
return NzbDrone.Shared.FormatHelpers.FileSizeHelper(size);
});
Handlebars.registerHelper("date", function(date) {
Handlebars.registerHelper("date", function (date) {
//TODO: show actual date in tooltip
if (!date) {
return '';
@ -36,4 +36,8 @@ define(['app'], function () {
return new Handlebars.SafeString(result);
});
});
Handlebars.registerHelper('defaultImg', function () {
return new Handlebars.SafeString(' onerror="this.src=\'/content/images/poster-dark.jpg\';"');
});
});