diff --git a/BTCPayServer/Controllers/HomeController.cs b/BTCPayServer/Controllers/HomeController.cs index ff97a1be8..49e7036f1 100644 --- a/BTCPayServer/Controllers/HomeController.cs +++ b/BTCPayServer/Controllers/HomeController.cs @@ -12,7 +12,7 @@ namespace BTCPayServer.Controllers { public IActionResult Index() { - return View(); + return View("Home"); } public IActionResult About() diff --git a/BTCPayServer/Controllers/InvoiceController.UI.cs b/BTCPayServer/Controllers/InvoiceController.UI.cs index 70c46fe18..b25bff775 100644 --- a/BTCPayServer/Controllers/InvoiceController.UI.cs +++ b/BTCPayServer/Controllers/InvoiceController.UI.cs @@ -21,7 +21,7 @@ namespace BTCPayServer.Controllers [HttpGet] [Route("i/{invoiceId}")] [AcceptMediaTypeConstraint("application/bitcoin-paymentrequest", false)] - public async Task Payment(string invoiceId) + public async Task Checkout(string invoiceId) { var invoice = await _InvoiceRepository.GetInvoice(null, invoiceId); if(invoice == null) @@ -91,7 +91,7 @@ namespace BTCPayServer.Controllers [HttpGet] [Route("Invoices")] [BitpayAPIConstraint(false)] - public async Task Index(string searchTerm = null, int skip = 0, int count = 20) + public async Task ListInvoices(string searchTerm = null, int skip = 0, int count = 20) { var store = await FindStore(User); var model = new InvoicesModel(); @@ -150,7 +150,7 @@ namespace BTCPayServer.Controllers }, store); StatusMessage = $"Invoice {result.Data.Id} just created!"; - return RedirectToAction("Index"); + return RedirectToAction("ListInvoices"); } [HttpPost] diff --git a/BTCPayServer/Controllers/ManageController.cs b/BTCPayServer/Controllers/ManageController.cs index 1cce4ea62..032f55af2 100644 --- a/BTCPayServer/Controllers/ManageController.cs +++ b/BTCPayServer/Controllers/ManageController.cs @@ -382,12 +382,12 @@ namespace BTCPayServer.Controllers if(pairingCode != null && await _TokenRepository.PairWithAsync(pairingCode, store.Id)) { StatusMessage = "Pairing is successfull"; - return RedirectToAction(nameof(Tokens)); + return RedirectToAction(nameof(ListTokens)); } else { StatusMessage = "Pairing failed"; - return RedirectToAction(nameof(Tokens)); + return RedirectToAction(nameof(ListTokens)); } } @@ -528,7 +528,7 @@ namespace BTCPayServer.Controllers [HttpPost] [ValidateAntiForgeryToken] - public async Task AddToken(AddTokenViewModel model) + public async Task CreateToken(CreateTokenViewModel model) { if(!ModelState.IsValid) { @@ -542,7 +542,7 @@ namespace BTCPayServer.Controllers var link = pairing.CreateLink(url).ToString(); await _TokenRepository.PairWithAsync(pairing.ToString(), storeId); StatusMessage = "New access token paired to this store"; - return RedirectToAction("Tokens"); + return RedirectToAction(nameof(ListTokens)); } private async Task GetStoreId() @@ -556,9 +556,9 @@ namespace BTCPayServer.Controllers } [HttpGet] - public IActionResult AddToken() + public IActionResult CreateToken() { - var model = new AddTokenViewModel(); + var model = new CreateTokenViewModel(); model.Facade = "merchant"; if(_Env.IsDevelopment()) { @@ -572,11 +572,11 @@ namespace BTCPayServer.Controllers { await _TokenRepository.DeleteToken(sin, name); StatusMessage = "Token revoked"; - return RedirectToAction("Tokens"); + return RedirectToAction(nameof(ListTokens)); } [HttpGet] - public async Task Tokens() + public async Task ListTokens() { var model = new TokensViewModel(); var tokens = await _TokenRepository.GetTokensByPairedIdAsync(await GetStoreId()); diff --git a/BTCPayServer/Models/ManageViewModels/TokensViewModel.cs b/BTCPayServer/Models/ManageViewModels/TokensViewModel.cs index e1ad82490..619d563e7 100644 --- a/BTCPayServer/Models/ManageViewModels/TokensViewModel.cs +++ b/BTCPayServer/Models/ManageViewModels/TokensViewModel.cs @@ -7,7 +7,7 @@ using System.Threading.Tasks; namespace BTCPayServer.Models.ManageViewModels { - public class AddTokenViewModel + public class CreateTokenViewModel { [PubKeyValidatorAttribute] public string PublicKey diff --git a/BTCPayServer/Views/Home/Index.cshtml b/BTCPayServer/Views/Home/Home.cshtml similarity index 100% rename from BTCPayServer/Views/Home/Index.cshtml rename to BTCPayServer/Views/Home/Home.cshtml diff --git a/BTCPayServer/Views/Invoice/Payment.cshtml b/BTCPayServer/Views/Invoice/Checkout.cshtml similarity index 100% rename from BTCPayServer/Views/Invoice/Payment.cshtml rename to BTCPayServer/Views/Invoice/Checkout.cshtml diff --git a/BTCPayServer/Views/Invoice/Index.cshtml b/BTCPayServer/Views/Invoice/ListInvoices.cshtml similarity index 95% rename from BTCPayServer/Views/Invoice/Index.cshtml rename to BTCPayServer/Views/Invoice/ListInvoices.cshtml index f1d671204..f23664566 100644 --- a/BTCPayServer/Views/Invoice/Index.cshtml +++ b/BTCPayServer/Views/Invoice/ListInvoices.cshtml @@ -50,7 +50,7 @@ @invoice.InvoiceId @invoice.Status @invoice.AmountCurrency - Go to payment + Checkout } diff --git a/BTCPayServer/Views/Manage/AddToken.cshtml b/BTCPayServer/Views/Manage/CreateToken.cshtml similarity index 92% rename from BTCPayServer/Views/Manage/AddToken.cshtml rename to BTCPayServer/Views/Manage/CreateToken.cshtml index 45e99b88d..adf64aa93 100644 --- a/BTCPayServer/Views/Manage/AddToken.cshtml +++ b/BTCPayServer/Views/Manage/CreateToken.cshtml @@ -1,4 +1,4 @@ -@model AddTokenViewModel +@model CreateTokenViewModel @{ ViewData["Title"] = "Create a new token"; ViewData.AddActivePage(ManageNavPages.Tokens); @@ -8,7 +8,7 @@
-
+
diff --git a/BTCPayServer/Views/Manage/Tokens.cshtml b/BTCPayServer/Views/Manage/ListTokens.cshtml similarity index 87% rename from BTCPayServer/Views/Manage/Tokens.cshtml rename to BTCPayServer/Views/Manage/ListTokens.cshtml index a3cd2de2c..b8eb623c6 100644 --- a/BTCPayServer/Views/Manage/Tokens.cshtml +++ b/BTCPayServer/Views/Manage/ListTokens.cshtml @@ -9,7 +9,7 @@ @Html.Partial("_StatusMessage", Model.StatusMessage)
- Create a new token + Create a new token diff --git a/BTCPayServer/Views/Manage/_ManageNav.cshtml b/BTCPayServer/Views/Manage/_ManageNav.cshtml index d8e75ec99..10a38153c 100644 --- a/BTCPayServer/Views/Manage/_ManageNav.cshtml +++ b/BTCPayServer/Views/Manage/_ManageNav.cshtml @@ -7,7 +7,7 @@