add translation for webfront
discord link has been genericized to social link
This commit is contained in:
parent
e8dff01c41
commit
a54ea3913d
@ -72,6 +72,15 @@
|
|||||||
<None Update="Localization\IW4MAdmin.ru-RU.json">
|
<None Update="Localization\IW4MAdmin.ru-RU.json">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</None>
|
</None>
|
||||||
|
<None Update="Localization\Webfront.ru-RU.json">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
<None Update="Localization\Webfront.es-EC.json">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
<None Update="Localization\Webfront.en-US.json">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@ -20,8 +20,9 @@
|
|||||||
"SETUP_ENCODING_STRING": "Enter encoding string",
|
"SETUP_ENCODING_STRING": "Enter encoding string",
|
||||||
"SETUP_ENABLE_VPNS": "Enable client VPNs",
|
"SETUP_ENABLE_VPNS": "Enable client VPNs",
|
||||||
"SETUP_IPHUB_KEY": "Enter iphub.info api key",
|
"SETUP_IPHUB_KEY": "Enter iphub.info api key",
|
||||||
"SETUP_DISPLAY_DISCORD": "Display discord link on webfront",
|
"SETUP_DISPLAY_SOCIAL": "Display social media link on webfront (discord, website, VK, etc..)",
|
||||||
"SETUP_DISCORD_INVITE": "Enter discord invite link",
|
"SETUP_SOCIAL_LINK": "Enter social media link",
|
||||||
|
"SETUP_SOCIAL_TITLE": "Enter social media name",
|
||||||
"SETUP_SERVER_USET6M": "Use Pluto T6 parser",
|
"SETUP_SERVER_USET6M": "Use Pluto T6 parser",
|
||||||
"SETUP_SERVER_USEIW5M": "Use Pluto IW5 Parser",
|
"SETUP_SERVER_USEIW5M": "Use Pluto IW5 Parser",
|
||||||
"SETUP_SERVER_MANUALLOG": "Enter manual log file path",
|
"SETUP_SERVER_MANUALLOG": "Enter manual log file path",
|
||||||
|
@ -20,8 +20,9 @@
|
|||||||
"SETUP_ENCODING_STRING": "Ingresar cadena de codificación",
|
"SETUP_ENCODING_STRING": "Ingresar cadena de codificación",
|
||||||
"SETUP_ENABLE_VPNS": "Habilitar VPNs clientes",
|
"SETUP_ENABLE_VPNS": "Habilitar VPNs clientes",
|
||||||
"SETUP_IPHUB_KEY": "Ingresar clave api de iphub.info",
|
"SETUP_IPHUB_KEY": "Ingresar clave api de iphub.info",
|
||||||
"SETUP_DISPLAY_DISCORD": "Mostrar link de Discord en frente de la web",
|
"SETUP_DISPLAY_SOCIAL": "Mostrar el link del medio de comunicación en la parte frontal de la web. (discord, website, VK, etc..)",
|
||||||
"SETUP_DISCORD_INVITE": "Ingresar link de invitación a discord",
|
"SETUP_SOCIAL_LINK": "Ingresar link del medio de comunicación",
|
||||||
|
"SETUP_SOCIAL_TITLE": "Ingresa el nombre de la red de comunicación",
|
||||||
"SETUP_SERVER_USET6M": "Usar analizador Pluto T6",
|
"SETUP_SERVER_USET6M": "Usar analizador Pluto T6",
|
||||||
"SETUP_SERVER_USEIW5M": "Usar analizador Pluto IW5",
|
"SETUP_SERVER_USEIW5M": "Usar analizador Pluto IW5",
|
||||||
"SETUP_SERVER_MANUALLOG": "Ingresar manualmente la ruta del archivo de registro",
|
"SETUP_SERVER_MANUALLOG": "Ingresar manualmente la ruta del archivo de registro",
|
||||||
|
@ -17,8 +17,9 @@
|
|||||||
"SETUP_ENCODING_STRING": "Введите кодировку",
|
"SETUP_ENCODING_STRING": "Введите кодировку",
|
||||||
"SETUP_ENABLE_VPNS": "Включить поддержку VPN у игроков",
|
"SETUP_ENABLE_VPNS": "Включить поддержку VPN у игроков",
|
||||||
"SETUP_IPHUB_KEY": "Введите iphub.info api-ключ",
|
"SETUP_IPHUB_KEY": "Введите iphub.info api-ключ",
|
||||||
"SETUP_DISPLAY_DISCORD": "Отображать ссылку на Discord в веб-интерфейсе",
|
"SETUP_DISPLAY_SOCIAL": "Отображать ссылку на социальную сеть в веб-интерфейсе (Discord, веб-сайт, ВК, и т.д.)",
|
||||||
"SETUP_DISCORD_INVITE": "Введите ссылку-приглашение в Discord",
|
"SETUP_SOCIAL_LINK": "Ввести ссылку на социальную сеть",
|
||||||
|
"SETUP_SOCIAL_TITLE": "Ввести имя социальной сети",
|
||||||
"SETUP_SERVER_USET6M": "Использовать Pluto T6 парсер",
|
"SETUP_SERVER_USET6M": "Использовать Pluto T6 парсер",
|
||||||
"SETUP_SERVER_USEIW5M": "Использовать парсер Pluto IW5",
|
"SETUP_SERVER_USEIW5M": "Использовать парсер Pluto IW5",
|
||||||
"SETUP_SERVER_MANUALLOG": "Введите путь для лог-файла",
|
"SETUP_SERVER_MANUALLOG": "Введите путь для лог-файла",
|
||||||
|
50
Application/Localization/Webfront.en-US.json
Normal file
50
Application/Localization/Webfront.en-US.json
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
{
|
||||||
|
"LocalizationName": "en-US",
|
||||||
|
"LocalizationIndex": {
|
||||||
|
"Set": {
|
||||||
|
"WEBFRONT_ACTION_BAN_NAME": "Ban",
|
||||||
|
"WEBFRONT_ACTION_LABEL_REASON": "Reason",
|
||||||
|
"WEBFRONT_ACTION_UNBAN_NAME": "Unban",
|
||||||
|
"WEBFRONT_ACTION_LOGIN_NAME": "Login",
|
||||||
|
"WEBFRONT_ACTION_LABEL_ID": "Client ID",
|
||||||
|
"WEBFRONT_ACTION_LABEL_PASSWORD": "Password",
|
||||||
|
"WEBFRONT_CLIENT_META_MASKED": "Masked",
|
||||||
|
"WEBFRONT_CLIENT_META_TRUE": "Is",
|
||||||
|
"WEBFRONT_CLIENT_META_FALSE": "Is not",
|
||||||
|
"WEBFRONT_CLIENT_META_JOINED": "Joined with alias",
|
||||||
|
"WEBFRONT_CLIENT_PROFILE_TITLE": "Profile",
|
||||||
|
"WEBFRONT_CLIENT_PRIVILEGED_TITLE": "Privileged Clients",
|
||||||
|
"WEBFRONT_CLIENT_SEARCH_MATCHING": "Clients Matching",
|
||||||
|
"WEBFRONT_CONSOLE_TITLE": "Web Console",
|
||||||
|
"WEBFRONT_HOME_TITLE": "Server Overview",
|
||||||
|
"WEBFRONT_ERROR_DESC": "IW4MAdmin encountered an error",
|
||||||
|
"WEBFRONT_ERROR_TITLE": "Error!",
|
||||||
|
"WEBFRONT_PENALTY_TITLE": "Client Penalties",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_NAME": "Name",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TYPE": "Type",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_OFFENSE": "Offense",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_ADMIN": "Admin",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TIME": "Time/Left",
|
||||||
|
"WEBFRONT_PROFILE_PLAYER": "Played",
|
||||||
|
"WEBFRONT_PROFILE_FSEEN": "First seen",
|
||||||
|
"WEBFRONT_PROFILE_LSEEN": "Last seen",
|
||||||
|
"WEBFRONT_PROFILE_LEVEL": "Level",
|
||||||
|
"WEBFRONT_CONSOLE_EXECUTE": "Execute",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_TITLE": "Sorry!",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_DESC": "An error occurred while processing your request",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_AGO": "ago",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_REMAINING": "left",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOW": "Show",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOWONLY": "Show only",
|
||||||
|
"WEBFRONT_NAV_HOME": "Home",
|
||||||
|
"WEBFRONT_NAV_PENALTIES": "Penalties",
|
||||||
|
"WEBFRONT_NAV_PRIVILEGED": "Admins",
|
||||||
|
"WEBFRONT_NAV_SOCIAL": "Social",
|
||||||
|
"WEBFRONT_NAV_DISCORD": "Discord",
|
||||||
|
"WEBFRONT_NAV_CONSOLE": "Console",
|
||||||
|
"WEBFRONT_NAV_PROFILE": "Client Profile",
|
||||||
|
"WEBFRONT_NAV_LOGOUT": "Logout",
|
||||||
|
"WEBFRONT_NAV_SEARCH": "Find Client"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
50
Application/Localization/Webfront.es-EC.json
Normal file
50
Application/Localization/Webfront.es-EC.json
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
{
|
||||||
|
"LocalizationName": "es-BR",
|
||||||
|
"LocalizationIndex": {
|
||||||
|
"Set": {
|
||||||
|
"WEBFRONT_ACTION_BAN_NAME": "Ban",
|
||||||
|
"WEBFRONT_ACTION_LABEL_REASON": "Razón",
|
||||||
|
"WEBFRONT_ACTION_UNBAN_NAME": "Desban",
|
||||||
|
"WEBFRONT_ACTION_LOGIN_NAME": "Inicio de sesión",
|
||||||
|
"WEBFRONT_ACTION_LABEL_ID": "ID del Cliente",
|
||||||
|
"WEBFRONT_ACTION_LABEL_PASSWORD": "Contraseña",
|
||||||
|
"WEBFRONT_CLIENT_META_MASKED": "Enmascarado",
|
||||||
|
"WEBFRONT_CLIENT_META_TRUE": "Está",
|
||||||
|
"WEBFRONT_CLIENT_META_FALSE": "No está",
|
||||||
|
"WEBFRONT_CLIENT_META_JOINED": "Se unió con el alias",
|
||||||
|
"WEBFRONT_CLIENT_PROFILE_TITLE": "Perfil",
|
||||||
|
"WEBFRONT_CLIENT_PRIVILEGED_TITLE": "Clientes privilegiados",
|
||||||
|
"WEBFRONT_CLIENT_SEARCH_MATCHING": "Clientes que concuerdan",
|
||||||
|
"WEBFRONT_CONSOLE_TITLE": "Consola Web",
|
||||||
|
"WEBFRONT_HOME_TITLE": "Vista general del servidor",
|
||||||
|
"WEBFRONT_ERROR_DESC": "IW4MAdmin encontró",
|
||||||
|
"WEBFRONT_ERROR_TITLE": "¡Error!",
|
||||||
|
"WEBFRONT_PENALTY_TITLE": "Faltas del cliente",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_NAME": "Nombre",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TYPE": "Tipo",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_OFFENSE": "Ofensa",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_ADMIN": "Administrador",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TIME": "Tiempo/Restante",
|
||||||
|
"WEBFRONT_PROFILE_PLAYER": "Jugadas",
|
||||||
|
"WEBFRONT_PROFILE_FSEEN": "Primera vez visto hace",
|
||||||
|
"WEBFRONT_PROFILE_LSEEN": "Última vez visto hace",
|
||||||
|
"WEBFRONT_PROFILE_LEVEL": "Nivel",
|
||||||
|
"WEBFRONT_CONSOLE_EXECUTE": "Ejecutar",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_TITLE": "¡Lo lamento!",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_DESC": "Un error ha ocurrido mientras se procesaba tu solicitud",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_AGO": "atrás",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_REMAINING": "restante",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOW": "Mostrar",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOWONLY": "Mostrar solamente",
|
||||||
|
"WEBFRONT_NAV_HOME": "Inicio",
|
||||||
|
"WEBFRONT_NAV_PENALTIES": "Sanciones",
|
||||||
|
"WEBFRONT_NAV_PRIVILEGED": "Administradores",
|
||||||
|
"WEBFRONT_NAV_SOCIAL": "Social",
|
||||||
|
"WEBFRONT_NAV_DISCORD": "Discord",
|
||||||
|
"WEBFRONT_NAV_CONSOLE": "Consola",
|
||||||
|
"WEBFRONT_NAV_PROFILE": "Perfil del cliente",
|
||||||
|
"WEBFRONT_NAV_LOGOUT": "Cerrar sesión",
|
||||||
|
"WEBFRONT_NAV_SEARCH": "Encontrar cliente"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
50
Application/Localization/Webfront.ru-RU.json
Normal file
50
Application/Localization/Webfront.ru-RU.json
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
{
|
||||||
|
"LocalizationName": "en-US",
|
||||||
|
"LocalizationIndex": {
|
||||||
|
"Set": {
|
||||||
|
"WEBFRONT_ACTION_BAN_NAME": "Забанить",
|
||||||
|
"WEBFRONT_ACTION_LABEL_REASON": "Причина",
|
||||||
|
"WEBFRONT_ACTION_UNBAN_NAME": "Разбанить",
|
||||||
|
"WEBFRONT_ACTION_LOGIN_NAME": "Войти",
|
||||||
|
"WEBFRONT_ACTION_LABEL_ID": "ID клиента",
|
||||||
|
"WEBFRONT_ACTION_LABEL_PASSWORD": "Пароль",
|
||||||
|
"WEBFRONT_CLIENT_META_MASKED": "Замаскирован",
|
||||||
|
"WEBFRONT_CLIENT_META_TRUE": "",
|
||||||
|
"WEBFRONT_CLIENT_META_FALSE": "не",
|
||||||
|
"WEBFRONT_CLIENT_META_JOINED": "Присоединился с именем",
|
||||||
|
"WEBFRONT_CLIENT_PROFILE_TITLE": "Профиль",
|
||||||
|
"WEBFRONT_CLIENT_PRIVILEGED_TITLE": "Клиенты с правами",
|
||||||
|
"WEBFRONT_CLIENT_SEARCH_MATCHING": "Подходящие клиенты",
|
||||||
|
"WEBFRONT_CONSOLE_TITLE": "Веб-консоль",
|
||||||
|
"WEBFRONT_HOME_TITLE": "Обзор сервера",
|
||||||
|
"WEBFRONT_ERROR_DESC": "IW4MAdmin столкнулся с ошибкой",
|
||||||
|
"WEBFRONT_ERROR_TITLE": "Ошибка!",
|
||||||
|
"WEBFRONT_PENALTY_TITLE": "Наказания клиентов",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_NAME": "Имя",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TYPE": "Тип",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_OFFENSE": "Нарушение",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_ADMIN": "Админ",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_TIME": "Время/Осталось",
|
||||||
|
"WEBFRONT_PROFILE_PLAYER": "Наиграл",
|
||||||
|
"WEBFRONT_PROFILE_FSEEN": "Впервые заходил",
|
||||||
|
"WEBFRONT_PROFILE_LSEEN": "Последний раз заходил",
|
||||||
|
"WEBFRONT_PROFILE_LEVEL": "Уровень",
|
||||||
|
"WEBFRONT_CONSOLE_EXECUTE": "Выполнить",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_TITLE": "Извините!",
|
||||||
|
"WEBFRONT_ERROR_GENERIC_DESC": "Произошла ошибка во время обработки вашего запроса",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_AGO": "назад",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_REMAINING": "осталось",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOW": "Показывать",
|
||||||
|
"WEBFRONT_PENALTY_TEMPLATE_SHOWONLY": "Показывать только",
|
||||||
|
"WEBFRONT_NAV_HOME": "Домой",
|
||||||
|
"WEBFRONT_NAV_PENALTIES": "Наказания",
|
||||||
|
"WEBFRONT_NAV_PRIVILEGED": "Админы",
|
||||||
|
"WEBFRONT_NAV_SOCIAL": "Соц. сети",
|
||||||
|
"WEBFRONT_NAV_DISCORD": "Discord",
|
||||||
|
"WEBFRONT_NAV_CONSOLE": "Консоль",
|
||||||
|
"WEBFRONT_NAV_PROFILE": "Профиль клиента",
|
||||||
|
"WEBFRONT_NAV_LOGOUT": "Выйти",
|
||||||
|
"WEBFRONT_NAV_SEARCH": "Найти клиента"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -15,6 +15,7 @@ namespace SharedLibraryCore.Configuration
|
|||||||
public bool EnableCustomSayName { get; set; }
|
public bool EnableCustomSayName { get; set; }
|
||||||
public string CustomSayName { get; set; }
|
public string CustomSayName { get; set; }
|
||||||
public string DiscordInviteCode { get; set; }
|
public string DiscordInviteCode { get; set; }
|
||||||
|
public string SocialLinkTitle { get; set; }
|
||||||
public string IPHubAPIKey { get; set; }
|
public string IPHubAPIKey { get; set; }
|
||||||
public string WebfrontBindUrl { get; set; }
|
public string WebfrontBindUrl { get; set; }
|
||||||
public string CustomParserEncoding { get; set; }
|
public string CustomParserEncoding { get; set; }
|
||||||
@ -51,10 +52,13 @@ namespace SharedLibraryCore.Configuration
|
|||||||
if (!EnableClientVPNs)
|
if (!EnableClientVPNs)
|
||||||
IPHubAPIKey = Utilities.PromptString(loc["SETUP_IPHUB_KEY"]);
|
IPHubAPIKey = Utilities.PromptString(loc["SETUP_IPHUB_KEY"]);
|
||||||
|
|
||||||
EnableDiscordLink = Utilities.PromptBool(loc["SETUP_DISPLAY_DISCORD"]);
|
EnableDiscordLink = Utilities.PromptBool(loc["SETUP_DISPLAY_SOCIAL"]);
|
||||||
|
|
||||||
if (EnableDiscordLink)
|
if (EnableDiscordLink)
|
||||||
DiscordInviteCode = Utilities.PromptString(loc["SETUP_DISCORD_INVITE"]);
|
{
|
||||||
|
SocialLinkTitle = Utilities.PromptString(loc["SETUP_SOCIAL_TITLE"]);
|
||||||
|
DiscordInviteCode = Utilities.PromptString(loc["SETUP_SOCIAL_LINK"]);
|
||||||
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
@ -210,27 +210,27 @@ namespace SharedLibraryCore
|
|||||||
public static String GetTimePassed(DateTime start, bool includeAgo)
|
public static String GetTimePassed(DateTime start, bool includeAgo)
|
||||||
{
|
{
|
||||||
TimeSpan Elapsed = DateTime.UtcNow - start;
|
TimeSpan Elapsed = DateTime.UtcNow - start;
|
||||||
string ago = includeAgo ? " ago" : "";
|
string ago = includeAgo ? " " + CurrentLocalization.LocalizationIndex["WEBFRONT_PENALTY_TEMPLATE_AGO"] : "";
|
||||||
|
|
||||||
if (Elapsed.TotalSeconds < 30 && includeAgo)
|
if (Elapsed.TotalSeconds < 30 && includeAgo)
|
||||||
return "just now";
|
return "just now";
|
||||||
if (Elapsed.TotalMinutes < 120)
|
if (Elapsed.TotalMinutes < 120)
|
||||||
{
|
{
|
||||||
if (Elapsed.TotalMinutes < 1.5)
|
if (Elapsed.TotalMinutes < 1.5)
|
||||||
return $"1 minute{ago}";
|
return $"1 {CurrentLocalization.LocalizationIndex["GLOBAL_MINUTES"]}{ago}";
|
||||||
return Math.Round(Elapsed.TotalMinutes, 0) + $" minutes{ago}";
|
return Math.Round(Elapsed.TotalMinutes, 0) + $" {CurrentLocalization.LocalizationIndex["GLOBAL_MINUTES"]}{ago}";
|
||||||
}
|
}
|
||||||
if (Elapsed.TotalHours <= 24)
|
if (Elapsed.TotalHours <= 24)
|
||||||
{
|
{
|
||||||
if (Elapsed.TotalHours < 1.5)
|
if (Elapsed.TotalHours < 1.5)
|
||||||
return $"1 hour{ago}";
|
return $"1 {CurrentLocalization.LocalizationIndex["GLOBAL_HOURS"]}{ago}";
|
||||||
return Math.Round(Elapsed.TotalHours, 0) + $" hours{ago}";
|
return Math.Round(Elapsed.TotalHours, 0) + $" { CurrentLocalization.LocalizationIndex["GLOBAL_HOURS"]}{ago}";
|
||||||
}
|
}
|
||||||
if (Elapsed.TotalDays <= 365)
|
if (Elapsed.TotalDays <= 365)
|
||||||
{
|
{
|
||||||
if (Elapsed.TotalDays < 1.5)
|
if (Elapsed.TotalDays < 1.5)
|
||||||
return $"1 day{ago}";
|
return $"1 {CurrentLocalization.LocalizationIndex["GLOBAL_DAYS"]}{ago}";
|
||||||
return Math.Round(Elapsed.TotalDays, 0) + $" days{ago}";
|
return Math.Round(Elapsed.TotalDays, 0) + $" {CurrentLocalization.LocalizationIndex["GLOBAL_DAYS"]}{ago}";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return $"a very long time{ago}";
|
return $"a very long time{ago}";
|
||||||
|
@ -83,12 +83,12 @@ namespace WebfrontCore.Controllers
|
|||||||
new InputInfo()
|
new InputInfo()
|
||||||
{
|
{
|
||||||
Name = "clientId",
|
Name = "clientId",
|
||||||
Label = "Client ID"
|
Label = Localization["WEBFRONT_ACTION_LABEL_ID"]
|
||||||
},
|
},
|
||||||
new InputInfo()
|
new InputInfo()
|
||||||
{
|
{
|
||||||
Name = "Password",
|
Name = "Password",
|
||||||
Label ="Password",
|
Label = Localization["WEBFRONT_ACTION_LABEL_PASSWORD"],
|
||||||
Type = "password",
|
Type = "password",
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -20,18 +20,21 @@ namespace WebfrontCore.Controllers
|
|||||||
protected SharedLibraryCore.Localization.Index Localization { get; private set; }
|
protected SharedLibraryCore.Localization.Index Localization { get; private set; }
|
||||||
protected EFClient Client { get; private set; }
|
protected EFClient Client { get; private set; }
|
||||||
private static byte[] LocalHost = { 127, 0, 0, 1 };
|
private static byte[] LocalHost = { 127, 0, 0, 1 };
|
||||||
private static string DiscordLink;
|
private static string SocialLink;
|
||||||
|
private static string SocialTitle;
|
||||||
|
|
||||||
public BaseController()
|
public BaseController()
|
||||||
{
|
{
|
||||||
Manager = Program.Manager;
|
if (Manager == null)
|
||||||
if (Manager.GetApplicationSettings().Configuration().EnableDiscordLink)
|
Manager = Program.Manager;
|
||||||
|
|
||||||
|
if (Localization == null)
|
||||||
|
Localization = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
|
|
||||||
|
if (Manager.GetApplicationSettings().Configuration().EnableDiscordLink && SocialLink == null)
|
||||||
{
|
{
|
||||||
string inviteLink = Manager.GetApplicationSettings().Configuration().DiscordInviteCode;
|
SocialLink = Manager.GetApplicationSettings().Configuration().DiscordInviteCode;
|
||||||
if (inviteLink != null)
|
SocialTitle = Manager.GetApplicationSettings().Configuration().SocialLinkTitle;
|
||||||
DiscordLink = inviteLink.Contains("https") ? inviteLink : $"https://discordapp.com/invite/{inviteLink}";
|
|
||||||
else
|
|
||||||
DiscordLink = "";
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -83,7 +86,8 @@ namespace WebfrontCore.Controllers
|
|||||||
ViewBag.Authorized = Authorized;
|
ViewBag.Authorized = Authorized;
|
||||||
ViewBag.Url = Manager.GetApplicationSettings().Configuration().WebfrontBindUrl;
|
ViewBag.Url = Manager.GetApplicationSettings().Configuration().WebfrontBindUrl;
|
||||||
ViewBag.User = Client;
|
ViewBag.User = Client;
|
||||||
ViewBag.DiscordLink = DiscordLink ?? "";
|
ViewBag.SocialLink = SocialLink ?? "";
|
||||||
|
ViewBag.SocialTitle = SocialTitle;
|
||||||
|
|
||||||
base.OnActionExecuting(context);
|
base.OnActionExecuting(context);
|
||||||
}
|
}
|
||||||
|
@ -53,8 +53,8 @@ namespace WebfrontCore.Controllers
|
|||||||
if (Authorized && client.Level > SharedLibraryCore.Objects.Player.Permission.Trusted)
|
if (Authorized && client.Level > SharedLibraryCore.Objects.Player.Permission.Trusted)
|
||||||
clientDto.Meta.Add(new ProfileMeta()
|
clientDto.Meta.Add(new ProfileMeta()
|
||||||
{
|
{
|
||||||
Key = "Masked",
|
Key = Localization["WEBFRONT_CLIENT_META_MASKED"],
|
||||||
Value = client.Masked ? "Is" : "Is not",
|
Value = client.Masked ? Localization["WEBFRONT_CLIENT_META_TRUE"]: Localization["WEBFRONT_CLIENT_META_FALSE"],
|
||||||
Sensitive = true,
|
Sensitive = true,
|
||||||
When = DateTime.MinValue
|
When = DateTime.MinValue
|
||||||
});
|
});
|
||||||
@ -67,7 +67,7 @@ namespace WebfrontCore.Controllers
|
|||||||
.Select(a => new ProfileMeta()
|
.Select(a => new ProfileMeta()
|
||||||
{
|
{
|
||||||
Key = "AliasEvent",
|
Key = "AliasEvent",
|
||||||
Value = $"Joined with alias {a.Name}",
|
Value = $"{Localization["WEBFRONT_CLIENT_META_JOINED"]} {a.Name}",
|
||||||
Sensitive = true,
|
Sensitive = true,
|
||||||
When = a.DateAdded
|
When = a.DateAdded
|
||||||
}));
|
}));
|
||||||
@ -83,7 +83,7 @@ namespace WebfrontCore.Controllers
|
|||||||
ViewBag.Title = clientDto.Name.Substring(clientDto.Name.Length - 1).ToLower()[0] == 's' ?
|
ViewBag.Title = clientDto.Name.Substring(clientDto.Name.Length - 1).ToLower()[0] == 's' ?
|
||||||
clientDto.Name + "'" :
|
clientDto.Name + "'" :
|
||||||
clientDto.Name + "'s";
|
clientDto.Name + "'s";
|
||||||
ViewBag.Title += " Profile";
|
ViewBag.Title += " " + Localization["WEBFRONT_CLIENT_PROFILE_TITLE"];
|
||||||
ViewBag.Description = $"Client information for {clientDto.Name}";
|
ViewBag.Description = $"Client information for {clientDto.Name}";
|
||||||
ViewBag.Keywords = $"IW4MAdmin, client, profile, {clientDto.Name}";
|
ViewBag.Keywords = $"IW4MAdmin, client, profile, {clientDto.Name}";
|
||||||
|
|
||||||
@ -109,7 +109,7 @@ namespace WebfrontCore.Controllers
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
ViewBag.Title = "Privileged Clients";
|
ViewBag.Title = Localization["WEBFRONT_CLIENT_PRIVILEGED_TITLE"];
|
||||||
ViewBag.Description = "List of all privileged clients on IW4MAdmin";
|
ViewBag.Description = "List of all privileged clients on IW4MAdmin";
|
||||||
ViewBag.Keywords = "IW4MAdmin, privileged, admins, clients, administrators";
|
ViewBag.Keywords = "IW4MAdmin, privileged, admins, clients, administrators";
|
||||||
|
|
||||||
@ -131,7 +131,7 @@ namespace WebfrontCore.Controllers
|
|||||||
})
|
})
|
||||||
.ToList();
|
.ToList();
|
||||||
|
|
||||||
ViewBag.Title = $"{clientsDto.Count} Clients Matching \"{clientName}\"";
|
ViewBag.Title = $"{clientsDto.Count} {Localization["WEBFRONT_CLIENT_SEARCH_MATCHING"]} \"{clientName}\"";
|
||||||
return View("Find/Index", clientsDto);
|
return View("Find/Index", clientsDto);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,7 @@ namespace WebfrontCore.Controllers
|
|||||||
});
|
});
|
||||||
|
|
||||||
ViewBag.Description = "Use the IW4MAdmin web console to execute commands";
|
ViewBag.Description = "Use the IW4MAdmin web console to execute commands";
|
||||||
ViewBag.Title = "Web Console";
|
ViewBag.Title = Localization["WEBFRONT_CONSOLE_TITLE"];
|
||||||
ViewBag.Keywords = "IW4MAdmin, console, execute, commands";
|
ViewBag.Keywords = "IW4MAdmin, console, execute, commands";
|
||||||
|
|
||||||
return View(activeServers);
|
return View(activeServers);
|
||||||
|
@ -13,7 +13,7 @@ namespace WebfrontCore.Controllers
|
|||||||
public IActionResult Index()
|
public IActionResult Index()
|
||||||
{
|
{
|
||||||
ViewBag.Description = "IW4MAdmin is a complete server administration tool for IW4x.";
|
ViewBag.Description = "IW4MAdmin is a complete server administration tool for IW4x.";
|
||||||
ViewBag.Title = "Server Overview";
|
ViewBag.Title = Localization["WEBFRONT_HOME_TITLE"];
|
||||||
ViewBag.Keywords = "IW4MAdmin, server, administration, IW4x, MW2, Modern Warfare 2";
|
ViewBag.Keywords = "IW4MAdmin, server, administration, IW4x, MW2, Modern Warfare 2";
|
||||||
|
|
||||||
return View();
|
return View();
|
||||||
@ -21,8 +21,8 @@ namespace WebfrontCore.Controllers
|
|||||||
|
|
||||||
public IActionResult Error()
|
public IActionResult Error()
|
||||||
{
|
{
|
||||||
ViewBag.Description = "IW4MAdmin encountered an error";
|
ViewBag.Description = Localization["WEBFRONT_ERROR_DESC"];
|
||||||
ViewBag.Title = "Error!";
|
ViewBag.Title = Localization["WEBFRONT_ERROR_TITLE"];
|
||||||
return View();
|
return View();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ namespace WebfrontCore.Controllers
|
|||||||
public IActionResult List(int showOnly = (int)SharedLibraryCore.Objects.Penalty.PenaltyType.Any)
|
public IActionResult List(int showOnly = (int)SharedLibraryCore.Objects.Penalty.PenaltyType.Any)
|
||||||
{
|
{
|
||||||
ViewBag.Description = "List of all the recent penalties (bans, kicks, warnings) on IW4MAdmin";
|
ViewBag.Description = "List of all the recent penalties (bans, kicks, warnings) on IW4MAdmin";
|
||||||
ViewBag.Title = "Client Penalties";
|
ViewBag.Title = Localization["WEBFRONT_PENALTY_TITLE"];
|
||||||
ViewBag.Keywords = "IW4MAdmin, penalties, ban, kick, warns";
|
ViewBag.Keywords = "IW4MAdmin, penalties, ban, kick, warns";
|
||||||
|
|
||||||
return View((SharedLibraryCore.Objects.Penalty.PenaltyType)showOnly);
|
return View((SharedLibraryCore.Objects.Penalty.PenaltyType)showOnly);
|
||||||
|
@ -1,11 +1,14 @@
|
|||||||
@model List<SharedLibraryCore.Dtos.PlayerInfo>
|
@model List<SharedLibraryCore.Dtos.PlayerInfo>
|
||||||
|
@{
|
||||||
|
var loc = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
|
}
|
||||||
|
|
||||||
<div class="mr-auto ml-auto col-12 col-lg-7 border-bottom">
|
<div class="mr-auto ml-auto col-12 col-lg-7 border-bottom">
|
||||||
<h4 class="pb-2 text-center ">@ViewBag.Title</h4>
|
<h4 class="pb-2 text-center ">@ViewBag.Title</h4>
|
||||||
<div class="row pt-2 pb-2 bg-primary">
|
<div class="row pt-2 pb-2 bg-primary">
|
||||||
<div class="col-5 ">Name </div>
|
<div class="col-5 ">@loc["WEBFRONT_PENALTY_TEMPLATE_NAME"]</div>
|
||||||
<div class="col-4">Level</div>
|
<div class="col-4">@loc["WEBFRONT_PROFILE_LEVEL"]</div>
|
||||||
<div class="col-3 text-right">Last Seen</div>
|
<div class="col-3 text-right">@loc["WEBFRONT_PROFILE_LSEEN"]</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@{
|
@{
|
||||||
@ -14,7 +17,7 @@
|
|||||||
<div class="row pt-2 pb-2 bg-dark">
|
<div class="row pt-2 pb-2 bg-dark">
|
||||||
<div class="col-5">@Html.ActionLink(client.Name, "ProfileAsync", "Client", new { id = client.ClientId })</div>
|
<div class="col-5">@Html.ActionLink(client.Name, "ProfileAsync", "Client", new { id = client.ClientId })</div>
|
||||||
<div class="col-4 level-color-@client.Level.ToLower()">@client.Level</div>
|
<div class="col-4 level-color-@client.Level.ToLower()">@client.Level</div>
|
||||||
<div class="col-3 text-right">@client.LastSeen ago</div>
|
<div class="col-3 text-right">@client.LastSeen @loc["WEBFRONT_PENALTY_TEMPLATE_AGO"]</div>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
@{
|
@{
|
||||||
string match = System.Text.RegularExpressions.Regex.Match(Model.Name.ToUpper(), "[A-Z]").Value;
|
string match = System.Text.RegularExpressions.Regex.Match(Model.Name.ToUpper(), "[A-Z]").Value;
|
||||||
string shortCode = match == string.Empty ? "?" : match;
|
string shortCode = match == string.Empty ? "?" : match;
|
||||||
|
var loc = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
}
|
}
|
||||||
<div id="profile_wrapper" class="row d-flex d-sm-inline-flex justify-content-center justify-content-left pb-3">
|
<div id="profile_wrapper" class="row d-flex d-sm-inline-flex justify-content-center justify-content-left pb-3">
|
||||||
<div class="mr-auto ml-auto ml-sm-0 mr-sm-0">
|
<div class="mr-auto ml-auto ml-sm-0 mr-sm-0">
|
||||||
@ -30,13 +31,13 @@
|
|||||||
<div id="profile_aliases_btn" class="oi oi-caret-bottom h3 ml-0 ml-md-2"></div>
|
<div id="profile_aliases_btn" class="oi oi-caret-bottom h3 ml-0 ml-md-2"></div>
|
||||||
|
|
||||||
@if (Model.LevelInt < (int)ViewBag.User.Level &&
|
@if (Model.LevelInt < (int)ViewBag.User.Level &&
|
||||||
(SharedLibraryCore.Objects.Player.Permission)Model.LevelInt != SharedLibraryCore.Objects.Player.Permission.Banned)
|
(SharedLibraryCore.Objects.Player.Permission)Model.LevelInt != SharedLibraryCore.Objects.Player.Permission.Banned)
|
||||||
{
|
{
|
||||||
<div id="profile_action_ban_btn" class="profile-action oi oi-lock-unlocked text-success h3 ml-2" title="Ban Client" data-action="ban" aria-hidden="true"></div>
|
<div id="profile_action_ban_btn" class="profile-action oi oi-lock-unlocked text-success h3 ml-2" title="Ban Client" data-action="ban" aria-hidden="true"></div>
|
||||||
}
|
}
|
||||||
|
|
||||||
@if (Model.LevelInt < (int)ViewBag.User.Level &&
|
@if (Model.LevelInt < (int)ViewBag.User.Level &&
|
||||||
(SharedLibraryCore.Objects.Player.Permission)Model.LevelInt == SharedLibraryCore.Objects.Player.Permission.Banned)
|
(SharedLibraryCore.Objects.Player.Permission)Model.LevelInt == SharedLibraryCore.Objects.Player.Permission.Banned)
|
||||||
{
|
{
|
||||||
<div id="profile_action_unban_btn" class="profile-action oi oi-lock-locked text-danger h3 ml-2" title="Unban Client" data-action="unban" aria-hidden="true"></div>
|
<div id="profile_action_unban_btn" class="profile-action oi oi-lock-locked text-danger h3 ml-2" title="Unban Client" data-action="unban" aria-hidden="true"></div>
|
||||||
}
|
}
|
||||||
@ -44,6 +45,7 @@
|
|||||||
|
|
||||||
<div id="profile_aliases" class="pr-0 pr-sm-4 pb-2 mb-2 text-muted order-0">
|
<div id="profile_aliases" class="pr-0 pr-sm-4 pb-2 mb-2 text-muted order-0">
|
||||||
@{
|
@{
|
||||||
|
@Model.NetworkId.ToString("X") <br/>
|
||||||
foreach (string alias in Model.Aliases)
|
foreach (string alias in Model.Aliases)
|
||||||
{
|
{
|
||||||
@alias <br />
|
@alias <br />
|
||||||
@ -65,13 +67,13 @@
|
|||||||
<h5><span class="level-color-@Model.Level.ToLower()"><strong>@Model.Level</strong></span></h5>
|
<h5><span class="level-color-@Model.Level.ToLower()"><strong>@Model.Level</strong></span></h5>
|
||||||
</div>
|
</div>
|
||||||
<div id="profile_time_played" class="text-muted">
|
<div id="profile_time_played" class="text-muted">
|
||||||
Played <span class="text-primary">@Model.TimePlayed</span> hours
|
@loc["WEBFRONT_PROFILE_PLAYER"] <span class="text-primary">@Model.TimePlayed</span> @loc["GLOBAL_HOURS"]
|
||||||
</div>
|
</div>
|
||||||
<div id="profile_first_seen" class="text-muted">
|
<div id="profile_first_seen" class="text-muted">
|
||||||
First seen <span class="text-primary">@Model.FirstSeen</span> ago
|
@loc["WEBFRONT_PROFILE_FSEEN"] <span class="text-primary">@Model.FirstSeen</span> @loc["WEBFRONT_PENALTY_TEMPLATE_AGO"]
|
||||||
</div>
|
</div>
|
||||||
<div id="profile_last_seen" class="text-muted">
|
<div id="profile_last_seen" class="text-muted">
|
||||||
Last seen <span class="text-primary">@Model.LastSeen</span> ago
|
@loc["WEBFRONT_PROFILE_LSEEN"] <span class="text-primary">@Model.LastSeen</span> @loc["WEBFRONT_PENALTY_TEMPLATE_AGO"]
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="profile_meta" class="text-center text-sm-right pt-2 mt-md-4 pt-md-3 mr-4 pr-4 mr-md-0 ml-4 pl-4 ml-md-0 pr-md-0 pl-md-0">
|
<div id="profile_meta" class="text-center text-sm-right pt-2 mt-md-4 pt-md-3 mr-4 pr-4 mr-md-0 ml-4 pl-4 ml-md-0 pr-md-0 pl-md-0">
|
||||||
@ -81,12 +83,6 @@
|
|||||||
|
|
||||||
<div class="row d-md-flex pt-2">
|
<div class="row d-md-flex pt-2">
|
||||||
<div id="profile_events" class="text-muted text-left ml-sm-0">
|
<div id="profile_events" class="text-muted text-left ml-sm-0">
|
||||||
@{
|
|
||||||
if (Model.Meta.Count == 0)
|
|
||||||
{
|
|
||||||
<span> No recent events</span>
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
<input id="console_command_value" class="form-control m-0 bg-dark text-light" type="text" />
|
<input id="console_command_value" class="form-control m-0 bg-dark text-light" type="text" />
|
||||||
</div>
|
</div>
|
||||||
<div class="col pl-1 pl-sm-0">
|
<div class="col pl-1 pl-sm-0">
|
||||||
<button id="console_command_button" class="btn btn-primary btn-block m-0">Execute</button>
|
<button id="console_command_button" class="btn btn-primary btn-block m-0">@SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex["WEBFRONT_CONSOLE_EXECUTE"]</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
@model SharedLibraryCore.Objects.Penalty.PenaltyType
|
@model SharedLibraryCore.Objects.Penalty.PenaltyType
|
||||||
|
@{
|
||||||
|
var loc = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
|
}
|
||||||
<h4 class="pb-2 text-center ">@ViewBag.Title</h4>
|
<h4 class="pb-2 text-center ">@ViewBag.Title</h4>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<select class="form-control bg-dark text-muted" id="penalty_filter_selection">
|
<select class="form-control bg-dark text-muted" id="penalty_filter_selection">
|
||||||
@ -10,22 +12,22 @@
|
|||||||
{
|
{
|
||||||
if (Model == SharedLibraryCore.Objects.Penalty.PenaltyType.Any)
|
if (Model == SharedLibraryCore.Objects.Penalty.PenaltyType.Any)
|
||||||
{
|
{
|
||||||
<option value="@Convert.ToInt32(penaltyType)" selected="selected" )>Show @penaltyType.ToString()</option>
|
<option value="@Convert.ToInt32(penaltyType)" selected="selected" )>@loc["WEBFRONT_PENALTY_TEMPLATE_SHOW"] @penaltyType.ToString()</option>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<option value="@Convert.ToInt32(penaltyType)" )>Show @penaltyType.ToString()</option>
|
<option value="@Convert.ToInt32(penaltyType)" )>@loc["WEBFRONT_PENALTY_TEMPLATE_SHOW"] @penaltyType.ToString()</option>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ((SharedLibraryCore.Objects.Penalty.PenaltyType)penaltyType == Model)
|
if ((SharedLibraryCore.Objects.Penalty.PenaltyType)penaltyType == Model)
|
||||||
{
|
{
|
||||||
<option value="@Convert.ToInt32(penaltyType)" selected="selected">Show only @penaltyType.ToString()s</option>
|
<option value="@Convert.ToInt32(penaltyType)" selected="selected">@loc["WEBFRONT_PENALTY_TEMPLATE_SHOWONLY"] @penaltyType.ToString()s</option>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<option value="@Convert.ToInt32(penaltyType)" )>Show only @penaltyType.ToString()s</option>
|
<option value="@Convert.ToInt32(penaltyType)" )>@loc["WEBFRONT_PENALTY_TEMPLATE_SHOWONLY"] @penaltyType.ToString()s</option>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -36,11 +38,11 @@
|
|||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead class="d-none d-md-table-header-group">
|
<thead class="d-none d-md-table-header-group">
|
||||||
<tr class="bg-primary pt-2 pb-2">
|
<tr class="bg-primary pt-2 pb-2">
|
||||||
<th scope="col">Name</th>
|
<th scope="col">@loc["WEBFRONT_PENALTY_TEMPLATE_NAME"]</th>
|
||||||
<th scope="col">Type</th>
|
<th scope="col">@loc["WEBFRONT_PENALTY_TEMPLATE_TYPE"]</th>
|
||||||
<th scope="col">Offense</th>
|
<th scope="col">@loc["WEBFRONT_PENALTY_TEMPLATE_OFFENSE"]</th>
|
||||||
<th scope="col">Admin</th>
|
<th scope="col">@loc["WEBFRONT_PENALTY_TEMPLATE_ADMIN"]</th>
|
||||||
<th scope="col" class="text-right">Time/Left</th>
|
<th scope="col" class="text-right">@loc["WEBFRONT_PENALTY_TEMPLATE_TIME"]</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody id="penalty_table" class="border-bottom bg-dark">
|
<tbody id="penalty_table" class="border-bottom bg-dark">
|
||||||
|
@ -1,48 +1,49 @@
|
|||||||
@{
|
@{
|
||||||
Layout = null;
|
Layout = null;
|
||||||
|
var loc = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
@model SharedLibraryCore.Dtos.PenaltyInfo
|
@model SharedLibraryCore.Dtos.PenaltyInfo
|
||||||
|
|
||||||
<tr class="d-table-row d-md-none bg-dark">
|
<tr class="d-table-row d-md-none bg-dark">
|
||||||
<th scope="row" class="bg-primary">Name</th>
|
<th scope="row" class="bg-primary">@loc["WEBFRONT_PENALTY_TEMPLATE_NAME"]</th>
|
||||||
<td>
|
<td>
|
||||||
@Html.ActionLink(Model.OffenderName, "ProfileAsync", "Client", new { id = Model.OffenderId }, new { @class = "link-inverse" })
|
@Html.ActionLink(Model.OffenderName, "ProfileAsync", "Client", new { id = Model.OffenderId }, new { @class = "link-inverse" })
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr class="d-table-row d-md-none bg-dark">
|
<tr class="d-table-row d-md-none bg-dark">
|
||||||
<th scope="row" class="bg-primary">Type</th>
|
<th scope="row" class="bg-primary">@loc["WEBFRONT_PENALTY_TEMPLATE_TYPE"]</th>
|
||||||
<td class="penalties-color-@Model.Type.ToLower()">
|
<td class="penalties-color-@Model.Type.ToLower()">
|
||||||
@Model.Type
|
@Model.Type
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr class="d-table-row d-md-none bg-dark">
|
<tr class="d-table-row d-md-none bg-dark">
|
||||||
<th scope="row" class="bg-primary">Offense</th>
|
<th scope="row" class="bg-primary">@loc["WEBFRONT_PENALTY_TEMPLATE_OFFENSE"]</th>
|
||||||
<td class="text-light">
|
<td class="text-light">
|
||||||
@Model.Offense
|
@Model.Offense
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr class="d-table-row d-md-none bg-dark">
|
<tr class="d-table-row d-md-none bg-dark">
|
||||||
<th scope="row" class="bg-primary">Admin</th>
|
<th scope="row" class="bg-primary">@loc["WEBFRONT_PENALTY_TEMPLATE_ADMIN"]</th>
|
||||||
<td>
|
<td>
|
||||||
@Html.ActionLink(Model.PunisherName, "ProfileAsync", "Client", new { id = Model.PunisherId }, new { @class = "level-color-" + Model.PunisherLevel.ToLower() })
|
@Html.ActionLink(Model.PunisherName, "ProfileAsync", "Client", new { id = Model.PunisherId }, new { @class = "level-color-" + Model.PunisherLevel.ToLower() })
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<tr class="d-table-row d-md-none bg-dark">
|
<tr class="d-table-row d-md-none bg-dark">
|
||||||
<th scope="row" class="w-25 bg-primary" style="border-bottom: 1px solid #222">Time/Left</th>
|
<th scope="row" class="w-25 bg-primary" style="border-bottom: 1px solid #222">@loc["WEBFRONT_PENALTY_TEMPLATE_TIME"]</th>
|
||||||
<td class="text-light mb-2 border-bottom">
|
<td class="text-light mb-2 border-bottom">
|
||||||
@{
|
@{
|
||||||
if (Model.TimeRemaining == string.Empty)
|
if (Model.TimeRemaining == string.Empty)
|
||||||
{
|
{
|
||||||
<span>@Model.TimePunished ago</span>
|
<span>@Model.TimePunished @loc["WEBFRONT_PENALTY_TEMPLATE_AGO"]</span>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<span> @Model.TimeRemaining left</span>
|
<span> @Model.TimeRemaining @loc["WEBFRONT_PENALTY_TEMPLATE_REMAINING"]</span>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
@ -65,11 +66,11 @@
|
|||||||
@{
|
@{
|
||||||
if (Model.TimeRemaining == string.Empty)
|
if (Model.TimeRemaining == string.Empty)
|
||||||
{
|
{
|
||||||
<span>@Model.TimePunished ago</span>
|
<span>@Model.TimePunished @loc["WEBFRONT_PENALTY_TEMPLATE_AGO"]</span>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<span> @Model.TimeRemaining left</span>
|
<span> @Model.TimeRemaining @loc["WEBFRONT_PENALTY_TEMPLATE_REMAINING"]</span>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
|
@ -2,5 +2,5 @@
|
|||||||
ViewData["Title"] = "Error";
|
ViewData["Title"] = "Error";
|
||||||
}
|
}
|
||||||
|
|
||||||
<h4 class="text-danger">Sorry!</h4>
|
<h4 class="text-danger">@SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex["WEBFRONT_ERROR_GENERIC_TITLE"]</h4>
|
||||||
<h4 class="text-danger">An error occurred while processing your request.</h4>
|
<h4 class="text-danger">@SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex["WEBFRONT_ERROR_GENERIC_DESC"]</h4>
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
<!DOCTYPE html>
|
@{
|
||||||
|
var loc = SharedLibraryCore.Utilities.CurrentLocalization.LocalizationIndex;
|
||||||
|
}
|
||||||
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
@ -32,13 +35,13 @@
|
|||||||
</button>
|
</button>
|
||||||
<div class="collapse navbar-collapse" id="navbarCollapse">
|
<div class="collapse navbar-collapse" id="navbarCollapse">
|
||||||
<ul class="navbar-nav mr-auto">
|
<ul class="navbar-nav mr-auto">
|
||||||
<li class="nav-item text-center text-md-left">@Html.ActionLink("Home", "Index", "Home", new { area = "" }, new { @class = "nav-link" })</li>
|
<li class="nav-item text-center text-md-left">@Html.ActionLink(loc["WEBFRONT_NAV_HOME"], "Index", "Home", new { area = "" }, new { @class = "nav-link" })</li>
|
||||||
<li class="nav-item text-center text-md-left">@Html.ActionLink("Penalties", "List", "Penalty", new { area = "" }, new { @class = "nav-link" })</li>
|
<li class="nav-item text-center text-md-left">@Html.ActionLink(loc["WEBFRONT_NAV_PENALTIES"], "List", "Penalty", new { area = "" }, new { @class = "nav-link" })</li>
|
||||||
<li class="nav-item text-center text-md-left">@Html.ActionLink("Admins", "PrivilegedAsync", "Client", new { area = "" }, new { @class = "nav-link" })</li>
|
<li class="nav-item text-center text-md-left">@Html.ActionLink(loc["WEBFRONT_NAV_PRIVILEGED"], "PrivilegedAsync", "Client", new { area = "" }, new { @class = "nav-link" })</li>
|
||||||
<li class="nav-item text-center text-md-left"></li>
|
<li class="nav-item text-center text-md-left"></li>
|
||||||
@if (!string.IsNullOrEmpty(ViewBag.DiscordLink))
|
@if (!string.IsNullOrEmpty(ViewBag.SocialLink))
|
||||||
{
|
{
|
||||||
<li class="nav-item text-center text-md-left"><a href="@ViewBag.DiscordLink" class="nav-link" target="_blank">Discord</a></li>
|
<li class="nav-item text-center text-md-left"><a href="@ViewBag.SocialLink" class="nav-link" target="_blank">@ViewBag.SocialTitle</a></li>
|
||||||
}
|
}
|
||||||
@if (ViewBag.Authorized)
|
@if (ViewBag.Authorized)
|
||||||
{
|
{
|
||||||
@ -46,17 +49,17 @@
|
|||||||
<a href="#" class="nav-link oi oi-person dropdown-toggle oi-fix-navbar w-100" id="account_dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></a>
|
<a href="#" class="nav-link oi oi-person dropdown-toggle oi-fix-navbar w-100" id="account_dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></a>
|
||||||
|
|
||||||
<div class="dropdown-menu p-0" aria-labelledby="account_dropdown">
|
<div class="dropdown-menu p-0" aria-labelledby="account_dropdown">
|
||||||
@Html.ActionLink("Console", "Index", "Console", new { area = "" }, new
|
@Html.ActionLink(loc["WEBFRONT_NAV_CONSOLE"], "Index", "Console", new { area = "" }, new
|
||||||
{
|
{
|
||||||
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
||||||
title = "Web Console"
|
title = "Web Console"
|
||||||
})
|
})
|
||||||
@Html.ActionLink("Profile", "ProfileAsync", "Client", new { id = ViewBag.User.ClientId }, new
|
@Html.ActionLink(loc["WEBFRONT_NAV_PROFILE"], "ProfileAsync", "Client", new { id = ViewBag.User.ClientId }, new
|
||||||
{
|
{
|
||||||
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
||||||
title = "Client Profile",
|
title = "Client Profile",
|
||||||
})
|
})
|
||||||
@Html.ActionLink("Logout", "LogoutAsync", "Account", new { area = "" }, new
|
@Html.ActionLink(loc["WEBFRONT_NAV_LOGOUT"], "LogoutAsync", "Account", new { area = "" }, new
|
||||||
{
|
{
|
||||||
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
@class = "dropdown-item bg-dark text-muted text-center text-md-left",
|
||||||
title = "Logout of account"
|
title = "Logout of account"
|
||||||
@ -74,7 +77,7 @@
|
|||||||
}
|
}
|
||||||
</ul>
|
</ul>
|
||||||
<form class="form-inline text-primary pt-3 pb-3" method="get" action="/Client/FindAsync">
|
<form class="form-inline text-primary pt-3 pb-3" method="get" action="/Client/FindAsync">
|
||||||
<input id="client_search" name="clientName" class="form-control mr-auto ml-auto mr-md-2" type="text" placeholder="Find Player" />
|
<input id="client_search" name="clientName" class="form-control mr-auto ml-auto mr-md-2" type="text" placeholder="@loc["WEBFRONT_NAV_SEARCH"]" />
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
Loading…
Reference in New Issue
Block a user