/// <summary> /// Returns a new MailGroupDetails instance filled with the DataReader's current record data /// </summary> protected virtual MailGroupDetails GetMailGroupFromReader(DbDataReader reader) { MailGroupDetails mailGroup = new MailGroupDetails(); if (reader.HasRows) { mailGroup.MailGroupId = GetReaderValue_Int32(reader, "MailGroupId", 0); //From: [Table] mailGroup.Name = GetReaderValue_String(reader, "Name", ""); //From: [Table] mailGroup.UpdatedBy = GetReaderValue_NullableInt32(reader, "UpdatedBy", null); //From: [Table] mailGroup.DLUP = GetReaderValue_NullableDateTime(reader, "DLUP", null); //From: [Table] mailGroup.ClientNo = GetReaderValue_NullableInt32(reader, "ClientNo", null); //From: [Table] mailGroup.LoginNo = GetReaderValue_NullableInt32(reader, "LoginNo", null); //From: [Table] mailGroup.NumberOfMembers = GetReaderValue_NullableInt32(reader, "NumberOfMembers", null); //From: [usp_selectAll_Division_for_Client] } return(mailGroup); }
/// <summary> /// Get /// Calls [usp_select_MailGroup] /// </summary> public static MailGroup Get(System.Int32?mailGroupNo) { Rebound.GlobalTrader.DAL.MailGroupDetails objDetails = Rebound.GlobalTrader.DAL.SiteProvider.MailGroup.Get(mailGroupNo); if (objDetails == null) { return(null); } else { MailGroup obj = new MailGroup(); obj.MailGroupId = objDetails.MailGroupId; obj.Name = objDetails.Name; obj.UpdatedBy = objDetails.UpdatedBy; obj.DLUP = objDetails.DLUP; obj.ClientNo = objDetails.ClientNo; obj.LoginNo = objDetails.LoginNo; obj.NumberOfMembers = objDetails.NumberOfMembers; objDetails = null; return(obj); } }