diff --git a/.circleci/config.yml b/.circleci/config.yml index bd0462823..7fa80eb03 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -124,7 +124,6 @@ workflows: filters: branches: only: master - publish: jobs: - amd64: @@ -134,21 +133,22 @@ workflows: ignore: /.*/ # only act on version tags v1.0.0.88 or v1.0.2-1 # OR feature tags like vlndseedbackup + # OR features on specific versions like v1.0.0.88-lndseedbackup-1 tags: - - only: /(v[1-9]+(\.[0-9]+)*(-[0-9]+)?)|(v[a-z]+)/ + + only: /(v[1-9]+(\.[0-9]+)*(-[a-z0-9-]+)?)|(v[a-z0-9-]+)/ - arm32v7: filters: branches: ignore: /.*/ tags: - only: /(v[1-9]+(\.[0-9]+)*(-[0-9]+)?)|(v[a-z]+)/ + only: /(v[1-9]+(\.[0-9]+)*(-[a-z0-9-]+)?)|(v[a-z0-9-]+)/ - arm64v8: filters: branches: ignore: /.*/ tags: - only: /(v[1-9]+(\.[0-9]+)*(-[0-9]+)?)|(v[a-z]+)/ + only: /(v[1-9]+(\.[0-9]+)*(-[a-z0-9-]+)?)|(v[a-z0-9-]+)/ - multiarch: requires: - amd64 @@ -158,4 +158,4 @@ workflows: branches: ignore: /.*/ tags: - only: /(v[1-9]+(\.[0-9]+)*(-[0-9]+)?)|(v[a-z]+)/ + only: /(v[1-9]+(\.[0-9]+)*(-[a-z0-9-]+)?)|(v[a-z0-9-]+)/ diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md new file mode 100644 index 000000000..da29d20f2 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug-report.md @@ -0,0 +1,38 @@ +--- +name: Bug report +about: File a bug report +title: '' +labels: '' +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**To Reproduce** +Steps to reproduce the behavior: +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Your BTCPay Environment (please complete the following information):** +- BTCPay Server Version [available in the right bottom corner of footer] +- Deployment Method: [e.g. Docker, Manual, Third-Party-hoist] + - Browser [e.g. chrome, safari] + +**Logs (if applicable)** +Basic logs can be found in Server Settings > Logs. More logs https://docs.btcpayserver.org/Troubleshooting/#2-looking-through-the-logs + +**Setup Parameters** +If you're reporting a deployment issue run `. btcpay-setup.sh -i` and paste your the parameters by obscuring private information. + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index f9c04659e..000000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,37 +0,0 @@ ---- -name: Report a problem -about: File a technical problem or report a bug ---- - -**Describe the problem/bug** -A clear and concise description of what the bug is. - -**Your environment** -* Version of BTCPay Server: -* Deployment method: -* Other relevant environment details: - -**Logs (if applicable)** -Basic logs can be found in Server Settings > Logs. - -**Setup Parameters** -If you're reporting a deployment issue run `. btcpay-setup.sh -i` and paste your the paremeters by obscuring private information. - -**To Reproduce** -Steps to reproduce the behavior: -1. Go to '...' -2. Click on '....' -3. Scroll down to '....' -4. See error - -**Expected behavior** -A clear and concise description of what you expected to happen. - -**Actual behavior** -Tell us what happens instead - -**Screenshots/Links** -If applicable, add screenshots or links to help explain your problem. - -**Additional context** -Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 000000000..2741e2c39 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Community Support Chat + url: https://chat.btcpayserver.org/ + about: Ask general questions and get community support in real-time. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index a8556d6e0..4c3216d81 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -1,6 +1,9 @@ --- name: Feature request -about: Ideas and feature requests +about: Suggest a new feature or enhancement +title: '' +labels: '' +assignees: '' --- @@ -10,11 +13,11 @@ A clear and concise description of what the problem is. Ex. I'm always frustrate **Describe the solution you'd like** A clear and concise description of what you want to happen. +**Sketch/Image/Wireframe/Mockup** + If applicable provide examples, wireframes, sketches or images to better explain your idea. + **Describe alternatives you've considered** A clear and concise description of any alternative solutions or features you've considered. -**Provide examples** -If applicable provide examples, wireframes, sketches or images to better explain your idea. - **Additional context** Add any other context or screenshots about the feature request here. diff --git a/BTCPayServer.Tests/README.md b/BTCPayServer.Tests/README.md index 16e31a81b..978327c49 100644 --- a/BTCPayServer.Tests/README.md +++ b/BTCPayServer.Tests/README.md @@ -52,6 +52,9 @@ If you get this message: Please, run the test `CanSetLightningServer`, this will establish a channel between the customer and the merchant, then, retry. +Alternatively you can run the `./docker-lightning-channel-setup.sh` script to establish the channel connection. +The `./docker-lightning-channel-teardown.sh` script closes any existing lightning channels. + ## FAQ `docker-compose up dev` failed or tests are not passing, what should I do? diff --git a/BTCPayServer.Tests/SeleniumTests.cs b/BTCPayServer.Tests/SeleniumTests.cs index d214abb64..4145dba4f 100644 --- a/BTCPayServer.Tests/SeleniumTests.cs +++ b/BTCPayServer.Tests/SeleniumTests.cs @@ -664,6 +664,7 @@ namespace BTCPayServer.Tests Assert.Equal(parsedBip21.Address.ToString(), s.Driver.FindElement(By.Id($"Outputs_0__DestinationAddress")).GetAttribute("value")); s.GoToWallet(new WalletId(storeId.storeId, "BTC"), WalletsNavPages.Settings); + var walletUrl = s.Driver.Url; s.Driver.FindElement(By.Id("SettingsMenu")).ForceClick(); s.Driver.FindElement(By.CssSelector("button[value=view-seed]")).Click(); @@ -671,7 +672,12 @@ namespace BTCPayServer.Tests // Seed backup page var recoveryPhrase = s.Driver.FindElements(By.Id("recovery-phrase")).First().GetAttribute("data-mnemonic"); Assert.Equal(mnemonic.ToString(), recoveryPhrase); - Assert.Contains("The recovery phrase will also be stored on a server as a hot wallet.", s.Driver.PageSource); + Assert.Contains("The recovery phrase will also be stored on the server as a hot wallet.", s.Driver.PageSource); + + // No confirmation, just a link to return to the wallet + Assert.Empty(s.Driver.FindElements(By.Id("confirm"))); + s.Driver.FindElement(By.Id("proceed")).Click(); + Assert.Equal(walletUrl, s.Driver.Url); } } void SetTransactionOutput(SeleniumTester s, int index, BitcoinAddress dest, decimal amount, bool subtract = false) diff --git a/BTCPayServer.Tests/docker-lightning-channel-setup.sh b/BTCPayServer.Tests/docker-lightning-channel-setup.sh new file mode 100755 index 000000000..562953d03 --- /dev/null +++ b/BTCPayServer.Tests/docker-lightning-channel-setup.sh @@ -0,0 +1,69 @@ +#!/bin/bash + +# Commands +BCMD=./docker-bitcoin-cli.sh +GCMD=./docker-bitcoin-generate.sh +CCMD=./docker-customer-lightning-cli.sh +MCMD=./docker-merchant-lightning-cli.sh + +function channel_count () { + local cmd=$1; local id=$2; + local count=$($cmd listchannels | jq -r ".channels | map(select(.destination == \"$id\")) | length | tonumber") 2>/dev/null + return $count +} + +function create_channel () { + local cmd=$1; local id=$2; + local btcaddr=$($cmd newaddr | jq -r '.address') + $BCMD sendtoaddress $btcaddr 0.15 >/dev/null + $GCMD 10 >/dev/null + local fundres=$($cmd fundchannel $id 14500000 5000 | jq -r '.channel_id') + $GCMD 20 >/dev/null + sleep 2 + channel_count $cmd $id + local count=$? + return $count +} + +# General information +cinfo=$($CCMD getinfo | jq '.' 2>/dev/null) +minfo=$($MCMD getinfo | jq '.' 2>/dev/null) +cid=$(echo $cinfo | jq -r '.id') +mid=$(echo $minfo | jq -r '.id') +caddr=$(echo $cinfo | jq -r '.address[] | "\(.address):\(.port)"') +maddr=$(echo $minfo | jq -r '.address[] | "\(.address):\(.port)"') + +printf "Customer ID: %s@%s\n\r" $cid $caddr +printf "Merchant ID: %s@%s\n\r" $mid $maddr + +# Connections +printf "\n\rConnecting both parties …\n\r" + +cconnid=$($CCMD connect "$mid@$maddr" | jq -r '.id' 2>/dev/null) +mconnid=$($MCMD connect "$cid@$caddr" | jq -r '.id' 2>/dev/null) + +printf "Customer to merchant %s\n\r" $([[ $cconnid == $mid ]] && echo "succeeded" || echo "failed") +printf "Merchant to customer %s\n\r" $([[ $mconnid == $cid ]] && echo "succeeded" || echo "failed") + +# Channels +printf "\n\rChecking channels …\n\r" +channel_count $CCMD $mid +cchanscount=$? +channel_count $MCMD $cid +mchanscount=$? + +printf "Customer channel count to merchant: %d\n\r" $cchanscount +printf "Merchant channel count to customer: %d\n\r" $mchanscount + +# Open channels if there are none, details: https://github.com/ElementsProject/lightning#opening-a-channel +if [[ $cchanscount -eq 0 ]]; then + create_channel $CCMD $mid + cchanres=$? + printf "Establishing channel from customer to merchant %s\n\r" $([[ $cchanres -gt 0 ]] && echo "succeeded" || echo "failed") +fi + +if [[ $mchanscount -eq 0 ]]; then + create_channel $MCMD $cid + mchanres=$? + printf "Establishing channel from merchant to customer %s\n\r" $([[ $mchanres -gt 0 ]] && echo "succeeded" || echo "failed") +fi diff --git a/BTCPayServer.Tests/docker-lightning-channel-teardown.sh b/BTCPayServer.Tests/docker-lightning-channel-teardown.sh new file mode 100755 index 000000000..c67281a55 --- /dev/null +++ b/BTCPayServer.Tests/docker-lightning-channel-teardown.sh @@ -0,0 +1,12 @@ +#!/bin/bash +set -e + +channels=$(./docker-merchant-lightning-cli.sh listchannels | jq -cr '.channels | map(.short_channel_id) | unique') +printf "Channels: %s\n\r" $channels + +for chanid in $(echo "${channels}" | jq -cr '.[]') +do + printf "Closing channel ID: %s\n\r" $chanid + ./docker-merchant-lightning-cli.sh close $chanid + ./docker-bitcoin-generate.sh 20 > /dev/null +done diff --git a/BTCPayServer/Views/Shared/Components/NotificationsDropdown/Default.cshtml b/BTCPayServer/Components/NotificationsDropdown/Default.cshtml similarity index 56% rename from BTCPayServer/Views/Shared/Components/NotificationsDropdown/Default.cshtml rename to BTCPayServer/Components/NotificationsDropdown/Default.cshtml index 3e8a80093..2671854bb 100644 --- a/BTCPayServer/Views/Shared/Components/NotificationsDropdown/Default.cshtml +++ b/BTCPayServer/Components/NotificationsDropdown/Default.cshtml @@ -1,4 +1,5 @@ -@model BTCPayServer.Services.Notifications.NotificationSummaryViewModel +@inject LinkGenerator linkGenerator +@model BTCPayServer.Components.NotificationsDropdown.NotificationSummaryViewModel @if (Model.UnseenCount > 0) { @@ -31,3 +32,36 @@ else } + diff --git a/BTCPayServer/Components/NotificationsDropdown/NoticationsDropdown.cs b/BTCPayServer/Components/NotificationsDropdown/NoticationsDropdown.cs new file mode 100644 index 000000000..3cff8e623 --- /dev/null +++ b/BTCPayServer/Components/NotificationsDropdown/NoticationsDropdown.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using BTCPayServer.Services.Notifications; +using Microsoft.AspNetCore.Mvc; + +namespace BTCPayServer.Components.NotificationsDropdown +{ + public class NotificationsDropdown : ViewComponent + { + private readonly NotificationManager _notificationManager; + + public NotificationsDropdown(NotificationManager notificationManager) + { + _notificationManager = notificationManager; + } + + public async Task InvokeAsync() + { + return View(await _notificationManager.GetSummaryNotifications(UserClaimsPrincipal)); + } + } +} diff --git a/BTCPayServer/Components/NotificationsDropdown/NotificationSummaryViewModel.cs b/BTCPayServer/Components/NotificationsDropdown/NotificationSummaryViewModel.cs new file mode 100644 index 000000000..41eaf556c --- /dev/null +++ b/BTCPayServer/Components/NotificationsDropdown/NotificationSummaryViewModel.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using BTCPayServer.Models.NotificationViewModels; + +namespace BTCPayServer.Components.NotificationsDropdown +{ + public class NotificationSummaryViewModel + { + public int UnseenCount { get; set; } + public List Last5 { get; set; } + } +} diff --git a/BTCPayServer/Views/Shared/_TableFooterPager.cshtml b/BTCPayServer/Components/Pager/Default.cshtml similarity index 100% rename from BTCPayServer/Views/Shared/_TableFooterPager.cshtml rename to BTCPayServer/Components/Pager/Default.cshtml diff --git a/BTCPayServer/Components/Pager/Pager.cs b/BTCPayServer/Components/Pager/Pager.cs new file mode 100644 index 000000000..9cb40cda5 --- /dev/null +++ b/BTCPayServer/Components/Pager/Pager.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using BTCPayServer.Models; +using Microsoft.AspNetCore.Mvc; + +namespace BTCPayServer.Components +{ + public class Pager : ViewComponent + { + public Pager() + { + } + public IViewComponentResult Invoke(BasePagingViewModel viewModel) + { + return View(viewModel); + } + } +} diff --git a/BTCPayServer/Controllers/InvoiceController.UI.cs b/BTCPayServer/Controllers/InvoiceController.UI.cs index e20516223..2a8ae27da 100644 --- a/BTCPayServer/Controllers/InvoiceController.UI.cs +++ b/BTCPayServer/Controllers/InvoiceController.UI.cs @@ -145,7 +145,7 @@ namespace BTCPayServer.Controllers .ToList(); var defaultRefund = invoice.Payments .Select(p => p.GetBlob(_NetworkProvider)) - .Select(p => p.GetPaymentMethodId()) + .Select(p => p?.GetPaymentMethodId()) .FirstOrDefault(p => p != null && p.PaymentType == BitcoinPaymentType.Instance); // TODO: What if no option? var refund = new RefundModel(); diff --git a/BTCPayServer/Controllers/NotificationsController.cs b/BTCPayServer/Controllers/NotificationsController.cs index 4a664d9e9..b8c01f687 100644 --- a/BTCPayServer/Controllers/NotificationsController.cs +++ b/BTCPayServer/Controllers/NotificationsController.cs @@ -15,22 +15,6 @@ using Microsoft.AspNetCore.Mvc; namespace BTCPayServer.Controllers { - - public class NotificationsDropdown : ViewComponent - { - private readonly NotificationManager _notificationManager; - - public NotificationsDropdown(NotificationManager notificationManager) - { - _notificationManager = notificationManager; - } - - public async Task InvokeAsync(int noOfEmployee) - { - return View(await _notificationManager.GetSummaryNotifications(UserClaimsPrincipal)); - } - } - [BitpayAPIConstraint(false)] [Authorize(AuthenticationSchemes = AuthenticationSchemes.Cookie)] [Route("[controller]/[action]")] diff --git a/BTCPayServer/Controllers/PullPaymentController.cs b/BTCPayServer/Controllers/PullPaymentController.cs index 034bb5345..fe8bebd5c 100644 --- a/BTCPayServer/Controllers/PullPaymentController.cs +++ b/BTCPayServer/Controllers/PullPaymentController.cs @@ -133,7 +133,7 @@ namespace BTCPayServer.Controllers { TempData.SetStatusMessageModel(new StatusMessageModel() { - Message = $"You posted a claim of {_currencyNameTable.DisplayFormatCurrency(vm.ClaimedAmount, ppBlob.Currency)} to {vm.Destination}, this will get fullfilled later.", + Message = $"Your claim request of {_currencyNameTable.DisplayFormatCurrency(vm.ClaimedAmount, ppBlob.Currency)} to {vm.Destination} has been submitted and is awaiting approval.", Severity = StatusMessageModel.StatusSeverity.Success }); } diff --git a/BTCPayServer/Controllers/WalletsController.cs b/BTCPayServer/Controllers/WalletsController.cs index 5d73f04c4..b165add39 100644 --- a/BTCPayServer/Controllers/WalletsController.cs +++ b/BTCPayServer/Controllers/WalletsController.cs @@ -1160,6 +1160,7 @@ namespace BTCPayServer.Controllers CryptoCode = walletId.CryptoCode, Mnemonic = seed, IsStored = true, + RequireConfirm = false, ReturnUrl = Url.Action(nameof(WalletSettings), new { walletId }) }; return this.RedirectToRecoverySeedBackup(recoveryVm); diff --git a/BTCPayServer/Data/PaymentDataExtensions.cs b/BTCPayServer/Data/PaymentDataExtensions.cs index 3423b88a4..45c267b75 100644 --- a/BTCPayServer/Data/PaymentDataExtensions.cs +++ b/BTCPayServer/Data/PaymentDataExtensions.cs @@ -15,7 +15,7 @@ namespace BTCPayServer.Data PaymentEntity paymentEntity = null; if (network == null) { - paymentEntity = NBitcoin.JsonConverters.Serializer.ToObject(unziped, null); + return null; } else { diff --git a/BTCPayServer/Extensions.cs b/BTCPayServer/Extensions.cs index f98679aab..8be823410 100644 --- a/BTCPayServer/Extensions.cs +++ b/BTCPayServer/Extensions.cs @@ -446,6 +446,7 @@ namespace BTCPayServer new KeyValuePair("mnemonic", vm.Mnemonic), new KeyValuePair("passphrase", vm.Passphrase), new KeyValuePair("isStored", vm.IsStored ? "true" : "false"), + new KeyValuePair("requireConfirm", vm.RequireConfirm ? "true" : "false"), new KeyValuePair("returnUrl", vm.ReturnUrl) } }; diff --git a/BTCPayServer/Hosting/Startup.cs b/BTCPayServer/Hosting/Startup.cs index ec7765212..dfe61389c 100644 --- a/BTCPayServer/Hosting/Startup.cs +++ b/BTCPayServer/Hosting/Startup.cs @@ -81,6 +81,12 @@ namespace BTCPayServer.Hosting return builtInFactory(context); }; }) + .AddRazorOptions(o => + { + // /Components/{View Component Name}/{View Name}.cshtml + o.ViewLocationFormats.Add("/{0}.cshtml"); + o.PageViewLocationFormats.Add("/{0}.cshtml"); + }) .AddNewtonsoftJson() #if RAZOR_RUNTIME_COMPILE .AddRazorRuntimeCompilation() diff --git a/BTCPayServer/Models/StoreViewModels/RecoverySeedBackupViewModel.cs b/BTCPayServer/Models/StoreViewModels/RecoverySeedBackupViewModel.cs index 265d37f27..a00c7a20f 100644 --- a/BTCPayServer/Models/StoreViewModels/RecoverySeedBackupViewModel.cs +++ b/BTCPayServer/Models/StoreViewModels/RecoverySeedBackupViewModel.cs @@ -10,8 +10,9 @@ namespace BTCPayServer.Models.StoreViewModels public string CryptoCode { get; set; } public string Mnemonic { get; set; } public string Passphrase { get; set; } - public bool IsStored { get; set; } public string ReturnUrl { get; set; } + public bool IsStored { get; set; } + public bool RequireConfirm { get; set; } = true; public string[] Words { diff --git a/BTCPayServer/Services/Invoices/Export/InvoiceExport.cs b/BTCPayServer/Services/Invoices/Export/InvoiceExport.cs index d9357924e..81a122a45 100644 --- a/BTCPayServer/Services/Invoices/Export/InvoiceExport.cs +++ b/BTCPayServer/Services/Invoices/Export/InvoiceExport.cs @@ -47,10 +47,8 @@ namespace BTCPayServer.Services.Invoices.Export using StringWriter writer = new StringWriter(); using var csvWriter = new CsvHelper.CsvWriter(writer, new CsvConfiguration(CultureInfo.InvariantCulture), true); csvWriter.WriteHeader(); - foreach (var invoice in invoices) - { - csvWriter.WriteRecord(invoice); - } + csvWriter.NextRecord(); + csvWriter.WriteRecords(invoices); csvWriter.Flush(); return writer.ToString(); } diff --git a/BTCPayServer/Services/Invoices/InvoiceRepository.cs b/BTCPayServer/Services/Invoices/InvoiceRepository.cs index 59d70116f..674de619a 100644 --- a/BTCPayServer/Services/Invoices/InvoiceRepository.cs +++ b/BTCPayServer/Services/Invoices/InvoiceRepository.cs @@ -484,6 +484,8 @@ retry: entity.Payments = invoice.Payments.Select(p => { var paymentEntity = p.GetBlob(_Networks); + if (paymentEntity is null) + return null; // PaymentEntity on version 0 does not have their own fee, because it was assumed that the payment method have fixed fee. // We want to hide this legacy detail in InvoiceRepository, so we fetch the fee from the PaymentMethod and assign it to the PaymentEntity. if (paymentEntity.Version == 0) @@ -497,6 +499,7 @@ retry: return paymentEntity; }) + .Where(p => p != null) .OrderBy(a => a.ReceivedTime).ToList(); #pragma warning restore CS0618 var state = invoice.GetInvoiceState(); diff --git a/BTCPayServer/Services/Notifications/Blobs/PayoutNotification.cs b/BTCPayServer/Services/Notifications/Blobs/PayoutNotification.cs index bec68b5f7..df70ac3fe 100644 --- a/BTCPayServer/Services/Notifications/Blobs/PayoutNotification.cs +++ b/BTCPayServer/Services/Notifications/Blobs/PayoutNotification.cs @@ -20,7 +20,7 @@ namespace BTCPayServer.Services.Notifications.Blobs public override string NotificationType => "payout"; protected override void FillViewModel(PayoutNotification notification, NotificationViewModel vm) { - vm.Body = "A new payout is awaiting for payment"; + vm.Body = "A new payout is awaiting for approval"; vm.ActionLink = _linkGenerator.GetPathByAction(nameof(WalletsController.Payouts), "Wallets", new { walletId = new WalletId(notification.StoreId, notification.PaymentMethod) }, _options.RootPath); diff --git a/BTCPayServer/Services/Notifications/NotificationManager.cs b/BTCPayServer/Services/Notifications/NotificationManager.cs index b3965d524..36379732a 100644 --- a/BTCPayServer/Services/Notifications/NotificationManager.cs +++ b/BTCPayServer/Services/Notifications/NotificationManager.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Security.Claims; using System.Threading.Tasks; +using BTCPayServer.Components.NotificationsDropdown; using BTCPayServer.Data; using BTCPayServer.Models.NotificationViewModels; using Microsoft.AspNetCore.Identity; @@ -124,10 +125,4 @@ namespace BTCPayServer.Services.Notifications throw new InvalidOperationException($"No INotificationHandler found for {blobType.Name}"); } } - - public class NotificationSummaryViewModel - { - public int UnseenCount { get; set; } - public List Last5 { get; set; } - } } diff --git a/BTCPayServer/Views/Account/Login.cshtml b/BTCPayServer/Views/Account/Login.cshtml index fa3356075..61d30087f 100644 --- a/BTCPayServer/Views/Account/Login.cshtml +++ b/BTCPayServer/Views/Account/Login.cshtml @@ -29,7 +29,7 @@ @if (env.OnionUrl != null) {
- + Copy Tor URL diff --git a/BTCPayServer/Views/Account/Register.cshtml b/BTCPayServer/Views/Account/Register.cshtml index c50395687..6016cf658 100644 --- a/BTCPayServer/Views/Account/Register.cshtml +++ b/BTCPayServer/Views/Account/Register.cshtml @@ -33,7 +33,7 @@ @if (env.OnionUrl != null) {
- + Copy Tor URL diff --git a/BTCPayServer/Views/Home/RecoverySeedBackup.cshtml b/BTCPayServer/Views/Home/RecoverySeedBackup.cshtml index 519a3e53f..f9f12af33 100644 --- a/BTCPayServer/Views/Home/RecoverySeedBackup.cshtml +++ b/BTCPayServer/Views/Home/RecoverySeedBackup.cshtml @@ -46,7 +46,7 @@ Do not photograph it. Do not store it digitally.

- The recovery phrase will also be stored on a server as a hot wallet. + The recovery phrase will also be stored on the server as a hot wallet.

} else @@ -65,11 +65,18 @@

Please make sure to also write down your passphrase.

}
-
- - - - -
+ @if (Model.RequireConfirm) + { +
+ + + + +
+ } + else + { + Done + }
diff --git a/BTCPayServer/Views/Home/SwaggerDocs.cshtml b/BTCPayServer/Views/Home/SwaggerDocs.cshtml index 094eb643e..dfd5742c5 100644 --- a/BTCPayServer/Views/Home/SwaggerDocs.cshtml +++ b/BTCPayServer/Views/Home/SwaggerDocs.cshtml @@ -8,7 +8,8 @@ - + +