public void Update(ref DBHelper dbHelper, UserEmail objUserEmail) { try { } catch (Exception objExp) { throw objExp; } }
public async Task<IUserEmail> Select(System.Int64 UserID) { return await Task.Run(() => { IDataReader objDataReader = null; UserEmail objUserEmail = null; try { var dbHelper = DBHelper.Instance; dbHelper.AddInParameter("@UserID", UserID, DbType.Int64); objDataReader = dbHelper.ExecuteDataReader(ProcedureName.SelectUserEmail, CommandType.StoredProcedure); if (objDataReader != null) { if (objDataReader.Read()) { objUserEmail = new UserEmail(); if (!objDataReader.IsDBNull(0)) objUserEmail.EmailID = objDataReader.GetString(0); if (!objDataReader.IsDBNull(1)) objUserEmail.UserID = objDataReader.GetInt64(1); if (!objDataReader.IsDBNull(2)) objUserEmail.Email = objDataReader.GetString(2); if (!objDataReader.IsDBNull(3)) objUserEmail.IsActive = objDataReader.GetInt32(3); if (!objDataReader.IsDBNull(4)) objUserEmail.IsVerified = objDataReader.GetInt32(4); if (!objDataReader.IsDBNull(5)) objUserEmail.IsVerCodeSent = objDataReader.GetInt32(5); if (!objDataReader.IsDBNull(6)) objUserEmail.VerificationCode = objDataReader.GetString(6); if (!objDataReader.IsDBNull(7)) objUserEmail.DttmCreated = objDataReader.GetDateTime(7); if (!objDataReader.IsDBNull(8)) objUserEmail.DttmModified = objDataReader.GetDateTime(8); } } if (!objDataReader.IsClosed) objDataReader.Close(); } catch (Exception objExp) { throw objExp; } return objUserEmail; }); }