parent
899d6ddbab
commit
68d026479f
@ -0,0 +1,18 @@
|
|||||||
|
using System.Text.Json.Serialization;
|
||||||
|
using NzbDrone.Core.CustomFormats;
|
||||||
|
|
||||||
|
namespace NzbDrone.Core.Notifications.Webhook
|
||||||
|
{
|
||||||
|
public class WebhookCustomFormat
|
||||||
|
{
|
||||||
|
[JsonIgnore(Condition = JsonIgnoreCondition.Never)]
|
||||||
|
public int Id { get; set; }
|
||||||
|
public string Name { get; set; }
|
||||||
|
|
||||||
|
public WebhookCustomFormat(CustomFormat customFormat)
|
||||||
|
{
|
||||||
|
Id = customFormat.Id;
|
||||||
|
Name = customFormat.Name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,18 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using NzbDrone.Core.CustomFormats;
|
||||||
|
|
||||||
|
namespace NzbDrone.Core.Notifications.Webhook
|
||||||
|
{
|
||||||
|
public class WebhookCustomFormatInfo
|
||||||
|
{
|
||||||
|
public List<WebhookCustomFormat> CustomFormats { get; set; }
|
||||||
|
public int CustomFormatScore { get; set; }
|
||||||
|
|
||||||
|
public WebhookCustomFormatInfo(List<CustomFormat> customFormats, int customFormatScore)
|
||||||
|
{
|
||||||
|
CustomFormats = customFormats.Select(c => new WebhookCustomFormat(c)).ToList();
|
||||||
|
CustomFormatScore = customFormatScore;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in new issue