Implemented Sort By feature