refactor facilities controller to only make one call to db instead of three