0
我不想在ASP.NET Boilerplate中進行本地化支持,請讓我知道如何禁用它(如果可能)。默認情況下禁用本地化而僅支持英文。
我不想在ASP.NET Boilerplate中進行本地化支持,請讓我知道如何禁用它(如果可能)。默認情況下禁用本地化而僅支持英文。
註釋掉這些行DefaultLanguagesCreator.cs:
private static List<ApplicationLanguage> GetInitialLanguages()
{
return new List<ApplicationLanguage>
{
new ApplicationLanguage(null, "en", "English", "famfamfam-flags gb"),
// new ApplicationLanguage(null, "ar", "العربية", "famfamfam-flags sa"),
// new ApplicationLanguage(null, "de", "German", "famfamfam-flags de"),
// new ApplicationLanguage(null, "it", "Italiano", "famfamfam-flags it"),
// new ApplicationLanguage(null, "fr", "Français", "famfamfam-flags fr"),
// new ApplicationLanguage(null, "pt-BR", "Portuguese", "famfamfam-flags br"),
// new ApplicationLanguage(null, "tr", "Türkçe", "famfamfam-flags tr"),
// new ApplicationLanguage(null, "ru", "Русский", "famfamfam-flags ru"),
// new ApplicationLanguage(null, "zh-CN", "簡體中文", "famfamfam-flags cn"),
// new ApplicationLanguage(null, "es-MX", "Español México", "famfamfam-flags mx"),
// new ApplicationLanguage(null, "ja", "日本語", "famfamfam-flags jp")
};
}
如果您以前播種,從數據庫中AbpLanguages
表中刪除的條目。
註釋掉這一行Account/_Layout.cshtml登錄前禁用語言選擇:
@*<vc:account-languages></vc:account-languages>*@
註釋掉這一行Shared/_Layout.cshtml登錄後禁用語言選擇:
@*@await Component.InvokeAsync(typeof(TopBarLanguageSwitchViewComponent))*@