hr view data fetching logic