72 lines
3.5 KiB
C#
72 lines
3.5 KiB
C#
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.Tantargy.Models
|
|
{
|
|
public class TanorakGridModel : IKretaIdentity
|
|
{
|
|
public const string TanorakExportAttributeId = nameof(TanorakExportAttributeId);
|
|
|
|
public string ID { get; set; }
|
|
|
|
[Display(Name = nameof(TantargyResource.Datum), ResourceType = typeof(TantargyResource))]
|
|
public DateTime? Datum { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 00, nameof(OrarendResource.OraKezdete), typeof(OrarendResource), DateTimeToStringPattern = Core.Constants.ToStringPattern.HungarianDateTimeWithoutSeconds)]
|
|
[Display(Name = nameof(OrarendResource.OraKezdete), ResourceType = typeof(OrarendResource))]
|
|
public DateTime? OraKezdete { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 01, nameof(TantargyResource.OraSorsz), typeof(TantargyResource))]
|
|
[Display(Name = nameof(TantargyResource.OraSorsz), ResourceType = typeof(TantargyResource))]
|
|
public string OraSorsz { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 02, nameof(TantargyResource.OraSorszama), typeof(TantargyResource))]
|
|
[Display(Name = nameof(TantargyResource.OraSorszama), ResourceType = typeof(TantargyResource))]
|
|
public string EvesSorsz { get; set; }
|
|
|
|
[Display(Name = nameof(TantargyResource.Nap), ResourceType = typeof(TantargyResource))]
|
|
public string HetNapja_DNAME { get; set; }
|
|
|
|
[Display(Name = nameof(TantargyResource.Tantargy), ResourceType = typeof(TantargyResource))]
|
|
public string TargyNev { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 03, nameof(TantargyResource.Tanar), typeof(TantargyResource))]
|
|
[Display(Name = nameof(TantargyResource.Tanar), ResourceType = typeof(TantargyResource))]
|
|
public string TanarNev { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 04, nameof(TantargyResource.TanoraTemaja), typeof(TantargyResource))]
|
|
[Display(Name = nameof(TantargyResource.TanoraTemaja), ResourceType = typeof(TantargyResource))]
|
|
public string Tema { get; set; }
|
|
|
|
[Display(Name = nameof(TantargyResource.OsztalyCsoport), ResourceType = typeof(TantargyResource))]
|
|
|
|
public string OsztCsopNev { get; set; }
|
|
|
|
[Display(Name = nameof(TantargyResource.Helyettesitett), ResourceType = typeof(TantargyResource))]
|
|
public string IsHelyetesitett_BNAME { get; set; }
|
|
|
|
[Display(Name = nameof(AdminisztracioResource.EgyediNap), ResourceType = typeof(AdminisztracioResource))]
|
|
public string IsEgyediNap_BNAME { get; set; }
|
|
|
|
[SimpleExportColumn(TanorakExportAttributeId, 05, nameof(OrarendResource.NaplozasDatuma), typeof(OrarendResource), DateTimeToStringPattern = Core.Constants.ToStringPattern.HungarianDateTimeWithoutSeconds)]
|
|
[Display(Name = nameof(OrarendResource.NaplozasDatuma), ResourceType = typeof(OrarendResource))]
|
|
public DateTime? NaplozasDatuma { get; set; }
|
|
|
|
public TanorakGridModel() { }
|
|
|
|
public TanorakGridModel(TanorakItemCo itemCo)
|
|
{
|
|
ID = itemCo.Id.ToString();
|
|
OraKezdete = itemCo.OraKezdete;
|
|
OraSorsz = itemCo.OraSorsz;
|
|
EvesSorsz = itemCo.EvesSorsz;
|
|
TanarNev = itemCo.TanarNev;
|
|
Tema = itemCo.Tema;
|
|
NaplozasDatuma = itemCo.NaplozasDatuma;
|
|
}
|
|
}
|
|
}
|