webui: include tvdb link in search results (#13200)

This commit is contained in:
ilike2burnthing
2022-04-25 03:23:36 +01:00
committed by GitHub
parent 012f2bd85e
commit e10f1c822e
5 changed files with 19 additions and 6 deletions

View File

@@ -302,6 +302,10 @@ table td.fit{
} }
.label-tmdb { .label-tmdb {
background-color: #7dbfd4;
}
.label-tvdb {
background-color: #86cca8; background-color: #86cca8;
} }

View File

@@ -972,6 +972,7 @@ function updateReleasesRow(row) {
var TitleLink = $(row).find("td.Title > a"); var TitleLink = $(row).find("td.Title > a");
var IMDBId = $(row).data("imdb"); var IMDBId = $(row).data("imdb");
var TMDBId = $(row).data("tmdb"); var TMDBId = $(row).data("tmdb");
var TVDBId = $(row).data("tvdb");
var Poster = $(row).data("poster"); var Poster = $(row).data("poster");
var Description = $(row).data("description"); var Description = $(row).data("description");
var DownloadVolumeFactor = parseFloat($(row).find("td.DownloadVolumeFactor").html()); var DownloadVolumeFactor = parseFloat($(row).find("td.DownloadVolumeFactor").html());
@@ -1003,6 +1004,10 @@ function updateReleasesRow(row) {
labels.append('\n<a href="https://www.themoviedb.org/movie/' + TMDBId + '" target="_blank" class="label label-tmdb" alt="TMDB" title="TMDB">TMDB</a>'); labels.append('\n<a href="https://www.themoviedb.org/movie/' + TMDBId + '" target="_blank" class="label label-tmdb" alt="TMDB" title="TMDB">TMDB</a>');
} }
if (TVDBId && TVDBId > 0) {
labels.append('\n<a href="https://thetvdb.com/?tab=series&id=' + TVDBId + '" target="_blank" class="label label-tvdb" alt="TVDB" title="TVDB">TVDB</a>');
}
if (!isNaN(DownloadVolumeFactor)) { if (!isNaN(DownloadVolumeFactor)) {
if (DownloadVolumeFactor == 0) { if (DownloadVolumeFactor == 0) {
labels.append('\n<span class="label label-success">FREELEECH</span>'); labels.append('\n<span class="label label-success">FREELEECH</span>');

View File

@@ -285,6 +285,10 @@ table td.fit{
} }
.label-tmdb { .label-tmdb {
background-color: #7dbfd4;
}
.label-tvdb {
background-color: #86cca8; background-color: #86cca8;
} }

View File

@@ -28,8 +28,8 @@
<link rel="stylesheet" type="text/css" href="../bootstrap/bootstrap.min.css?changed=2017083001"> <link rel="stylesheet" type="text/css" href="../bootstrap/bootstrap.min.css?changed=2017083001">
<link rel="stylesheet" type="text/css" href="../animate.css?changed=2017083001"> <link rel="stylesheet" type="text/css" href="../animate.css?changed=2017083001">
<link rel="stylesheet" type="text/css" href="../css/tagify.css?changed=11662"> <link rel="stylesheet" type="text/css" href="../css/tagify.css?changed=11662">
<link rel="stylesheet" type="text/css" href="../custom.css?changed=202204223" media="only screen and (min-device-width: 480px)"> <link rel="stylesheet" type="text/css" href="../custom.css?changed=202204251" media="only screen and (min-device-width: 480px)">
<link rel="stylesheet" type="text/css" href="../custom_mobile.css?changed=202204223" media="only screen and (max-device-width: 480px)"> <link rel="stylesheet" type="text/css" href="../custom_mobile.css?changed=202204251" media="only screen and (max-device-width: 480px)">
<link rel="stylesheet" type="text/css" href="../css/jquery.dataTables.min.css?changed=2017083001"> <link rel="stylesheet" type="text/css" href="../css/jquery.dataTables.min.css?changed=2017083001">
<link rel="stylesheet" type="text/css" href="../css/bootstrap-multiselect.css?changed=2017083001" /> <link rel="stylesheet" type="text/css" href="../css/bootstrap-multiselect.css?changed=2017083001" />
<link rel="stylesheet" type="text/css" href="../css/font-awesome.min.css?changed=2017083001"> <link rel="stylesheet" type="text/css" href="../css/font-awesome.min.css?changed=2017083001">
@@ -458,7 +458,7 @@
</thead> </thead>
<tbody> <tbody>
{{#each releases}} {{#each releases}}
<tr class="jackett-releases-row" data-imdb="{{Imdb}}" data-tmdb="{{TMDb}}" data-poster="{{Poster}}" data-description="{{Description}}"> <tr class="jackett-releases-row" data-imdb="{{Imdb}}" data-tmdb="{{TMDb}}" data-tvdb="{{TVDBId}}" data-poster="{{Poster}}" data-description="{{Description}}">
<td class="fit">{{PublishDate}}</td> <td class="fit">{{PublishDate}}</td>
<td class="fit">{{FirstSeen}}</td> <td class="fit">{{FirstSeen}}</td>
<td class="fit">{{jacketTimespan PublishDate}}</td> <td class="fit">{{jacketTimespan PublishDate}}</td>
@@ -586,7 +586,7 @@
</thead> </thead>
<tbody> <tbody>
{{#each Results}} {{#each Results}}
<tr class="jackett-search-results-row" data-imdb="{{Imdb}}" data-tmdb="{{TMDb}}" data-poster="{{Poster}}" data-description="{{Description}}"> <tr class="jackett-search-results-row" data-imdb="{{Imdb}}" data-tmdb="{{TMDb}}" data-tvdb="{{TVDBId}}" data-poster="{{Poster}}" data-description="{{Description}}">
<td>{{PublishDate}}</td> <td>{{PublishDate}}</td>
<td>{{jacketTimespan PublishDate}}</td> <td>{{jacketTimespan PublishDate}}</td>
<td>{{Tracker}}</td> <td>{{Tracker}}</td>
@@ -754,6 +754,6 @@
</script> </script>
<script type="text/javascript" src="../libs/api.js?changed=2017083001"></script> <script type="text/javascript" src="../libs/api.js?changed=2017083001"></script>
<script type="text/javascript" src="../custom.js?changed=202204222"></script> <script type="text/javascript" src="../custom.js?changed=202204251"></script>
</body> </body>
</html> </html>

View File

@@ -16,7 +16,7 @@
<link href="../bootstrap/bootstrap.min.css" rel="stylesheet"> <link href="../bootstrap/bootstrap.min.css" rel="stylesheet">
<link href="../animate.css" rel="stylesheet"> <link href="../animate.css" rel="stylesheet">
<link href="../custom.css?changed=202204223" rel="stylesheet"> <link href="../custom.css?changed=202204251" rel="stylesheet">
<title>Jackett</title> <title>Jackett</title>
</head> </head>