This commit is contained in:
2020-07-27 23:47:12 +00:00
parent f2f0113d62
commit eb1786da85
3 changed files with 25 additions and 3 deletions

View File

@@ -274,6 +274,20 @@ namespace AyaNova.Biz
}
}
//used by internal notification and other processes i.e. "Server" in all languages for server based notifications
internal static async Task<Dictionary<long, string>> GetAllTranslationsForKey(string translationKey)
{
#if (DEBUG)
TrackRequestedKey(translationKey);
#endif
using (AyContext ct = ServiceProviderProvider.DBContext)
{
return await ct.TranslationItem.Where(z => z.Key == translationKey).AsNoTracking().ToDictionaryAsync(z => z.TranslationId, z => z.Display);
}
}
//Get the CJKIndex value for the translation specified
internal static async Task<bool> GetCJKIndexAsync(long translationId, AyContext ct)