Run dotnet format (#3244)

This commit is contained in:
Nicolas Dorier
2021-12-31 16:59:02 +09:00
committed by GitHub
parent e2d0b7c5f7
commit 04b8eafacb
259 changed files with 1613 additions and 1491 deletions

View File

@@ -38,7 +38,7 @@ namespace BTCPayServer.Models.AppViewModels
var defaultAppType = AppType.PointOfSale.ToString();
var choices = typeof(AppType).GetEnumNames().Select(o => new Format
{
Name = typeof(AppType).DisplayName(o),
Name = typeof(AppType).DisplayName(o),
Value = o
}).ToArray();
var chosen = choices.FirstOrDefault(f => f.Value == defaultAppType) ?? choices.FirstOrDefault();

View File

@@ -10,7 +10,7 @@ namespace BTCPayServer.Models.AppViewModels
{
public string StoreId { get; set; }
public string StoreName { get; set; }
[Required]
[MaxLength(50)]
[MinLength(1)]
@@ -50,12 +50,12 @@ namespace BTCPayServer.Models.AppViewModels
[Display(Name = "Enable Disqus Comments")]
public bool DisqusEnabled { get; set; } = true;
[Display(Name = "Disqus Shortname")]
[Display(Name = "Disqus Shortname")]
public string DisqusShortname { get; set; }
[Display(Name = "Start date")]
public DateTime? StartDate { get; set; }
[Display(Name = "End date")]
public DateTime? EndDate { get; set; }
@@ -66,14 +66,14 @@ namespace BTCPayServer.Models.AppViewModels
[Display(Name = "Set a target amount")]
[Range(0, double.PositiveInfinity)]
public decimal? TargetAmount { get; set; }
public IEnumerable<string> ResetEveryValues = Enum.GetNames(typeof(CrowdfundResetEvery));
[Display(Name = "Reset goal every")]
public string ResetEvery { get; set; } = nameof(CrowdfundResetEvery.Never);
public int ResetEveryAmount { get; set; } = 1;
[Display(Name = "Do not allow additional contributions after target has been reached")]
public bool EnforceTargetAmount { get; set; }
@@ -95,16 +95,16 @@ namespace BTCPayServer.Models.AppViewModels
[Display(Name = "Sort contribution perks by popularity")]
public bool SortPerksByPopularity { get; set; }
[Display(Name = "Display contribution ranking")]
public bool DisplayPerksRanking { get; set; }
[Display(Name = "Display contribution value")]
public bool DisplayPerksValue { get; set; }
[Display(Name = "Sounds to play when a payment is made. One sound per line")]
public string Sounds { get; set; }
[Display(Name = "Colors to rotate between with animation when a payment is made. One color per line (any valid css color value).")]
public string AnimationColors { get; set; }

View File

@@ -10,7 +10,7 @@ namespace BTCPayServer.Models.AppViewModels
{
public string StoreId { get; set; }
public string StoreName { get; set; }
[Required]
[MaxLength(50)]
[MinLength(1)]

View File

@@ -16,7 +16,7 @@ namespace BTCPayServer.Models.AppViewModels
Minimum,
Fixed
}
public ItemPriceType Type { get; set; }
public string Formatted { get; set; }
public decimal? Value { get; set; }