diff --git a/server/AyaNova/Controllers/EnumListController.cs b/server/AyaNova/Controllers/EnumListController.cs index 496a9488..fbd80ae0 100644 --- a/server/AyaNova/Controllers/EnumListController.cs +++ b/server/AyaNova/Controllers/EnumListController.cs @@ -106,14 +106,25 @@ namespace AyaNova.Api.Controllers else if (keyNameInLowerCase == StringUtil.TrimTypeName(typeof(AyaType).ToString()).ToLowerInvariant()) { //this is intended primarily for developers, not for UI facing so no need to localize or pretty it up + //bullshit, it's just extra work not translated and developers only need the number, not the enumeration name which is for here only + var values = Enum.GetValues(typeof(AyaType)); + foreach (AyaType t in values) + TranslationKeysToFetch.Add(t.ToString()); + var LT = TranslationBiz.GetSubsetStaticAsync(TranslationKeysToFetch, TranslationId).Result; + foreach (AyaType t in values) { - string name = t.ToString(); - if (t.HasAttribute(typeof(CoreBizObjectAttribute))) + string tName = t.ToString(); + string name = string.Empty; + if (LT.ContainsKey(tName)) { - name += " [CoreBizObject]"; + name = LT[tName]; + } + else + { + name = tName; } ReturnList.Add(new NameIdItem() { Name = name, Id = (long)t }); } diff --git a/server/AyaNova/biz/AyaType.cs b/server/AyaNova/biz/AyaType.cs index 4d2c8d01..f93906e9 100644 --- a/server/AyaNova/biz/AyaType.cs +++ b/server/AyaNova/biz/AyaType.cs @@ -50,9 +50,10 @@ namespace AyaNova.Biz //AyaNova.Biz.BizObjectFactory //AyaNova.Biz.BizRoles //AyaNova.Biz.BizObjectNameFetcherDIRECT - //and in the CLIENT in ayatype.js + //and need TRANSLATION KEYS because any type could show in the event log at teh client end + }