public IList<CY.UME.Core.Business.AlbumExtend> GetAlbumExtend(long AccountId, string type, string instanceId) { IList<Core.Business.AlbumExtend> albumExtendlist = new List<Core.Business.AlbumExtend>(); SqlServerUtility sql = new SqlServerUtility(connectionString); sql.AddParameter("@AccountId", SqlDbType.BigInt, AccountId); sql.AddParameter("@Type", SqlDbType.NVarChar, type); sql.AddParameter("@InstanceId", SqlDbType.NVarChar, instanceId); SqlDataReader reader = sql.ExecuteSPReader("USP_AlbumExtend_Select_By_AccountId_And_InstanceId_And_Type"); if (reader != null) { while (reader.Read()) { Core.Business.AlbumExtend albumExtend = new Core.Business.AlbumExtend(); long Id = 0; if (!reader.IsDBNull(0)) Id = reader.GetInt64(0); albumExtend = CY.UME.Core.Business.AlbumExtend.Load(Id); albumExtend.MarkOld(); albumExtendlist.Add(albumExtend); } reader.Close(); } return albumExtendlist; }
public IList<Core.Business.AlbumExtend> GetAllAlbumExtend() { IList<Core.Business.AlbumExtend> albumExtendlist = new List<Core.Business.AlbumExtend>(); SqlServerUtility sql = new SqlServerUtility(connectionString); SqlDataReader reader = sql.ExecuteSPReader("USP_AlbumExtend_SelectAll"); if(reader != null) { while(reader.Read()) { Core.Business.AlbumExtend albumExtend = new Core.Business.AlbumExtend(); long Id = 0; if (!reader.IsDBNull(0)) Id = reader.GetInt64(0); albumExtend = CY.UME.Core.Business.AlbumExtend.Load(Id); albumExtend.MarkOld(); albumExtendlist.Add(albumExtend); } reader.Close(); } return albumExtendlist; }