コード例 #1
0
ファイル: Sever.cs プロジェクト: windygu/School
        public override void AssignData()
        {
            Dto dto = (base.FormDto as FormDto).Dto as Dto;

            if (dto == null)
            {
                return;
            }
            Comp.Data data = base.ComponentData as Comp.Data;
            data.Id               = dto.Id;
            data.DateOfBirth      = dto.DateOfBirth;
            data.BirthPlace       = dto.BirthPlace;
            data.MotherTongue     = new ConfFac.MotherTongue.Server(null).Convert(dto.MotherTongue) as Conf.MotherTongue.Data;
            data.Religion         = new ConfFac.Religion.Server(null).Convert(dto.Religion) as Conf.Religion.Data;
            data.Caste            = new ConfFac.Caste.Server(null).Convert(dto.Caste) as Conf.Caste.Data;
            data.SubCaste         = new ConfFac.SubCaste.Server(null).Convert(dto.SubCaste) as Conf.SubCaste.Data;
            data.Gender           = new ConfFac.Gender.Server(null).Convert(dto.Gender) as Conf.Gender.Data;
            data.PresentAddress   = new ConfFac.ContactInformation.Server(null).Convert(dto.CurrentAddress) as Conf.ContactInformation.Data;
            data.PermanentAddress = new ConfFac.ContactInformation.Server(null).Convert(dto.PermanentAddress) as Conf.ContactInformation.Data;
        }
コード例 #2
0
ファイル: Sever.cs プロジェクト: windygu/School
 public override BinAff.Facade.Library.Dto Convert(BinAff.Core.Data data)
 {
     if (data == null)
     {
         return(new Dto());
     }
     Comp.Data dt = data as Comp.Data;
     return(new Dto
     {
         Id = dt.Id,
         DateOfBirth = dt.DateOfBirth,
         BirthPlace = dt.BirthPlace,
         MotherTongue = new ConfFac.MotherTongue.Server(null).Convert(dt.MotherTongue) as ConfFac.MotherTongue.Dto,
         Religion = new ConfFac.Religion.Server(null).Convert(dt.Religion) as ConfFac.Religion.Dto,
         Caste = new ConfFac.Caste.Server(null).Convert(dt.Caste) as ConfFac.Caste.Dto,
         SubCaste = new ConfFac.SubCaste.Server(null).Convert(dt.SubCaste) as ConfFac.SubCaste.Dto,
         Gender = new ConfFac.Gender.Server(null).Convert(dt.Gender) as ConfFac.Gender.Dto,
         CurrentAddress = new ConfFac.ContactInformation.Server(null).Convert(dt.PresentAddress) as ConfFac.ContactInformation.Dto,
         PermanentAddress = new ConfFac.ContactInformation.Server(null).Convert(dt.PermanentAddress) as ConfFac.ContactInformation.Dto,
     });
 }
コード例 #3
0
ファイル: Dao.cs プロジェクト: BinAff/School
 public Dao(Data data)
     : base(data)
 {
 }
コード例 #4
0
ファイル: Server.cs プロジェクト: BinAff/School
 public Server(Data data)
     : base(data)
 {
 }