title: How to orderby in AngularJS using Nested property
body: <p>This is the json that is generated using PHP </p>
  
  <pre><code>[{"Sale":{"id":"1","customer_id":"1","amount":"15","created":"2014-05-17"}}]
  </code></pre>
  
  <p>Doing <code>orderBy:id</code> is obviously not working. I read in other posts that an orderBy function needs to be created for this kind of data structure. I am not able to create the function. Can anyone please tell me what is the correct way to approach this?</p>