init
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Kreta.BusinessLogic.HelperClasses;
|
||||
using Kreta.BusinessLogic.Helpers.SystemSettings;
|
||||
using Kreta.Enums;
|
||||
using Kreta.Web.Helpers;
|
||||
|
||||
namespace Kreta.Web.Models
|
||||
{
|
||||
public class ZaradekSzovegModel
|
||||
{
|
||||
public int NyelvId { get; set; }
|
||||
|
||||
public string Szoveg { get; set; }
|
||||
|
||||
public static List<ZaradekSzovegModel> AdatszotarNyelvCoToZaradekSzovegModel(List<AdatszotarZaradekNyelvCo> coList = null)
|
||||
{
|
||||
coList = coList ?? new List<AdatszotarZaradekNyelvCo>();
|
||||
return new SystemSettingsHelper(ConnectionTypeExtensions.GetSessionConnectionType()).GetSystemSettingValue<List<int>>(RendszerBeallitasTipusEnum.Nemzeti_Nyelvi_Dokumentum_Nyelvek).ConvertAll(y =>
|
||||
new ZaradekSzovegModel
|
||||
{
|
||||
NyelvId = y,
|
||||
Szoveg = coList.SingleOrDefault(x => x.NyelvId == y)?.Name ?? string.Empty
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user