mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-18 06:24:24 +01:00
More Translations (#6318)
* Store selector * Footer * Notifications * Checkout Appearance * Users list * Forms * Emails * Pay Button * Edit Dictionary * Remove newlines, fix typos * Forms * Pull payments and payouts * Various pages * Use local docs link * Fix * Even more translations * Fixes #6325 * Account pages * Notifications * Placeholders * Various pages and components * Add more
This commit is contained in:
@@ -3,6 +3,7 @@ using BTCPayServer.Configuration;
|
||||
using BTCPayServer.Controllers;
|
||||
using BTCPayServer.Data;
|
||||
using Microsoft.AspNetCore.Routing;
|
||||
using Microsoft.Extensions.Localization;
|
||||
|
||||
namespace BTCPayServer.Services.Notifications.Blobs;
|
||||
|
||||
@@ -28,15 +29,16 @@ internal class InviteAcceptedNotification : BaseNotification
|
||||
StoreName = store.StoreName;
|
||||
}
|
||||
|
||||
internal class Handler(LinkGenerator linkGenerator, BTCPayServerOptions options)
|
||||
internal class Handler(LinkGenerator linkGenerator, BTCPayServerOptions options, IStringLocalizer stringLocalizer)
|
||||
: NotificationHandler<InviteAcceptedNotification>
|
||||
{
|
||||
private IStringLocalizer StringLocalizer { get; } = stringLocalizer;
|
||||
public override string NotificationType => TYPE;
|
||||
public override (string identifier, string name)[] Meta
|
||||
{
|
||||
get
|
||||
{
|
||||
return [(TYPE, "User accepted invitation")];
|
||||
return [(TYPE, StringLocalizer["User accepted invitation"])];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,7 +47,7 @@ internal class InviteAcceptedNotification : BaseNotification
|
||||
vm.Identifier = notification.Identifier;
|
||||
vm.Type = notification.NotificationType;
|
||||
vm.StoreId = notification.StoreId;
|
||||
vm.Body = $"User {notification.UserEmail} accepted the invite to {notification.StoreName}.";
|
||||
vm.Body = StringLocalizer["User {0} accepted the invite to {1}.", notification.UserEmail, notification.StoreName];
|
||||
vm.ActionLink = linkGenerator.GetPathByAction(nameof(UIStoresController.StoreUsers),
|
||||
"UIStores",
|
||||
new { storeId = notification.StoreId }, options.RootPath);
|
||||
|
||||
Reference in New Issue
Block a user