public AddressTypeData(AddressTypeData data) { Name = data.Name; rowguid = data.rowguid; ModifiedDate = data.ModifiedDate; Uid = data.Uid; }
public AddressType(AddressTypeData addressTypeData) { AddressTypeKey = addressTypeData.AddressTypeKey; AddressTypeCode = addressTypeData.AddressTypeCode; AddressTypeName = addressTypeData.AddressTypeName; AddressTypeDesc = addressTypeData.AddressTypeDesc; AddedUserID = addressTypeData.AuditAddUserId; AddedDateTime = addressTypeData.AuditAddDatetime; UpdateUserID = addressTypeData.AuditUpdateUserId; UpdateDateTime = addressTypeData.AuditUpdateDatetime; }
protected override void LazySet() { base.LazySet(); if (PersistenceState == PersistenceState.NewAndChanged || PersistenceState == PersistenceState.LoadedAndChanged) { if ((object)InnerData == (object)OriginalData) { OriginalData = new AddressTypeData(InnerData); } } }
} // Map function closer public List <SqlParameter> MapParamsForUpsert(AddressTypeData entity) { var sql_params = new List <SqlParameter>(); sql_params.Add(new SqlParameter("@address_type_key", entity.AddressTypeKey)); sql_params.Add(new SqlParameter("@address_type_code", entity.AddressTypeCode)); sql_params.Add(new SqlParameter("@address_type_name", entity.AddressTypeName)); sql_params.Add(new SqlParameter("@address_type_desc", entity.AddressTypeDesc)); sql_params.Add(GetOutParam()); return(sql_params); }
public AddressType(AddressTypeData addressTypeData) { if (addressTypeData == null) { throw new ArgumentNullException(nameof(addressTypeData)); } AddressTypeId = addressTypeData.AddressTypeId; AddressTypeCode = addressTypeData.AddressTypeCode; AddressTypeName = addressTypeData.AddressTypeName; AddressTypeCategory = addressTypeData.AddressTypeCategory; AddressTypeDesc = addressTypeData.AddressTypeDesc; }
public AddressType Map(AddressTypeData address_type_data) { return(new AddressType() { AddressTypeKey = address_type_data.AddressTypeKey, AddressTypeCode = address_type_data.AddressTypeCode, AddressTypeName = address_type_data.AddressTypeName, AddressTypeDesc = address_type_data.AddressTypeDesc, AddedUserID = address_type_data.AuditAddUserId, AddedDateTime = address_type_data.AuditAddDatetime, UpdateUserID = address_type_data.AuditUpdateUserId, UpdateDateTime = address_type_data.AuditUpdateDatetime, }); }
public bool DeleteType(AddressType type) { if (type == null) { throw new ArgumentNullException(nameof(type)); } return(ExecuteFaultHandledOperation(() => { AddressTypeData address_type_data = _addr_es.Map(type); _repo_addr_type.Delete(address_type_data); return true; })); }
public void AddressTypeModelTest1() { var data = new AddressTypeData { AddressTypeKey = 1, AddressTypeCode = "TEST", AddressTypeName = "TEST", AddressTypeDesc = "TEST", AuditAddUserId = "TEST", AuditAddDatetime = new System.DateTime(2018, 1, 1), AuditUpdateUserId = "TEST", AuditUpdateDatetime = new System.DateTime(2018, 1, 1), }; var sut = new AddressType(data); Assert.True(sut.AddressTypeKey == 1); Assert.True(sut.AddressTypeCode == "TEST"); Assert.True(sut.AddressTypeName == "TEST"); Assert.True(sut.AddressTypeDesc == "TEST"); }
public void SetAddressType(AddressTypeData addressTypeData) { AddressType = new AddressType(addressTypeData); AddressTypeId = addressTypeData.AddressTypeId; }
public AddressType Map(AddressTypeData commentData) => new AddressType(commentData);
public AddressType Map(AddressTypeData ent) { return(new AddressType(ent)); }
public List <SqlParameter> MapParamsForDelete(AddressTypeData entity) { return(MapParamsForDelete(entity.AddressTypeKey)); }