init
This commit is contained in:
commit
e124a47765
19374 changed files with 9806149 additions and 0 deletions
155
Kreta.BusinessLogic/HelperClasses/DualisKepzohelyCo.cs
Normal file
155
Kreta.BusinessLogic/HelperClasses/DualisKepzohelyCo.cs
Normal file
|
@ -0,0 +1,155 @@
|
|||
using System.Data;
|
||||
using Kreta.BusinessLogic.Classes;
|
||||
using Kreta.Core;
|
||||
using Kreta.DataAccess.Interfaces;
|
||||
using Kreta.Enums.ManualEnums;
|
||||
|
||||
namespace Kreta.BusinessLogic.HelperClasses
|
||||
{
|
||||
public class DualisKepzohelyCo
|
||||
{
|
||||
public DualisKepzohelyCo() { }
|
||||
|
||||
public DualisKepzohelyCo(DataRow dataRow, bool isSzerkesztheto)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["SzervezetId"]);
|
||||
KepzohelyNeve = SDAConvert.ToString(dataRow["SzervezetNev"]).ReplaceMultipleSpacesAndTrim();
|
||||
KepzohelyAdoszama = SDAConvert.ToString(dataRow["SzervezetAzonosito"]).ReplaceMultipleSpacesAndTrim();
|
||||
KepzohelyCime = SDAConvert.ToString(dataRow["SzervezetCim"]);
|
||||
TanulokSzama = SDAConvert.ToInt32(dataRow["TanulokSzama"]);
|
||||
OktatokSzama = SDAConvert.ToInt32(dataRow["OktatokSzama"]);
|
||||
CsoportokSzama = SDAConvert.ToInt32(dataRow["CsoportokSzama"]);
|
||||
TantargyakSzama = SDAConvert.ToInt32(dataRow["TantargyakSzama"]);
|
||||
HelyszinekSzama = SDAConvert.ToInt32(dataRow["HelyszinekSzama"]);
|
||||
RogzitoId = SDAConvert.ToInt32(dataRow["RogzitoId"]);
|
||||
ParentSzervezetId = SDAConvert.ToNullableInt32(dataRow["ParentSzervezetId"]);
|
||||
ParentSzervezetNeve = SDAConvert.ToString(dataRow["ParentSzervezetNev"]).ReplaceMultipleSpacesAndTrim();
|
||||
HelyszinTipusId = SDAConvert.ToInt32(dataRow["HelyszinTipusId"]);
|
||||
IsSzerkesztheto = isSzerkesztheto;
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string KepzohelyNeve { get; set; }
|
||||
public string KepzohelyAdoszama { get; set; }
|
||||
public string KepzohelyCime { get; set; }
|
||||
public int TanulokSzama { get; set; }
|
||||
public int OktatokSzama { get; set; }
|
||||
public int CsoportokSzama { get; set; }
|
||||
public int TantargyakSzama { get; set; }
|
||||
public int HelyszinekSzama { get; set; }
|
||||
public int RogzitoId { get; set; }
|
||||
public int HelyszinTipusId { get; set; }
|
||||
public int? ParentSzervezetId { get; set; }
|
||||
public string ParentSzervezetNeve { get; set; }
|
||||
|
||||
public bool IsSzerkesztheto { get; set; }
|
||||
|
||||
public static ISzervezet CoToSzervezetEntity(ISzervezet entity, DualisKepzohelyCo co)
|
||||
{
|
||||
entity.Nev = co.KepzohelyNeve;
|
||||
entity.Azonosito = co.KepzohelyAdoszama;
|
||||
if (co.ID.HasValue)
|
||||
{
|
||||
entity.ID = co.ID.Value;
|
||||
}
|
||||
entity.Szervezetcim = co.KepzohelyCime;
|
||||
entity.DualishelyszintipusId = co.HelyszinTipusId;
|
||||
if (co.ParentSzervezetId.IsEntityId())
|
||||
{
|
||||
entity.ParentSzervezetId = co.ParentSzervezetId.Value;
|
||||
}
|
||||
entity.Tipus = (int)SzervezetTipusEnum.Dualis;
|
||||
|
||||
return entity;
|
||||
}
|
||||
}
|
||||
|
||||
public class DualisCsoportCo
|
||||
{
|
||||
public DualisCsoportCo() { }
|
||||
|
||||
public DualisCsoportCo(DataRow dataRow)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["CsoportId"]);
|
||||
CsoportNeve = SDAConvert.ToString(dataRow["CsoportNeve"]);
|
||||
TanulokSzama = SDAConvert.ToInt32(dataRow["TanulokSzama"]);
|
||||
Megjegyzes = SDAConvert.ToString(dataRow["Megjegyzes"]);
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string CsoportNeve { get; set; }
|
||||
public int TanulokSzama { get; set; }
|
||||
public string Megjegyzes { get; set; }
|
||||
}
|
||||
|
||||
public class DualisTanuloCo
|
||||
{
|
||||
public DualisTanuloCo() { }
|
||||
|
||||
public DualisTanuloCo(DataRow dataRow)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["TanuloId"]);
|
||||
Nev = SDAConvert.ToString(dataRow["TanuloNeve"]);
|
||||
OktatasiAzonosito = SDAConvert.ToString(dataRow["OktatasiAzonosito"]);
|
||||
Adoazonosito = SDAConvert.ToString(dataRow["Adoazonosito"]);
|
||||
TajSzam = SDAConvert.ToString(dataRow["TajSzam"]);
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string Nev { get; set; }
|
||||
public string OktatasiAzonosito { get; set; }
|
||||
public string Adoazonosito { get; set; }
|
||||
public string TajSzam { get; set; }
|
||||
}
|
||||
|
||||
public class DualisOktatoCo
|
||||
{
|
||||
public DualisOktatoCo() { }
|
||||
|
||||
public DualisOktatoCo(DataRow dataRow)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["OktatoId"]);
|
||||
Nev = SDAConvert.ToString(dataRow["OktatoNeve"]);
|
||||
OktatasiAzonosito = SDAConvert.ToString(dataRow["OktatasiAzonosito"]);
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string Nev { get; set; }
|
||||
public string OktatasiAzonosito { get; set; }
|
||||
}
|
||||
|
||||
public class DualisTantargyCo
|
||||
{
|
||||
public DualisTantargyCo() { }
|
||||
|
||||
public DualisTantargyCo(DataRow dataRow)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["TantargyId"]);
|
||||
Nev = SDAConvert.ToString(dataRow["TantargyNeve"]);
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string Nev { get; set; }
|
||||
}
|
||||
|
||||
public class DualisHelyszinCo
|
||||
{
|
||||
public DualisHelyszinCo() { }
|
||||
|
||||
public DualisHelyszinCo(DataRow dataRow)
|
||||
{
|
||||
ID = SDAConvert.ToInt32(dataRow["TeremId"]);
|
||||
Nev = SDAConvert.ToString(dataRow["TeremNeve"]);
|
||||
HelyisegJelleg = SDAConvert.ToString(dataRow["HelyisegJelleg"]);
|
||||
HelyszinTipus = SDAConvert.ToString(dataRow["HelyszinTipus"]);
|
||||
Aktiv = SDAConvert.ToBooleanFromTF(dataRow["Aktiv"]);
|
||||
}
|
||||
|
||||
public int? ID { get; set; }
|
||||
public string Nev { get; set; }
|
||||
public string HelyisegJelleg { get; set; }
|
||||
public string HelyszinTipus { get; set; }
|
||||
public bool Aktiv { get; set; }
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue