mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
fix(localisation): Localize request types in notifications (#4516)
[skip ci]
This commit is contained in:
parent
2ed8c48d12
commit
e09435da45
3 changed files with 40 additions and 1 deletions
27
src/Ombi.I18n/Resources/Texts.Designer.cs
generated
27
src/Ombi.I18n/Resources/Texts.Designer.cs
generated
|
@ -60,6 +60,15 @@ namespace Ombi.I18n.Resources {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Album.
|
||||
/// </summary>
|
||||
public static string Album {
|
||||
get {
|
||||
return ResourceManager.GetString("Album", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Type:.
|
||||
/// </summary>
|
||||
|
@ -87,6 +96,15 @@ namespace Ombi.I18n.Resources {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Movie.
|
||||
/// </summary>
|
||||
public static string Movie {
|
||||
get {
|
||||
return ResourceManager.GetString("Movie", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to New Albums.
|
||||
/// </summary>
|
||||
|
@ -132,6 +150,15 @@ namespace Ombi.I18n.Resources {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to TV Show.
|
||||
/// </summary>
|
||||
public static string TvShow {
|
||||
get {
|
||||
return ResourceManager.GetString("TvShow", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Unsubscribe.
|
||||
/// </summary>
|
||||
|
|
|
@ -144,4 +144,13 @@
|
|||
<data name="Unsubscribe" xml:space="preserve">
|
||||
<value>Unsubscribe</value>
|
||||
</data>
|
||||
<data name="Album" xml:space="preserve">
|
||||
<value>Album</value>
|
||||
</data>
|
||||
<data name="Movie" xml:space="preserve">
|
||||
<value>Movie</value>
|
||||
</data>
|
||||
<data name="TvShow" xml:space="preserve">
|
||||
<value>TV Show</value>
|
||||
</data>
|
||||
</root>
|
|
@ -4,6 +4,7 @@ using System.Linq;
|
|||
using System.Text;
|
||||
using Humanizer;
|
||||
using Ombi.Helpers;
|
||||
using Ombi.I18n.Resources;
|
||||
using Ombi.Notifications.Models;
|
||||
using Ombi.Settings.Settings.Models;
|
||||
using Ombi.Store.Entities;
|
||||
|
@ -192,7 +193,9 @@ namespace Ombi.Notifications
|
|||
return requestType switch
|
||||
{
|
||||
null => string.Empty,
|
||||
RequestType.TvShow => "TV Show",
|
||||
RequestType.TvShow => Texts.TvShow,
|
||||
RequestType.Album => Texts.Album,
|
||||
RequestType.Movie => Texts.Movie,
|
||||
_ => requestType.Humanize()
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue