public async Task <IEnumerable <Address> > GetAll() { var sqlQuery = "select * from Address"; using var connection = new SqlConnection(_sql.GetConnectionString()); var addresses = await connection.QueryAsync <Address>(sqlQuery); return(addresses); }
public async Task <IEnumerable <Detail> > GetAll() { var sqlQuery = "select * from Details"; using var connection = new SqlConnection(_sql.GetConnectionString()); var details = await connection.QueryAsync <Detail>(sqlQuery); return(details); }
public async Task <IEnumerable <Property> > GetAll() { var sqlQuery = "select * from Properties"; using var connection = new SqlConnection(_sql.GetConnectionString()); var properties = await connection.QueryAsync <Property>(sqlQuery); return(properties); }