using System; using System.ComponentModel.DataAnnotations; using Kreta.BusinessLogic.HelperClasses; using Kreta.BusinessLogic.Interfaces; using Kreta.Core.CustomAttributes; using Kreta.Resources; namespace Kreta.Web.Areas.Orarend.Models { public class TanitasiOraGridModel : IKretaIdentity { #region Fields /// /// Technikai paraméter(ek) a reflection-ös exporthoz. /// public const string TanoraExportAttributeId = nameof(TanoraExportAttributeId); #endregion Fields public TanitasiOraGridModel() { } public TanitasiOraGridModel(TanoraItemCo itemCo) { ID = itemCo.ID.ToString(); Datum = itemCo.Datum; Ora = itemCo.Ora; OraSorszTxt = itemCo.OraSorszam; TanarNev = itemCo.TanarNev; Megjegyzes = itemCo.Megjegyzes; OsztCsopNev = itemCo.OsztCsopNev; TargyNev = itemCo.TargyNev; Tema = itemCo.Tema; NaplozasDatuma = itemCo.NaplozasDatuma; HFRogzitve = itemCo.HFRogzitve; OnlineOra = itemCo.OnlineOra; } public string ID { get; set; } public int? OrarendiOra { get; set; } [Display(Name = nameof(OrarendResource.Datum), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 00, nameof(OrarendResource.Datum), typeof(OrarendResource))] public DateTime Datum { get; set; } [Display(Name = nameof(OrarendResource.NaplozasDatuma), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 08, nameof(OrarendResource.NaplozasDatuma), typeof(OrarendResource))] public DateTime NaplozasDatuma { get; set; } [Display(Name = nameof(OrarendResource.NagyOra), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 01, nameof(OrarendResource.OraNaponBeluliSorszama), typeof(OrarendResource))] public int? Ora { get; set; } [Display(Name = nameof(OrarendResource.OraSorszam), ResourceType = typeof(OrarendResource))] public int OraSorsz { get; set; } [Display(Name = nameof(OrarendResource.OraSorszam), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 02, nameof(OrarendResource.OraSorszam), typeof(OrarendResource))] public string OraSorszTxt { get; set; } [Display(Name = nameof(OrarendResource.OraEvesSorszama), ResourceType = typeof(OrarendResource))] public int EvesSorsz { get; set; } [Display(Name = nameof(OrarendResource.TanarHelyettesito), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 03, nameof(OrarendResource.TanarHelyettesito), typeof(OrarendResource))] public string TanarNev { get; set; } [Display(Name = nameof(OrarendResource.TanarHelyettesito), ResourceType = typeof(OrarendResource))] public string TanarNevElotagNelkul { get; set; } [Display(Name = nameof(OrarendResource.HelyettesitesOka), ResourceType = typeof(OrarendResource))] public string Helyettesitesoka { get; set; } [Display(Name = nameof(OrarendResource.Megjegyzes), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 04, nameof(OrarendResource.Megjegyzes), typeof(OrarendResource))] public string Megjegyzes { get; set; } [Display(Name = nameof(OrarendResource.OsztalyCsoport), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 05, nameof(OrarendResource.OsztalyCsoport), typeof(OrarendResource))] public string OsztCsopNev { get; set; } [Display(Name = nameof(OrarendResource.Tantargy), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 06, nameof(OrarendResource.Tantargy), typeof(OrarendResource))] public string TargyNev { get; set; } [Display(Name = nameof(OrarendResource.Tema), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 07, nameof(OrarendResource.Tema), typeof(OrarendResource))] public string Tema { get; set; } public string HFRogzitve_BNAME { get; set; } [Display(Name = nameof(OrarendResource.HFRogzitve), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 09, nameof(OrarendResource.HFRogzitve), typeof(OrarendResource))] public string HFRogzitve { get; set; } [Display(Name = nameof(OrarendResource.OnlineOra), ResourceType = typeof(OrarendResource))] [SimpleExportColumn(nameof(TanoraExportAttributeId), 10, nameof(OrarendResource.OnlineOra), typeof(OrarendResource))] public string OnlineOra { get; set; } } }