結果 : how to sort an array based on an object's value in javascript