added helper for getting data by calling it from views