added sorting to opportunities