diff --git a/BTCPayServer/Controllers/StoresController.cs b/BTCPayServer/Controllers/StoresController.cs index 2c55ca0ca..bd420f076 100644 --- a/BTCPayServer/Controllers/StoresController.cs +++ b/BTCPayServer/Controllers/StoresController.cs @@ -381,6 +381,7 @@ namespace BTCPayServer.Controllers vm.OnChainMinValue = storeBlob.OnChainMinValue?.ToString() ?? ""; vm.LightningMaxValue = storeBlob.LightningMaxValue?.ToString() ?? ""; vm.LightningAmountInSatoshi = storeBlob.LightningAmountInSatoshi; + vm.LightningPrivateRouteHints = storeBlob.LightningPrivateRouteHints; vm.RedirectAutomatically = storeBlob.RedirectAutomatically; return View(vm); } @@ -441,6 +442,7 @@ namespace BTCPayServer.Controllers blob.OnChainMinValue = onchainMinValue; blob.LightningMaxValue = lightningMaxValue; blob.LightningAmountInSatoshi = model.LightningAmountInSatoshi; + blob.LightningPrivateRouteHints = model.LightningPrivateRouteHints; blob.RedirectAutomatically = model.RedirectAutomatically; if (CurrentStore.SetStoreBlob(blob)) { diff --git a/BTCPayServer/Data/StoreBlob.cs b/BTCPayServer/Data/StoreBlob.cs index 143805d57..c91d313da 100644 --- a/BTCPayServer/Data/StoreBlob.cs +++ b/BTCPayServer/Data/StoreBlob.cs @@ -92,6 +92,7 @@ namespace BTCPayServer.Data [JsonConverter(typeof(CurrencyValueJsonConverter))] public CurrencyValue LightningMaxValue { get; set; } public bool LightningAmountInSatoshi { get; set; } + public bool LightningPrivateRouteHints { get; set; } public string CustomCSS { get; set; } public string CustomLogo { get; set; } diff --git a/BTCPayServer/Models/StoreViewModels/CheckoutExperienceViewModel.cs b/BTCPayServer/Models/StoreViewModels/CheckoutExperienceViewModel.cs index ffb14db2c..8d1e789ab 100644 --- a/BTCPayServer/Models/StoreViewModels/CheckoutExperienceViewModel.cs +++ b/BTCPayServer/Models/StoreViewModels/CheckoutExperienceViewModel.cs @@ -63,7 +63,10 @@ namespace BTCPayServer.Models.StoreViewModels [Display(Name = "Display lightning payment amounts in Satoshis")] public bool LightningAmountInSatoshi { get; set; } - + + [Display(Name = "Add hop hints for private channels to the lightning invoice")] + public bool LightningPrivateRouteHints { get; set; } + [Display(Name = "Redirect invoice to redirect url automatically after paid")] public bool RedirectAutomatically { get; set; } } diff --git a/BTCPayServer/Views/Stores/CheckoutExperience.cshtml b/BTCPayServer/Views/Stores/CheckoutExperience.cshtml index 2542fe1bb..095877590 100644 --- a/BTCPayServer/Views/Stores/CheckoutExperience.cshtml +++ b/BTCPayServer/Views/Stores/CheckoutExperience.cshtml @@ -81,6 +81,12 @@ +
+ + + +
+