2020-02-09 02:35:16 +00:00
|
|
|
namespace Jackett.Common.Models.DTO
|
2017-08-08 15:02:16 +00:00
|
|
|
{
|
|
|
|
public class TorrentPotatoRequest
|
|
|
|
{
|
|
|
|
public string Username { get; set; }
|
|
|
|
public string Imdbid { get; set; }
|
|
|
|
public string Search { get; set; }
|
|
|
|
|
|
|
|
public static TorznabQuery ToTorznabQuery(TorrentPotatoRequest request)
|
|
|
|
{
|
|
|
|
var torznabQuery = new TorznabQuery()
|
|
|
|
{
|
|
|
|
Categories = new int[1] { TorznabCatType.Movies.ID },
|
|
|
|
SearchTerm = request.Search,
|
|
|
|
ImdbID = request.Imdbid,
|
2017-08-11 12:29:15 +00:00
|
|
|
QueryType = "TorrentPotato"
|
2017-08-08 15:02:16 +00:00
|
|
|
};
|
|
|
|
torznabQuery.ExpandCatsToSubCats();
|
|
|
|
|
|
|
|
return torznabQuery;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|