Add sort_key and sort_dir parameters to *-list

These arguments are using for sorting the result on the server.
Small refactoring was conducted to seperate processing of
common arguments for all lists into the utility function.

Change-Id: I33be1fcecc665c8f2207e53b24ff47954d80dc60
Closes-Bug: #1339731
Merge "Add sort_key and sort_dir parameters to *-list"