public virtual void Clone(ClientContract cloneObj) { base.Clone(cloneObj); cloneObj.ContractNum = this.ContractNum; cloneObj.StudentName = this.StudentName; cloneObj.Birthday = this.Birthday; cloneObj.University = this.University; cloneObj.Course = this.Course; cloneObj.Consultant = this.Consultant; cloneObj.BrachCompany = this.BrachCompany; cloneObj.SendDate = this.SendDate; cloneObj.ApplyStatus = this.ApplyStatus; cloneObj.Note = this.Note; if(this.Country != null){ cloneObj.Country = new IWEHAVE.ERP.CenterBE.CountryEnum(); cloneObj.Country.EnumValue = this.Country.EnumValue; cloneObj.Country.Code = this.Country.Code; cloneObj.Country.Name = this.Country.Name; }else{ cloneObj.Country = null; } if(this.Type != null){ cloneObj.Type = new IWEHAVE.ERP.CenterBE.ContractTypeEnum(); cloneObj.Type.EnumValue = this.Type.EnumValue; cloneObj.Type.Code = this.Type.Code; cloneObj.Type.Name = this.Type.Name; }else{ cloneObj.Type = null; } cloneObj.Sex = this.Sex; }
private static ClientContract Create(bool inList) { ClientContract entity = new ClientContract(); entity.ID = NHExt.Runtime.Util.EntityGuidHelper.New(); entity.EntityState = NHExt.Runtime.Enums.EntityState.Add; if(inList){ if(Session.Current != null){ Session.Current.InList(entity); } } return entity; }
public override NHExt.Runtime.Model.BaseEntity Clone() { ClientContract cloneObj = new ClientContract(); this.Clone(cloneObj); return cloneObj; }